7 [% IF SELF.part.image || SELF.part.description %]
8 [% IF SELF.part.image && INSTANCE_CONF.get_parts_show_image %]
9 <div class="image col">
10 <a href="[% SELF.part.image | html %]" target="_blank">
11 <img style="[% INSTANCE_CONF.get_parts_image_css %]" src="[% SELF.part.image | html %]"/>
15 [% IF SELF.part.description %]
16 <h2 class="record-title col">
17 [% SELF.part.description %] [% IF SELF.part.partnumber %]<small>([% SELF.part.partnumber %])</small>[% END %]
22 <div class="wrapper" id="wrapper-1">
23 [% INCLUDE 'generic/toggle_wrapper.html' %]
26 <table id="ic3" class="tbl-horizontal">
27 <caption>[% 'Basic Article Data' | $T8 %]</caption>
28 <colgroup> <col class="wi-mediumsmall"><col class="wi-wide"> </colgroup>
31 <th>[% 'Part Number' | $T8 %]</th>
32 <td>[% L.input_tag("part.partnumber", SELF.part.partnumber, size=10, class='initial_focus
33 wi-mediumsmall', "data-validate"="trimmed_whitespaces") %]</td>
36 <th>[% 'Part Classification' | $T8 %]</th>
37 <td>[% P.part.select_classification('part.classification_id', default => SELF.part.classification_id, type => SELF.parts_classification_filter, class='wi-wide' ) %]</td>
40 <th>[% 'Part Description' | $T8 %]</th>
41 <td class="wi-wide">[% L.areainput_tag("part.description", SELF.part.description, class='wi-wide', cols=10, rows=10) %]</td>
44 <th>[% 'EAN-Code' | $T8 %]</th>
45 <td>[% L.input_tag("part.ean", SELF.part.ean, class='wi-wide', size=10, "data-validate"="trimmed_whitespaces") %]</td>
48 <th>[% 'Tariff Code' | $T8 %]</th>
49 <td>[% L.input_tag("part.tariff_code", SELF.part.tariff_code, class='wi-wide', size=10, "data-validate"="trimmed_whitespaces") %]</td>
51 [% IF SELF.all_partsgroups.size %]
53 <th>[% 'Partsgroup' | $T8 %]</th>
55 [% L.select_tag('part.partsgroup_id', SELF.all_partsgroups, default=SELF.part.partsgroup_id, title_key='partsgroup', value_key='id', with_empty=1, class='wi-wide') %]
59 [% IF SELF.all_buchungsgruppen.size %]
61 <th>[% 'Booking group' | $T8 %]</th>
62 <td>[% L.select_tag('part.buchungsgruppen_id', SELF.all_buchungsgruppen, default=SELF.part.buchungsgruppen_id, title_key='description', value_key='id', with_empty=0, class='wi-wide') %]</td>
65 [% IF SELF.all_payment_terms.size %]
67 <th>[% 'Payment Terms' | $T8 %]</th>
68 <td>[% L.select_tag('part.payment_id', SELF.all_payment_terms, default=SELF.part.payment_id, title_key='description', value_key='id', with_empty=1, class='wi-wide') %]</td>
72 <th> <label for="order_locked">[% 'Do not order anymore' | $T8 %]</label> </th>
73 <td>[% L.checkbox_tag('part.order_locked', checked = SELF.part.order_locked, for_submit=1) %]</td>
77 <th> <label for="part_obsolete">[% 'Obsolete' | $T8 %]</label> </th>
78 <td>[% L.checkbox_tag('part.obsolete', checked = SELF.part.obsolete, for_submit=1) %]</td>
82 <th> <label for="part_shop">[% 'Shop article' | $T8 %]</label> </th>
83 <td>[% L.checkbox_tag('part.shop', checked = SELF.part.shop, for_submit=1, id='part_shop') %]</td>
88 <table class="tbl-horizontal">
89 <caption>[% 'Part Notes' | $T8 %]</caption>
90 <colgroup> <col class="wi-mediumsmall-wide"> </colgroup>
93 <td class="wi-mediumsmall-wide">[% L.textarea_tag("part.notes", P.restricted_html(SELF.part.notes), class='texteditor wi-mediumsmall-wide', cols=10, rows=10) %]</td>
100 <table id="ic5" class="tbl-horizontal">
101 <caption>[% 'Prices' | $T8 %]</caption>
102 <colgroup> <col class="wi-mediumsmall"><col class="wi-mediumsmall"> </colgroup>
105 <th>[% 'Price updated' | $T8 %]</th>
106 <td>[% SELF.part.last_price_update.valid_from.to_kivitendo | html %]</td>
109 <th>[% 'List Price' | $T8 %]</th>
111 [% IF (AUTH.assert('part_service_assembly_edit_prices', 'may_fail')) %]
112 [% L.input_tag("part.listprice_as_number", SELF.part.listprice_as_number, class='reformat_number numeric wi-mediumsmall', size=10) %]
114 <span class="data wi-mediumsmall numeric">[% SELF.part.listprice_as_number %]</span>
119 <th>[% 'Sell Price' | $T8 %]</th>
121 [% IF (AUTH.assert('part_service_assembly_edit_prices', 'may_fail')) %]
122 [% L.input_tag("part.sellprice_as_number", SELF.part.sellprice_as_number, class='reformat_number numeric wi-mediumsmall', size=10) %]
124 <span class="data wi-mediumsmall numeric">[% SELF.part.sellprice_as_number %]</span>
126 [% IF (SELF.part.is_assortment or SELF.part.is_assembly) %]
127 <span class="data below wi-mediumsmall numeric">(<span id="items_sellprice_sum_basic">[% LxERP.format_amount(SELF.part.items_sellprice_sum, 2) %])</span></span>
132 <th>[% 'Last Cost' | $T8 %]</th>
134 [%- UNLESS SELF.part.is_assembly %]
135 [% IF (AUTH.assert('part_service_assembly_edit_prices', 'may_fail')) %]
136 [% L.input_tag("part.lastcost_as_number", SELF.part.lastcost_as_number, class='reformat_number numeric wi-mediumsmall', size=10) %]
138 <span class="data wi-mediumsmall numeric">[% SELF.part.lastcost_as_number %]</span>
141 [% IF SELF.part.is_assortment || SELF.part.is_assembly %]
142 <span class="data below wi-mediumsmall numeric">(<span id="items_lastcost_sum_basic">[% LxERP.format_amount(SELF.part.items_lastcost_sum, 2) %])</span></span>
146 [% IF SELF.all_price_factors.size %]
148 <th>[% 'Price Factor' | $T8 %]</th>
150 [% L.select_tag('part.price_factor_id', SELF.all_price_factors, default=SELF.part.price_factor_id, title_key='description', value_key='id', with_empty=1, class='wi-mediumsmall') %]
155 <th><label for="part_not_discountable">[% 'Not Discountable' | $T8 %]</label></th>
156 <td>[% L.checkbox_tag('part.not_discountable', checked = SELF.part.not_discountable, for_submit=1) %]</td>
160 <div id="pricegroups">
161 [% PROCESS 'part/_pricegroup_prices.html' %]
163 <table id="ic5" class="tbl-horizontal">
164 <colgroup> <col class="wi-mediumsmall"><col class="wi-small"> </colgroup>
167 <th>[% 'Business Volume' | $T8 %]</th>
168 <td>[% L.input_tag("part.gv_as_number", SELF.part.gv_as_number, class='reformat_number numeric wi-mediumsmall', size=10) %]</td>
171 <th>[% 'Verrechnungseinheit' | $T8 %]</th>
172 <td>[% L.input_tag("part.ve", SELF.part.ve, class='wi-mediumsmall', size=10) %]</td>
179 <table class="tbl-horizontal">
180 <caption>[% 'Unit' | $T8 %]</caption>
182 <col class="wi-small">
183 <col class="wi-lightwide">
187 <th>[% 'Unit' | $T8 %]</th>
189 [% IF !SELF.part.id or SELF.part.orphaned # same logic as unit_changable %]
190 [% L.select_tag('part.unit', SELF.all_units, default=SELF.part.unit, title_key='name', value_key='name', class='wi-mediumsmall') %]
192 [% L.hidden_tag('part.unit', SELF.part.unit) %] [% HTML.escape(SELF.part.unit) %]
197 [% UNLESS SELF.part.is_service %]
198 <table class="tbl-horizontal">
199 <caption>[% 'Warehouse' | $T8 %]</caption>
201 <col class="wi-small">
202 <col class="wi-lightwide">
206 <th>[% 'Weight' | $T8 %]</th>
208 [% IF SELF.part.is_assembly %]
209 <span id="items_weight_sum_basic">[% LxERP.format_amount(SELF.part.weight) %]</span>
211 [% L.input_tag('part.weight_as_number', SELF.part.weight_as_number, size=10, class='wi-small reformat_number numeric', size=10) %]
213 [% HTML.escape(INSTANCE_CONF.get_weightunit) %]
217 <th>[% 'On Hand' | $T8 %]</th>
218 <td><span class="data wi-small numeric">[% LxERP.format_amount(SELF.part.onhand) %] [% SELF.part.unit | html %]</span></td>
221 <th>[% 'ROP' | $T8 %]</th>
222 <td>[% L.input_tag("part.rop_as_number", SELF.part.rop_as_number, size=10, class='wi-small reformat_number numeric') %]</td>
225 <th align="right" nowrap="true">[% 'Order Size' | $T8 %]</th>
226 <td>[% L.input_tag("part.order_qty_as_number", SELF.part.order_qty_as_number, size=10,
227 class="wi-small reformat_number numeric") %]</td>
229 [% IF SELF.all_warehouses.size %]
231 <th>[% 'Default Warehouse' | $T8 %]</th>
232 <td>[% L.select_tag('part.warehouse_id', SELF.all_warehouses, default=SELF.part.warehouse.id, title_key='description', with_empty=1, class='wi-lightwide') %]</td>
236 <th>[% 'Default Bin' | $T8 %]</th>
237 <td class="wi-lightwide">
238 <span id="bin" class="condensed">
239 [% IF SELF.part.warehouse.id %]
240 [% L.select_tag('part.bin_id', SELF.part.warehouse.bins_sorted_naturally, default=SELF.part.bin.id, title_key='description', with_empty=0, class='wi-lightwide') %]
246 <th><label for="part_has_sernumber">[% 'Has serial number' | $T8 %]</label></th>
247 <td>[% L.checkbox_tag('part.has_sernumber', checked = SELF.part.has_sernumber, for_submit=1) %]</td>
251 [% END #/UNLESS SELF.part.is_service %]
253 <table class="tbl-horizontal">
254 <caption>[% 'Formula' | $T8 %]</caption>
255 <colgroup> <col class="wi-small-mediumsmall"> </colgroup>
258 <td> <textarea id="part.formel" name="part.formel" rows="[% IF notes_rows %][% HTML.escape(notes_rows) %][% ELSE %]3[% END %]" cols="10" class="tooltipster-html wi-small-mediumsmall" title="[% 'The formula needs the following syntax:<br>For regular article:<br>Variablename= Variable Unit;<br>Variablename2= Variable2 Unit2;<br>...<br>###<br>Variable + ( Variable2 / Variable )<br><b>Please be beware of the spaces in the formula</b><br>' | $T8 %]">[% HTML.escape(SELF.part.formel) %]</textarea>
264 <table id="ic6" class="tbl-horizontal">
265 <caption>[% 'Illustrations' | $T8 %]</caption>
266 <colgroup><col class="wi-small"><col class="wi-lightwide"></colgroup>
269 <th>[% 'Image' | $T8 %]</th>
270 <td>[% L.input_tag("part.image", SELF.part.image, class='wi-lightwide', size=10,
271 "data-validate"="trimmed_whitespaces") %]</td>
274 <th>[% 'Microfiche' | $T8 %]</th>
275 <td>[% L.input_tag("part.microfiche", SELF.part.microfiche, class='wi-lightwide', size=10,
276 "data-validate"="trimmed_whitespaces") %]</td>
279 <th>[% 'Drawing' | $T8 %]</th>
280 <td>[% L.input_tag("part.drawing", SELF.part.drawing, class='wi-lightwide', size=10,
281 "data-validate"="trimmed_whitespaces") %]</td>
287 [% IF CUSTOM_VARIABLES_FIRST_TAB %]
289 <table id="custom_variables_table" class="tbl-list wi-moderate">
290 <caption>[% 'Custom Variables' | $T8 %]</caption>
292 <col class="wi-smallest">
293 <col class="wi-small">
294 <col class="wi-lightwide">
299 <th>[% 'Description' | $T8 %]</th>
300 <th>[% 'Value' | $T8 %]</th>
304 [%- FOREACH var = CUSTOM_VARIABLES_FIRST_TAB %]
306 <td>[% var.VALID_BOX %]</td>
308 [%- IF !var.partsgroup_filtered %]
309 [% HTML.escape(var.description) %]
312 <td>[% var.HTML_CODE %]</td>
317 <div class="wrapper">
318 <p>[% 'Note' | $T8 %]: [% 'Unchecked custom variables will not appear in orders and invoices.' | $T8 %]</p>
323 </div><!-- /.wrapper -->
325 <div id="customerprices" class="wrapper">
326 [% PROCESS 'part/_customerprices.html' %]
329 [% UNLESS SELF.part.is_assembly %]
330 <div id="makemodel" class="wrapper">[% PROCESS 'part/_makemodel.html' %]</div>
333 <div id="businessmodels" class="wrapper">
334 [% PROCESS 'part/_businessmodels.html' %]