Merge pull request #3567 from rmehta/item-description-mozilla-fix
[fix] item image in mozilla #3412 #3413
diff --git a/erpnext/templates/print_formats/includes/item_table_description.html b/erpnext/templates/print_formats/includes/item_table_description.html
index f259626..ece5386 100644
--- a/erpnext/templates/print_formats/includes/item_table_description.html
+++ b/erpnext/templates/print_formats/includes/item_table_description.html
@@ -1,6 +1,7 @@
{% if doc.in_format_data("image") and doc.get("image") and not doc.is_print_hide("image")-%}
<div class="pull-left" style="max-width: 38.2%; margin-right: 10px;">
- <img src="{{ doc.image }}" style="max-width: 100%">
+ <!-- width: 100% is a mozilla bug -->
+ <img src="{{ doc.image }}" class="img-responsive" style="width: 100%;">
</div>
{%- endif %}
<div>
@@ -8,14 +9,14 @@
<div class="primary">{{ doc.item_code }}</div>
{%- endif %}
{% if (doc.in_format_data("item_name") and not doc.is_print_hide("item_name") and
- (not doc.in_format_data("item_code") or doc.is_print_hide("item_code")
+ (not doc.in_format_data("item_code") or doc.is_print_hide("item_code")
or doc.item_code != doc.item_name)) -%}
<div class="primary">{{ doc.get_formatted("item_name") }}</div>
{%- endif %}
{% if (doc.in_format_data("description") and doc.description and
(
(
- (not doc.in_format_data("item_code") or doc.is_print_hide("item_code")) and
+ (not doc.in_format_data("item_code") or doc.is_print_hide("item_code")) and
(not doc.in_format_data("item_name") or doc.is_print_hide("item_name"))
) or not (doc.item_code == doc.item_name == doc.description)
))