5 [% SET best_price = price_source.best_price %]
6 [% SET best_discount = price_source.best_discount %]
7 <h2>[% 'Prices' | $T8 %]</h2>
10 <tr class='listheading'>
12 <th>[% 'Price Source' | $T8 %]</th>
13 <th>[% 'Price' | $T8 %]</th>
14 <th>[% 'Best Price' | $T8 %]</th>
15 <th>[% 'Details' | $T8 %]</th>
18 [%- IF price_source.record_item.active_price_source %]
19 <td>[% L.button_tag('kivi.io.update_price_source(' _ FORM.row _ ', \'\')', LxERP.t8('Select')) %]</td>
21 <td><b>[% 'Selected' | $T8 %]</b></td>
23 <td>[% 'None (PriceSource)' | $T8 %]</td>
28 [%- FOREACH price IN price_source.available_prices %]
30 [%- IF price_source.record_item.active_price_source != price.source %]
31 <td>[% L.button_tag('kivi.io.update_price_source(' _ FORM.row _ ', \'' _ price.source _ '\', \'' _ LxERP.format_amount(price.price, -2) _ '\')', LxERP.t8('Select')) %]</td>
32 [%- ELSIF price_source.record_item.sellprice * 1 != price.price * 1 %]
33 <td>[% L.button_tag('kivi.io.update_price_source(' _ FORM.row _ ', \'' _ price.source _ '\', \'' _ LxERP.format_amount(price.price, -2) _ '\')', LxERP.t8('Update Price')) %]</td>
35 <td><b>[% 'Selected' | $T8 %]</b></td>
37 <td>[% price.source_description | html %]</td>
38 <td class="numeric">[% price.price_as_number %]</td>
39 [% IF price.source == best_price.source %]
40 <td align='center'>•</td>
44 <td>[% price.description | html %]</td>
49 <h2>[% 'Discounts' | $T8 %]</h2>
52 <tr class='listheading'>
54 <th>[% 'Price Source' | $T8 %]</th>
55 <th>[% 'Discount' | $T8 %]</th>
56 <th>[% 'Best Discount' | $T8 %]</th>
57 <th>[% 'Details' | $T8 %]</th>
60 [%- IF price_source.record_item.active_discount_source %]
61 <td>[% L.button_tag('kivi.io.update_discount_source(' _ FORM.row _ ', \'\')', LxERP.t8('Select')) %]</td>
63 <td><b>[% 'Selected' | $T8 %]</b></td>
65 <td>[% 'None (PriceSource Discount)' | $T8 %]</td>
70 [%- FOREACH price IN price_source.available_discounts %]
72 [%- IF price_source.record_item.active_discount_source != price.source %]
73 <td>[% L.button_tag('kivi.io.update_discount_source(' _ FORM.row _ ', \'' _ price.source _ '\', \'' _ price.discount_as_percent _ '\')', LxERP.t8('Select')) %]</td>
74 [%- ELSIF price_source.record_item.discount * 1 != price.discount * 100 %]
75 <td>[% L.button_tag('kivi.io.update_discount_source(' _ FORM.row _ ', \'' _ price.source _ '\', \'' _ price.discount_as_percent _ '\')', LxERP.t8('Update Discount')) %]</td>
77 <td><b>[% 'Selected' | $T8 %]</b></td>
79 <td>[% price.source_description | html %]</td>
80 <td>[% price.discount_as_percent %] %</td>
81 [% IF price.source == best_discount.source %]
82 <td align='center'>•</td>
86 <td>[% price.description | html %]</td>