item grid, added other printable fields in description
This commit is contained in:
parent
f84c240d1c
commit
d82352eacc
@ -1,3 +1,7 @@
|
|||||||
|
{%- from "templates/print_formats/standard_macros.html" import print_value -%}
|
||||||
|
{%- set std_fields = ("item_code", "item_name", "description", "qty", "rate", "amount", "stock_uom") -%}
|
||||||
|
{%- set visible_columns = get_visible_columns(doc.get(df.fieldname), table_meta) -%}
|
||||||
|
|
||||||
<table class="table table-bordered">
|
<table class="table table-bordered">
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
@ -18,11 +22,21 @@
|
|||||||
{%- endif %}
|
{%- endif %}
|
||||||
</td>
|
</td>
|
||||||
<td style="width: 37%;">
|
<td style="width: 37%;">
|
||||||
<div style="border: 0px;">{{ row.description }}</div></td>
|
<div style="border: 0px;">{{ row.description }}
|
||||||
|
{%- for field in visible_columns -%}
|
||||||
|
{%- if (field.fieldname not in std_fields) and
|
||||||
|
(row[field.fieldname] not in (None, "")) -%}
|
||||||
|
<br><strong>{{ field.label }}:</strong>
|
||||||
|
{{ frappe.format_value(row[field.fieldname], field, doc) }}</p>
|
||||||
|
{%- endif -%}
|
||||||
|
{%- endfor -%}
|
||||||
<td style="width: 10%; text-align: right;">{{ row.qty }} {{ row.stock_uom }}</td>
|
<td style="width: 10%; text-align: right;">{{ row.qty }} {{ row.stock_uom }}</td>
|
||||||
<td style="width: 15%; text-align: right;">{{
|
<td style="width: 15%; text-align: right;">{{
|
||||||
format(row.rate, table_meta.get_field("rate"), doc) }}</td>
|
frappe.format_value(row.rate,
|
||||||
<td style="width: 15%; text-align: right;">{{ format(row.amount, table_meta.get_field("amount"), doc) }}</td>
|
table_meta.get_field("rate"), doc) }}</td>
|
||||||
|
<td style="width: 15%; text-align: right;">{{
|
||||||
|
frappe.format_value(row.amount,
|
||||||
|
table_meta.get_field("amount"), doc) }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
{%- endfor -%}
|
{%- endfor -%}
|
||||||
</tbody>
|
</tbody>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user