1 [%- USE HTML -%][%- USE LxERP -%][%- USE L -%][%- USE T8 -%]<h1>[% HTML.escape(title) %]</h1>
2 [% SET style="width: 400px" %]
4 <form action="controller.pl" method="post">
5 [%- L.hidden_tag("id", SELF.config.id) %]
9 <th align="right">[% 'Description' | $T8 %]</th>
10 <td>[%- L.input_tag("config.description", SELF.config.description) %]</td>
12 [%- FOREACH bg = BUCHUNGSGRUPPEN %]
14 <th align="right">[% 'Revenue' | $T8 %] [% HTML.escape(bg.description) %]</th>
15 [%- IF NOT SELF.config.id %]
16 <td>[% L.chart_picker('income_accno_id_' _ bg.id, SELF.defaults.income_accno_id, choose=1, type='IC_income,IC_sale', style=style) %]</td>
17 [%- ELSIF SELF.config.id AND SELF.config.orphaned %]
18 <td>[% L.chart_picker('income_accno_id_' _ bg.id, CHARTLIST.${bg.id}.income_accno_id, choose=1, type='IC_income,IC_sale', style=style) %]</td>
20 <td>[% CHARTLIST.${bg.id}.income_accno_description %]</td>
24 <th align="right">[% 'Expense' | $T8 %] [% HTML.escape(bg.description) %]</th>
25 [%- IF NOT SELF.config.id %]
26 <td>[% L.chart_picker('expense_accno_id_' _ bg.id, SELF.defaults.expense_accno_id, choose=1, type='IC_expense,IC_cogs', style=style) %]</td>
27 [%- ELSIF SELF.config.id AND SELF.config.orphaned %]
28 <td>[% L.chart_picker('expense_accno_id_' _ bg.id, CHARTLIST.${bg.id}.expense_accno_id, choose=1, type='IC_expense,IC_cogs', style=style) %]</td>
30 <td>[% CHARTLIST.${bg.id}.expense_accno_description %]</td>
36 [% LxERP.t8('Obsolete') %]: [% L.checkbox_tag('config.obsolete', checked = SELF.config.obsolete, for_submit=1) %]
39 [% L.hidden_tag("action", "Taxzones/dispatch") %]
40 [% L.submit_tag("action_" _ (SELF.config.id ? "update" : "create"), LxERP.t8('Save'), onclick="return check_prerequisites();") %]
41 [%- IF SELF.config.id AND SELF.config.orphaned %]
42 [% L.submit_tag("action_delete", LxERP.t8('Delete'), confirm=LxERP.t8('Are you sure?')) %]
44 <a href="[% SELF.url_for(action='list') %]">[%- LxERP.t8("Cancel") %]</a>
49 <script type="text/javascript">
51 function check_prerequisites() {
52 if ($('#config_description').val() === "") {
53 alert(kivi.t8('The description is missing.'));