3 [% USE HTML %]<script type="text/javascript" src="js/FormManager.js" >
4 /****************************************************
5 * Form Dependency Manager- By Twey- http://www.twey.co.uk
6 * Visit Dynamic Drive for this script and more: http://www.dynamicdrive.com
7 ****************************************************/
10 <script type="text/javascript">
11 window.onload = function() {
12 setupDependencies('EditAccount'); //name of form(s). Seperate each with a comma (ie: 'weboptions', 'myotherform' )
17 <form method="post" name="EditAccount" action="am.pl">
19 <input type="hidden" name="id" value="[% HTML.escape(id) %]">
20 <input type="hidden" name="type" value="account">
21 <input type="hidden" name="orphaned" value="[% HTML.escape(orphaned) %]">
22 <input type="hidden" name="new_chart_valid" value="[% HTML.escape(new_chart_valid) %]">
23 <input type="hidden" name="original_accno" value="[% HTML.escape(accno) %]">
24 <input type="hidden" name="inventory_accno_id" value="[% HTML.escape(inventory_accno_id) %]">
25 <input type="hidden" name="income_accno_id" value="[% HTML.escape(income_accno_id) %]">
26 <input type="hidden" name="expense_accno_id" value="[% HTML.escape(expense_accno_id) %]">
27 <input type="hidden" name="fxgain_accno_id" value="[% HTML.escape(fxgain_accno_id) %]">
28 <input type="hidden" name="fxloss_accno_id" value="[% HTML.escape(fxloss_accno_id) %]">
30 <table border="0" width="100%">
32 <th class="listtop">[% title %]</th>
38 [% 'Main Preferences' | $T8 %]
44 [% 'Account Number' | $T8 %]
46 <td><input name="accno" size="20" value="[% HTML.escape(accno) %]"></td>
51 [% 'Description' | $T8 %]
54 <td><input name="description" size="40" value="[% HTML.escape(description) %]"></td>
59 [% 'Chart Type' | $T8 %]
64 [% IF AccountIsPosted %]
65 [% L.select_tag('dummy_charttype',
66 L.options_for_select(all_charttypes,
67 title => 'name', value => 'value',
68 default => selected_charttype),
70 [% L.hidden_tag('charttype', selected_charttype) %]
72 [% L.select_tag('charttype',
73 L.options_for_select(all_charttypes,
74 title => 'name', value => 'value',
75 default => selected_charttype)) %]
82 <fieldset class="DEPENDS ON charttype BEING A">
83 <legend>[% 'Account Type' | $T8 %]</legend>
84 <select name="category" id="AccountType" class="DEPENDS ON charttype BEING A">
85 [% select_category %]</select>
88 [% IF ChartTypeIsAccount %]
89 <fieldset class="DEPENDS ON charttype BEING A">
90 <legend>[% 'Is this a summary account to record' | $T8 %]</legend>
91 <input name="AR" type="checkbox" class="checkbox" value="AR" [% HTML.escape(AR) %]>
92 [% 'AR' | $T8 %]
93 <input name="AP" type="checkbox" class="checkbox" value="AP" [% HTML.escape(AP) %]>
94 [% 'AP' | $T8 %]
95 <input name="IC" type="checkbox" class="checkbox" value="IC" [% HTML.escape(IC) %]>
96 [% 'Inventory' | $T8 %]
99 [% IF AccountIsPosted %]
100 [% IF AR_amount %] [% L.hidden_tag('AR_amount', 'AR_amount') %] [% END %]
101 [% IF AR_paid %] [% L.hidden_tag('AR_paid', 'AR_paid') %] [% END %]
102 [% IF AR_tax %] [% L.hidden_tag('AR_tax', 'AR_tax') %] [% END %]
103 [% IF AP_amount %] [% L.hidden_tag('AP_amount', 'AP_amount') %] [% END %]
104 [% IF AP_paid %] [% L.hidden_tag('AP_paid', 'AP_paid') %] [% END %]
105 [% IF AP_tax %] [% L.hidden_tag('AP_tax', 'AP_tax') %] [% END %]
106 [%- SET DIS = ' disabled="disabled"' %]
108 <fieldset class="DEPENDS ON charttype BEING A">
109 <legend>[% 'Include in drop-down menus' | $T8 %]</legend>
110 <p style='font-weight:normal'>[% 'These will only be effective if the account is NOT a summary account AND there exists at least one taxkey. Setting the account as a summary account will erase these settings.' | $T8 %]</p>
111 <p style='font-weight:normal'>[% 'Changes to Receivables and Payables are only possible if no transactions to this account are posted yet.' | $T8 %]
112 [% 'And if the account does not act as tax-o-matic account.' | $T8 %]</p>
115 <th align="left">[% 'Receivables' | $T8 %]</th>
116 <th align="left">[% 'Payables' | $T8 %]</th>
117 <th align="left">[% 'Parts Inventory' | $T8 %]</th>
118 <th align="left">[% 'Service Items' | $T8 %]</th>
122 [% L.radio_button_tag('AR_include_in_dropdown',
123 value => 'AR_amount',
124 disabled => AccountIsPosted,
125 checked => AR_amount) %]
126 [% 'Revenue' | $T8 %] <br>
127 [% L.radio_button_tag('AR_include_in_dropdown',
129 disabled => AccountIsPosted,
130 checked => AR_paid) %]
131 [% 'Receipt' | $T8 %] <br>
132 [% L.radio_button_tag('AR_include_in_dropdown',
134 disabled => AccountIsPosted,
135 checked => AR_tax) %]
136 [% 'Tax' | $T8 %] <br>
137 [% L.radio_button_tag('AR_include_in_dropdown',
139 disabled => AccountIsPosted) %]
140 [% 'do not include' | $T8 %]
143 [% L.radio_button_tag('AP_include_in_dropdown',
144 value => 'AP_amount',
145 disabled => AccountIsPosted,
146 checked => AP_amount) %]
147 [% 'Expense/Asset' | $T8 %] <br>
148 [% L.radio_button_tag('AP_include_in_dropdown',
150 disabled => AccountIsPosted,
151 checked => AP_paid) %]
152 [% 'Payment' | $T8 %] <br>
153 [% L.radio_button_tag('AP_include_in_dropdown',
155 disabled => AccountIsPosted,
156 checked => AP_tax) %]
157 [% 'Tax' | $T8 %] <br>
158 [% L.radio_button_tag('AP_include_in_dropdown',
160 disabled => AccountIsPosted) %]
161 [% 'do not include' | $T8 %]
164 <input name="IC_sale" type="checkbox" class="checkbox" value="IC_sale"
165 [% HTML.escape(IC_sale) %]>
166 [% 'Revenue' | $T8 %] <br>
167 <input name="IC_cogs" type="checkbox" class="checkbox" value="IC_cogs"
168 [% HTML.escape(IC_cogs) %]>
169 [% 'Expense' | $T8 %] <br>
170 <input name="IC_taxpart" type="checkbox" class="checkbox" value="IC_taxpart"
171 [% HTML.escape(IC_taxpart) %]>
176 <input name=IC_income type=checkbox class=checkbox value="IC_income"
177 [% HTML.escape(IC_income) %]>
178 [% 'Revenue' | $T8 %] <br>
179 <input name=IC_expense type=checkbox class=checkbox value="IC_expense"
180 [% HTML.escape(IC_expense) %]>
181 [% 'Expense' | $T8 %] <br>
182 <input name=IC_taxservice type=checkbox class=checkbox value="IC_taxservice"
183 [% HTML.escape(IC_taxservice) %]>
191 <fieldset class="DEPENDS ON charttype BEING A">
193 [% 'Taxkeys and Taxreport Preferences' | $T8 %]
195 <p style='font-weight:normal'>[% 'Note: Taxkeys must have a "valid from" date, and will not behave correctly without.' | $T8 %]</p>
198 [% IF account_exists %]
200 <th align="left">[% 'Taxkey' | $T8 %]</th>
201 <th align="left">[% 'valid from' | $T8 %]</th>
202 <th align="left">[% 'pos_ustva' | $T8 %]</th>
203 <th align="left">[% 'delete' | $T8 %] ? </th>
205 [% FOREACH tk = ACCOUNT_TAXKEYS %]
208 <input type="hidden" name="taxkey_id_[% tk.runningnumber %]" value="[% tk.id %]">
209 <td><select name="taxkey_tax_[% tk.runningnumber %]">[% tk.selecttaxkey %]</select></td>
210 <td><input name="taxkey_startdate_[% tk.runningnumber %]" value="[% HTML.escape(tk.startdate) %]"></td>
211 <td><select name="taxkey_pos_ustva_[% tk.runningnumber %]">[% tk.select_tax %]</select></td>
212 <td><input name="taxkey_del_[% tk.runningnumber %]" type="checkbox"
213 class="checkbox" value="delete"></td>
215 <input type="hidden" name="taxkey_id_[% tk.runningnumber %]" value="NEW">
216 <td><select name="taxkey_tax_[% tk.runningnumber %]">[% tk.selecttaxkey %]</select></td>
217 <td><input name="taxkey_startdate_[% tk.runningnumber %]" value="[% HTML.escape(tk.startdate) %]"></td>
218 <td><select name="taxkey_pos_ustva_[% tk.runningnumber %]">[% tk.select_tax %]</select></td>
226 <td align="center" colspan="4"><p>[% 'Save account first to insert taxkeys' | $T8 %]</p>
233 <fieldset class="DEPENDS ON charttype BEING A">
234 <legend>[% 'Report and misc. Preferences' | $T8 %]</legend>
237 <th align="left">[% 'EUER' | $T8 %]</th>
238 <td colspan="3"><select name="pos_eur">[% select_eur %]</select></td>
241 <th align="left">[% 'BWA' | $T8 %]</th>
242 <td colspan="3"><select name="pos_bwa">[% select_bwa %]</select></td>
244 <!-- Diese Steuerfunktion hat keine Auswirkung in der Bilanz und wird erstmal deaktiviert. -->
246 <th align="left">[% 'Bilanz' | $T8 %]</th>
247 <td colspan="3"><select name="pos_bilanz">[% select_bilanz %]</select></td>
250 <th align="left">[% 'Datevautomatik' | $T8 %]</th>
251 <td colspan="3"><input name="datevautomatik" type="checkbox" class="checkbox" value="T" [% IF datevautomatik %]checked [% END %]></td>
254 <th align="left">[% 'Folgekonto' | $T8 %]</th>
255 <td><select name="new_chart_id">[% selectnewaccount %]</select></td>
256 <th align="left">[% 'Valid from' | $T8 %]</th>
257 <td><input name="valid_from" value="[% valid_from %]"></td>
262 <hr size="3" noshade>