120 |
120 |
}
|
121 |
121 |
|
122 |
122 |
sub report {
|
123 |
|
$main::lxdebug->enter_sub();
|
|
123 |
$::lxdebug->enter_sub;
|
124 |
124 |
|
125 |
125 |
check_rp_access();
|
126 |
126 |
|
127 |
|
my $form = $main::form;
|
128 |
|
my %myconfig = %main::myconfig;
|
129 |
|
my $locale = $main::locale;
|
130 |
|
|
131 |
127 |
my %title = (
|
132 |
|
'balance_sheet' => 'Balance Sheet',
|
133 |
|
'income_statement' => 'Income Statement',
|
134 |
|
'trial_balance' => 'Trial Balance',
|
135 |
|
'ar_aging' => 'Search AR Aging',
|
136 |
|
'ap_aging' => 'Search AP Aging',
|
137 |
|
'tax_collected' => 'Tax collected',
|
138 |
|
'tax_paid' => 'Tax paid',
|
139 |
|
'nontaxable_sales' => 'Non-taxable Sales',
|
140 |
|
'nontaxable_purchases' => 'Non-taxable Purchases',
|
141 |
|
'receipts' => 'Receipts',
|
142 |
|
'payments' => 'Payments',
|
143 |
|
'projects' => 'Project Transactions',
|
144 |
|
'bwa' => 'Business evaluation',
|
|
128 |
balance_sheet => $::locale->text('Balance Sheet'),
|
|
129 |
income_statement => $::locale->text('Income Statement'),
|
|
130 |
trial_balance => $::locale->text('Trial Balance'),
|
|
131 |
ar_aging => $::locale->text('Search AR Aging'),
|
|
132 |
ap_aging => $::locale->text('Search AP Aging'),
|
|
133 |
tax_collected => $::locale->text('Tax collected'),
|
|
134 |
tax_paid => $::locale->text('Tax paid'),
|
|
135 |
nontaxable_sales => $::locale->text('Non-taxable Sales'),
|
|
136 |
nontaxable_purchases => $::locale->text('Non-taxable Purchases'),
|
|
137 |
receipts => $::locale->text('Receipts'),
|
|
138 |
payments => $::locale->text('Payments'),
|
|
139 |
projects => $::locale->text('Project Transactions'),
|
|
140 |
bwa => $::locale->text('Business evaluation'),
|
145 |
141 |
);
|
146 |
142 |
|
147 |
|
$form->{title} = $locale->text($title{ $form->{report} });
|
148 |
|
|
149 |
|
my $accrual = $::instance_conf->get_accounting_method eq 'cash' ? "" : "checked";
|
150 |
|
my $cash = $::instance_conf->get_accounting_method eq 'cash' ? "checked" : "";
|
151 |
|
|
152 |
|
my $year = (localtime)[5] + 1900;
|
|
143 |
$::form->{title} = $title{$::form->{report}};
|
153 |
144 |
|
154 |
145 |
# get departments
|
155 |
|
$form->all_departments(\%myconfig);
|
156 |
|
if (@{ $form->{all_departments} || [] }) {
|
157 |
|
$form->{selectdepartment} = "<option>\n";
|
158 |
|
map { $form->{selectdepartment} .= "<option>$_->{description}--$_->{id}\n" } @{ $form->{all_departments} || [] };
|
|
146 |
$::form->all_departments(\%::myconfig);
|
|
147 |
if (@{ $::form->{all_departments} || [] }) {
|
|
148 |
$::form->{selectdepartment} = "<option>\n";
|
|
149 |
map { $::form->{selectdepartment} .= "<option>$_->{description}--$_->{id}\n" } @{ $::form->{all_departments} || [] };
|
159 |
150 |
}
|
160 |
151 |
|
161 |
|
my $department;
|
162 |
|
$department = qq|
|
163 |
|
<tr>
|
164 |
|
<th align=right nowrap>| . $locale->text('Department') . qq|</th>
|
165 |
|
<td colspan=3><select name=department>$form->{selectdepartment}</select></td>
|
166 |
|
</tr>
|
167 |
|
| if $form->{selectdepartment};
|
168 |
|
|
169 |
|
$form->get_lists("projects" => { "key" => "ALL_PROJECTS",
|
170 |
|
"all" => 1 });
|
171 |
|
|
172 |
|
my %project_labels = ();
|
173 |
|
my @project_values = ("");
|
174 |
|
foreach my $item (@{ $form->{"ALL_PROJECTS"} }) {
|
175 |
|
push(@project_values, $item->{"id"});
|
176 |
|
$project_labels{$item->{"id"}} = $item->{"projectnumber"};
|
177 |
|
}
|
178 |
|
|
179 |
|
my $projectnumber =
|
180 |
|
NTI($::request->{cgi}->popup_menu('-name' => "project_id",
|
181 |
|
'-values' => \@project_values,
|
182 |
|
'-labels' => \%project_labels));
|
183 |
|
|
184 |
|
# use JavaScript Calendar or not
|
185 |
|
$form->{jsscript} = 1;
|
186 |
|
my $jsscript = "";
|
187 |
|
my ( $name_1, $id_1, $value_1, $trigger_1, $name_2, $id_2, $value_2, $trigger_2, );
|
188 |
|
if ($form->{report} eq "balance_sheet") {
|
189 |
|
$name_1 = "asofdate";
|
190 |
|
$id_1 = "asofdate";
|
191 |
|
$value_1 = "$form->{asofdate}";
|
192 |
|
$trigger_1 = "trigger1";
|
193 |
|
$name_2 = "compareasofdate";
|
194 |
|
$id_2 = "compareasofdate";
|
195 |
|
$value_2 = "$form->{compareasofdate}";
|
196 |
|
$trigger_2 = "trigger2";
|
197 |
|
} elsif ($form->{report} =~ /(receipts|payments)$/) {
|
198 |
|
$name_1 = "fromdate";
|
199 |
|
$id_1 = "fromdate";
|
200 |
|
$value_1 = "$form->{fromdate}";
|
201 |
|
$trigger_1 = "trigger1";
|
202 |
|
$name_2 = "todate";
|
203 |
|
$id_2 = "todate";
|
204 |
|
$value_2 = "";
|
205 |
|
$trigger_2 = "trigger2";
|
206 |
|
} elsif (($form->{report} eq "ar_aging") || ($form->{report} eq "ap_aging")) {
|
207 |
|
$name_1 = "fromdate";
|
208 |
|
$id_1 = "fromdate";
|
209 |
|
$value_1 = "$form->{fromdate}";
|
210 |
|
$trigger_1 = "trigger1";
|
211 |
|
$name_2 = "todate";
|
212 |
|
$id_2 = "todate";
|
213 |
|
$value_2 = "";
|
214 |
|
$trigger_2 = "trigger2";
|
215 |
|
|
216 |
|
} else {
|
217 |
|
$name_1 = "fromdate";
|
218 |
|
$id_1 = "fromdate";
|
219 |
|
$value_1 = "$form->{fromdate}";
|
220 |
|
$trigger_1 = "trigger1";
|
221 |
|
$name_2 = "todate";
|
222 |
|
$id_2 = "todate";
|
223 |
|
$value_2 = "";
|
224 |
|
$trigger_2 = "trigger2";
|
225 |
|
}
|
226 |
|
|
227 |
|
my ($button1, $button1_2, $button2, $button2_2);
|
228 |
|
my $checked;
|
229 |
|
|
230 |
|
# with JavaScript Calendar
|
231 |
|
if ($form->{jsscript}) {
|
232 |
|
if ($name_1 eq "") {
|
233 |
|
$button1 = qq| <input name=$name_2 id=$id_2 size=11 title="$myconfig{dateformat}" onBlur=\"check_right_date_format(this)\">|;
|
234 |
|
$button1_2 = qq| <input type=button name=$name_2 id="$trigger_2" value=| . $locale->text('button') . qq|>|;
|
235 |
|
|
236 |
|
#write Trigger
|
237 |
|
$jsscript = Form->write_trigger(\%myconfig, "1", "$name_2", "BR", "$trigger_2");
|
238 |
|
} else {
|
239 |
|
$button1 = qq| <input name=$name_1 id=$id_1 size=11 title="$myconfig{dateformat}" value="$value_1" onBlur=\"check_right_date_format(this)\">|;
|
240 |
|
$button1_2 = qq| <input type=button name=$name_1 id="$trigger_1" value=| . $locale->text('button') . qq|>|;
|
241 |
|
$button2 = qq| <input name=$name_2 id=$id_2 size=11 title="$myconfig{dateformat}" onBlur=\"check_right_date_format(this)\">|;
|
242 |
|
$button2_2 = qq| <input type=button name=$name_2 id="$trigger_2" value=| . $locale->text('button') . qq|> |;
|
243 |
|
|
244 |
|
#write Trigger
|
245 |
|
$jsscript = Form->write_trigger(\%myconfig, "2", "$name_1", "BR", "$trigger_1", "$name_2", "BL", "$trigger_2");
|
246 |
|
}
|
247 |
|
} else {
|
|
152 |
$::form->get_lists("projects" => { "key" => "ALL_PROJECTS", "all" => 1 });
|
248 |
153 |
|
249 |
|
# without JavaScript Calendar
|
250 |
|
if ($name_1 eq "") {
|
251 |
|
$button1 = qq|<input name=$name_2 id=$id_2 size=11 title="$myconfig{dateformat}" onBlur=\"check_right_date_format(this)\">|;
|
252 |
|
} else {
|
253 |
|
$button1 = qq|<input name=$name_1 id=$id_1 size=11 title="$myconfig{dateformat}" value=$value_1 onBlur=\"check_right_date_format(this)\">|;
|
254 |
|
$button2 = qq|<input name=$name_2 id=$id_2 size=11 title="$myconfig{dateformat}" onBlur=\"check_right_date_format(this)\">|;
|
255 |
|
}
|
256 |
|
}
|
257 |
|
$form->{javascript} .= qq|<script type="text/javascript" src="js/common.js"></script>|;
|
258 |
|
$form->header;
|
259 |
154 |
my $onload = qq|focus()|;
|
260 |
|
$onload .= qq|;setupDateFormat('|. $myconfig{dateformat} .qq|', '|. $locale->text("Falsches Datumsformat!") .qq|')|;
|
261 |
|
$onload .= qq|;setupPoints('|. $myconfig{numberformat} .qq|', '|. $locale->text("wrongformat") .qq|')|;
|
262 |
|
print qq|
|
263 |
|
<body onLoad="$onload">
|
264 |
|
|
265 |
|
<form method=post action=$form->{script}>
|
266 |
|
|
267 |
|
<input type=hidden name=title value="$form->{title}">
|
268 |
|
|
269 |
|
<table width=100% border="0">
|
270 |
|
<tr>
|
271 |
|
<th class=listtop>$form->{title}</th>
|
272 |
|
</tr>
|
273 |
|
<tr height="5"></tr>
|
274 |
|
<tr>
|
275 |
|
<td>
|
276 |
|
<table border="0">
|
277 |
|
$department
|
278 |
|
|;
|
279 |
|
|
280 |
|
if ($form->{report} eq "projects") {
|
281 |
|
print qq|
|
282 |
|
<tr>
|
283 |
|
<th align=right nowrap>| . $locale->text('Project') . qq|</th>
|
284 |
|
<td colspan=5><input name=projectnumber size=25</td>
|
285 |
|
</tr>
|
286 |
|
<input type=hidden name=nextsub value=generate_projects>
|
287 |
|
<tr>
|
288 |
|
<th align=right>| . $locale->text('From') . qq|</th>
|
289 |
|
<td>$button1</td>
|
290 |
|
<td>$button1_2</td>
|
291 |
|
<th align=right>| . $locale->text('Bis') . qq|</th>
|
292 |
|
<td>$button2</td>
|
293 |
|
<td>$button2_2</td>
|
294 |
|
</tr>
|
295 |
|
</table>
|
296 |
|
</td>
|
297 |
|
</tr>
|
298 |
|
<tr>
|
299 |
|
<td>
|
300 |
|
<table>
|
301 |
|
<tr>
|
302 |
|
<th align=right nowrap>| . $locale->text('Include in Report') . qq|</th>
|
303 |
|
<td><input name=l_heading class=checkbox type=checkbox value=Y> | . $locale->text('Heading') . qq|
|
304 |
|
<input name=l_subtotal class=checkbox type=checkbox value=Y> | . $locale->text('Subtotal') . qq|</td>
|
305 |
|
</tr>
|
306 |
|
|
307 |
|
$jsscript
|
308 |
|
|;
|
309 |
|
}
|
310 |
|
|
311 |
|
if ($form->{report} eq "income_statement") {
|
312 |
|
print qq|
|
313 |
|
<tr>
|
314 |
|
<th align=right nowrap>| . $locale->text('Project') . qq|</th>
|
315 |
|
<td colspan=3>$projectnumber</td>
|
316 |
|
</tr>
|
317 |
|
<input type=hidden name=nextsub value=generate_income_statement>
|
318 |
|
</table>
|
319 |
|
<table>
|
320 |
|
<tr>
|
321 |
|
<th align=left><input name=reporttype class=radio type=radio value="custom" checked> | . $locale->text('Customized Report') . qq|</th>
|
322 |
|
</tr>
|
323 |
|
<tr>
|
324 |
|
<th colspan=1>| . $locale->text('Year') . qq|</th>
|
325 |
|
<td><input name=year size=11 title="| . $locale->text('YYYY') . qq|" value="$year"></td>
|
326 |
|
</tr>
|
327 |
|
|;
|
328 |
|
|
329 |
|
print qq|
|
330 |
|
<tr>
|
331 |
|
<td align=right> <b> | . $locale->text('Yearly') . qq|</b> </td>
|
332 |
|
<th align=left>| . $locale->text('Quarterly') . qq|</th>
|
333 |
|
<th align=left colspan=3>| . $locale->text('Monthly') . qq|</th>
|
334 |
|
</tr>
|
335 |
|
<tr>
|
336 |
|
<td align=right> <input name=duetyp class=radio type=radio value="13" "checked"></td>
|
337 |
|
<td><input name=duetyp class=radio type=radio value="A" $checked > 1. | . $locale->text('Quarter') . qq|</td>
|
338 |
|
|;
|
339 |
|
$checked = "";
|
340 |
|
print qq|
|
341 |
|
<td><input name=duetyp class=radio type=radio value="1" $checked > | . $locale->text('January') . qq|</td>
|
342 |
|
|;
|
343 |
|
$checked = "";
|
344 |
|
print qq|
|
345 |
|
<td><input name=duetyp class=radio type=radio value="5" $checked > | . $locale->text('May') . qq|</td>
|
346 |
|
<td><input name=duetyp class=radio type=radio value="9" $checked > | . $locale->text('September') . qq|</td>
|
347 |
|
|
348 |
|
</tr>
|
349 |
|
<tr>
|
350 |
|
<td align= right> </td>
|
351 |
|
<td><input name=duetyp class=radio type=radio value="B" $checked> 2. | . $locale->text('Quarter') . qq|</td>
|
352 |
|
<td><input name=duetyp class=radio type=radio value="2" $checked > | . $locale->text('February') . qq|</td>
|
353 |
|
<td><input name=duetyp class=radio type=radio value="6" $checked > | . $locale->text('June') . qq|</td>
|
354 |
|
<td><input name=duetyp class=radio type=radio value="10" $checked > | . $locale->text('October') . qq|</td>
|
355 |
|
</tr>
|
356 |
|
<tr>
|
357 |
|
<td> </td>
|
358 |
|
<td><input name=duetyp class=radio type=radio value="C" $checked> 3. | . $locale->text('Quarter') . qq|</td>
|
359 |
|
<td><input name=duetyp class=radio type=radio value="3" $checked > | . $locale->text('March') . qq|</td>
|
360 |
|
<td><input name=duetyp class=radio type=radio value="7" $checked > | . $locale->text('July') . qq|</td>
|
361 |
|
<td><input name=duetyp class=radio type=radio value="11" $checked > | . $locale->text('November') . qq|</td>
|
362 |
|
|
363 |
|
</tr>
|
364 |
|
<tr>
|
365 |
|
<td> </td>
|
366 |
|
<td><input name=duetyp class=radio type=radio value="D" $checked> 4. | . $locale->text('Quarter') . qq| </td>
|
367 |
|
<td><input name=duetyp class=radio type=radio value="4" $checked > | . $locale->text('April') . qq|</td>
|
368 |
|
<td><input name=duetyp class=radio type=radio value="8" $checked > | . $locale->text('August') . qq|</td>
|
369 |
|
<td><input name=duetyp class=radio type=radio value="12" $checked > | . $locale->text('December') . qq|</td>
|
370 |
|
|
371 |
|
</tr>
|
372 |
|
<tr>
|
373 |
|
<td colspan=5><hr size=3 noshade></td>
|
374 |
|
</tr>
|
375 |
|
<tr>
|
376 |
|
<th align=left><input name=reporttype class=radio type=radio value="free" $checked> | . $locale->text('Free report period') . qq|</th>
|
377 |
|
<td align=left colspan=4>| . $locale->text('From') . qq|
|
378 |
|
$button1
|
379 |
|
$button1_2
|
380 |
|
| . $locale->text('Bis') . qq|
|
381 |
|
$button2
|
382 |
|
$button2_2
|
383 |
|
</td>
|
384 |
|
</tr>
|
385 |
|
<tr>
|
386 |
|
<td colspan=5><hr size=3 noshade></td>
|
387 |
|
</tr>
|
388 |
|
<tr>
|
389 |
|
<th align=leftt>| . $locale->text('Method') . qq|</th>
|
390 |
|
<td colspan=3><input name=method class=radio type=radio value=accrual $accrual>| . $locale->text('Accrual') . qq|
|
391 |
|
<input name=method class=radio type=radio value=cash $cash>| . $locale->text('EUR') . qq|</td>
|
392 |
|
</tr>
|
393 |
|
|
394 |
|
$jsscript
|
395 |
|
|;
|
396 |
|
}
|
397 |
|
|
398 |
|
if ($form->{report} eq "bwa") {
|
399 |
|
print qq|
|
400 |
|
<tr>
|
401 |
|
<th align=right nowrap>| . $locale->text('Project') . qq|</th>
|
402 |
|
<td colspan=3>$projectnumber</td>
|
403 |
|
</tr>
|
404 |
|
<input type=hidden name=nextsub value=generate_bwa>
|
405 |
|
</table>
|
406 |
|
<table>
|
407 |
|
<tr>
|
408 |
|
<th align=left><input name=reporttype class=radio type=radio value="custom" checked> | . $locale->text('Customized Report') . qq|</th>
|
409 |
|
</tr>
|
410 |
|
<tr>
|
411 |
|
<th colspan=1>| . $locale->text('Year') . qq|</th>
|
412 |
|
<td><input name=year size=11 title="| . $locale->text('YYYY') . qq|" value="$year"></td>
|
413 |
|
</tr>
|
414 |
|
|;
|
415 |
|
|
416 |
|
print qq|
|
417 |
|
<tr>
|
418 |
|
<td align=right> <b> | . $locale->text('Yearly') . qq|</b> </td>
|
419 |
|
<th align=left>| . $locale->text('Quarterly') . qq|</th>
|
420 |
|
<th align=left colspan=3>| . $locale->text('Monthly') . qq|</th>
|
421 |
|
</tr>
|
422 |
|
<tr>
|
423 |
|
<td align=right> <input name=duetyp class=radio type=radio value="13"
|
424 |
|
$checked></td>
|
425 |
|
<td><input name=duetyp class=radio type=radio value="A" $checked > 1. | . $locale->text('Quarter') . qq|</td>
|
426 |
|
|;
|
427 |
|
$checked = "checked";
|
428 |
|
print qq|
|
429 |
|
<td><input name=duetyp class=radio type=radio value="1" $checked > | . $locale->text('January') . qq|</td>
|
430 |
|
|;
|
431 |
|
$checked = "";
|
432 |
|
print qq|
|
433 |
|
<td><input name=duetyp class=radio type=radio value="5" $checked > | . $locale->text('May') . qq|</td>
|
434 |
|
<td><input name=duetyp class=radio type=radio value="9" $checked > | . $locale->text('September') . qq|</td>
|
435 |
|
|
436 |
|
</tr>
|
437 |
|
<tr>
|
438 |
|
<td align= right> </td>
|
439 |
|
<td><input name=duetyp class=radio type=radio value="B" $checked> 2. | . $locale->text('Quarter') . qq|</td>
|
440 |
|
<td><input name=duetyp class=radio type=radio value="2" $checked > | . $locale->text('February') . qq|</td>
|
441 |
|
<td><input name=duetyp class=radio type=radio value="6" $checked > | . $locale->text('June') . qq|</td>
|
442 |
|
<td><input name=duetyp class=radio type=radio value="10" $checked > | . $locale->text('October') . qq|</td>
|
443 |
|
</tr>
|
444 |
|
<tr>
|
445 |
|
<td> </td>
|
446 |
|
<td><input name=duetyp class=radio type=radio value="C" $checked> 3. | . $locale->text('Quarter') . qq|</td>
|
447 |
|
<td><input name=duetyp class=radio type=radio value="3" $checked > | . $locale->text('March') . qq|</td>
|
448 |
|
<td><input name=duetyp class=radio type=radio value="7" $checked > | . $locale->text('July') . qq|</td>
|
449 |
|
<td><input name=duetyp class=radio type=radio value="11" $checked > | . $locale->text('November') . qq|</td>
|
450 |
|
|
451 |
|
</tr>
|
452 |
|
<tr>
|
453 |
|
<td> </td>
|
454 |
|
<td><input name=duetyp class=radio type=radio value="D" $checked> 4. | . $locale->text('Quarter') . qq| </td>
|
455 |
|
<td><input name=duetyp class=radio type=radio value="4" $checked > | . $locale->text('April') . qq|</td>
|
456 |
|
<td><input name=duetyp class=radio type=radio value="8" $checked > | . $locale->text('August') . qq|</td>
|
457 |
|
<td><input name=duetyp class=radio type=radio value="12" $checked > | . $locale->text('December') . qq|</td>
|
458 |
|
|
459 |
|
</tr>
|
460 |
|
<tr>
|
461 |
|
<td colspan=5><hr size=3 noshade></td>
|
462 |
|
</tr>
|
463 |
|
<tr>
|
464 |
|
<th align=left><input name=reporttype class=radio type=radio value="free" $checked> | . $locale->text('Free report period') . qq|</th>
|
465 |
|
<td align=left colspan=4>| . $locale->text('From') . qq|
|
466 |
|
$button1
|
467 |
|
$button1_2
|
468 |
|
| . $locale->text('Bis') . qq|
|
469 |
|
$button2
|
470 |
|
$button2_2
|
471 |
|
</td>
|
472 |
|
</tr>
|
473 |
|
<tr>
|
474 |
|
<td colspan=5><hr size=3 noshade></td>
|
475 |
|
</tr>
|
476 |
|
<tr>
|
477 |
|
<th align=leftt>| . $locale->text('Method') . qq|</th>
|
478 |
|
<td colspan=3><input name=method class=radio type=radio value=accrual $accrual>| . $locale->text('Accrual') . qq|
|
479 |
|
<input name=method class=radio type=radio value=cash $cash>| . $locale->text('EUR') . qq|</td>
|
480 |
|
</tr>
|
481 |
|
<tr>
|
482 |
|
<th align=right colspan=4>| . $locale->text('Decimalplaces') . qq|</th>
|
483 |
|
<td><input name=decimalplaces size=3 value="2"></td>
|
484 |
|
</tr>
|
485 |
|
|
486 |
|
$jsscript
|
487 |
|
|;
|
488 |
|
}
|
489 |
|
|
490 |
|
if ($form->{report} eq "balance_sheet") {
|
491 |
|
print qq|
|
492 |
|
<input type=hidden name=nextsub value=generate_balance_sheet>
|
493 |
|
<tr>
|
494 |
|
<th align=right>| . $locale->text('as at') . qq|</th>
|
495 |
|
<td>
|
496 |
|
$button1
|
497 |
|
$button1_2
|
498 |
|
</td>
|
499 |
|
<th align=right nowrap>| . $locale->text('Compare to') . qq|</th>
|
500 |
|
<td>
|
501 |
|
$button2
|
502 |
|
$button2_2
|
503 |
|
</td>
|
504 |
|
</tr>
|
505 |
|
<tr>
|
506 |
|
<th align=right>| . $locale->text('Decimalplaces') . qq|</th>
|
507 |
|
<td><input name=decimalplaces size=3 value="2"></td>
|
508 |
|
</tr>
|
509 |
|
</table>
|
510 |
|
</td>
|
511 |
|
</tr>
|
512 |
|
<tr>
|
513 |
|
<td>
|
514 |
|
<table>
|
515 |
|
<tr>
|
516 |
|
<th align=right>| . $locale->text('Method') . qq|</th>
|
517 |
|
<td colspan=3><input name=method class=radio type=radio value=accrual $accrual>| . $locale->text('Accrual') . qq|
|
518 |
|
<input name=method class=radio type=radio value=cash $cash>| . $locale->text('EUR') . qq|</td>
|
519 |
|
</tr>
|
520 |
|
|
521 |
|
<tr>
|
522 |
|
<th align=right nowrap>| . $locale->text('Include in Report') . qq|</th>
|
523 |
|
<td><input name=l_heading class=checkbox type=checkbox value=Y> | . $locale->text('Heading') . qq|
|
524 |
|
<input name=l_subtotal class=checkbox type=checkbox value=Y> | . $locale->text('Subtotal') . qq|
|
525 |
|
<input name=l_accno class=checkbox type=checkbox value=Y> | . $locale->text('Account Number') . qq|</td>
|
526 |
|
</tr>
|
527 |
155 |
|
528 |
|
$jsscript
|
529 |
|
|;
|
530 |
|
}
|
531 |
|
|
532 |
|
if ($form->{report} eq "trial_balance") {
|
533 |
|
print qq|
|
534 |
|
<tr>
|
535 |
|
<th align=right nowrap>| . $locale->text('Project') . qq|</th>
|
536 |
|
<td colspan=3>$projectnumber</td>
|
537 |
|
</tr>
|
538 |
|
<input type=hidden name=nextsub value=generate_trial_balance>
|
539 |
|
</table>
|
540 |
|
<table>
|
541 |
|
<tr>
|
542 |
|
<th align=left><input name=reporttype class=radio type=radio value="custom" checked> | . $locale->text('Customized Report') . qq|</th>
|
543 |
|
</tr>
|
544 |
|
<tr>
|
545 |
|
<th colspan=1>| . $locale->text('Year') . qq|</th>
|
546 |
|
<td><input name=year size=11 title="| . $locale->text('YYYY') . qq|" value="$year"></td>
|
547 |
|
</tr>
|
548 |
|
|;
|
549 |
|
|
550 |
|
print qq|
|
551 |
|
<tr>
|
552 |
|
<td align=right> <b> | . $locale->text('Yearly') . qq|</b> </td>
|
553 |
|
<th align=left>| . $locale->text('Quarterly') . qq|</th>
|
554 |
|
<th align=left colspan=3>| . $locale->text('Monthly') . qq|</th>
|
555 |
|
</tr>
|
556 |
|
<tr>
|
557 |
|
<td align=right> <input name=duetyp class=radio type=radio value="13" $checked></td>
|
558 |
|
<td><input name=duetyp class=radio type=radio value="A" $checked > 1. | . $locale->text('Quarter') . qq|</td>
|
559 |
|
|;
|
560 |
|
$checked = "checked";
|
561 |
|
print qq|
|
562 |
|
<td><input name=duetyp class=radio type=radio value="1" $checked > | . $locale->text('January') . qq|</td>
|
563 |
|
|;
|
564 |
|
$checked = "";
|
565 |
|
print qq|
|
566 |
|
<td><input name=duetyp class=radio type=radio value="5" $checked > | . $locale->text('May') . qq|</td>
|
567 |
|
<td><input name=duetyp class=radio type=radio value="9" $checked > | . $locale->text('September') . qq|</td>
|
568 |
|
|
569 |
|
</tr>
|
570 |
|
<tr>
|
571 |
|
<td align= right> </td>
|
572 |
|
<td><input name=duetyp class=radio type=radio value="B" $checked> 2. | . $locale->text('Quarter') . qq|</td>
|
573 |
|
<td><input name=duetyp class=radio type=radio value="2" $checked > | . $locale->text('February') . qq|</td>
|
574 |
|
<td><input name=duetyp class=radio type=radio value="6" $checked > | . $locale->text('June') . qq|</td>
|
575 |
|
<td><input name=duetyp class=radio type=radio value="10" $checked > | . $locale->text('October') . qq|</td>
|
576 |
|
</tr>
|
577 |
|
<tr>
|
578 |
|
<td> </td>
|
579 |
|
<td><input name=duetyp class=radio type=radio value="C" $checked> 3. | . $locale->text('Quarter') . qq|</td>
|
580 |
|
<td><input name=duetyp class=radio type=radio value="3" $checked > | . $locale->text('March') . qq|</td>
|
581 |
|
<td><input name=duetyp class=radio type=radio value="7" $checked > | . $locale->text('July') . qq|</td>
|
582 |
|
<td><input name=duetyp class=radio type=radio value="11" $checked > | . $locale->text('November') . qq|</td>
|
583 |
|
|
584 |
|
</tr>
|
585 |
|
<tr>
|
586 |
|
<td> </td>
|
587 |
|
<td><input name=duetyp class=radio type=radio value="D" $checked> 4. | . $locale->text('Quarter') . qq| </td>
|
588 |
|
<td><input name=duetyp class=radio type=radio value="4" $checked > | . $locale->text('April') . qq|</td>
|
589 |
|
<td><input name=duetyp class=radio type=radio value="8" $checked > | . $locale->text('August') . qq|</td>
|
590 |
|
<td><input name=duetyp class=radio type=radio value="12" $checked > | . $locale->text('December') . qq|</td>
|
591 |
|
|
592 |
|
</tr>
|
593 |
|
<tr>
|
594 |
|
<td colspan=5><hr size=3 noshade></td>
|
595 |
|
</tr>
|
596 |
|
<tr>
|
597 |
|
<th align=left><input name=reporttype class=radio type=radio value="free" $checked> | . $locale->text('Free report period') . qq|</th>
|
598 |
|
<td align=left colspan=4>| . $locale->text('From') . qq|
|
599 |
|
$button1
|
600 |
|
$button1_2
|
601 |
|
| . $locale->text('Bis') . qq|
|
602 |
|
$button2
|
603 |
|
$button2_2
|
604 |
|
</td>
|
605 |
|
</tr>
|
606 |
|
<tr>
|
607 |
|
<td colspan=5><hr size=3 noshade></td>
|
608 |
|
</tr>
|
609 |
|
<tr>
|
610 |
|
<th align=leftt>| . $locale->text('Method') . qq|</th>
|
611 |
|
<td colspan=3><input name=method class=radio type=radio value=accrual $accrual>| . $locale->text('Accrual') . qq|
|
612 |
|
<input name=method class=radio type=radio value=cash $cash>| . $locale->text('EUR') . qq|</td>
|
613 |
|
</tr>
|
614 |
|
<tr>
|
615 |
|
<th align=right colspan=4>| . $locale->text('All Accounts') . qq|</th>
|
616 |
|
<td><input name=all_accounts type=checkbox value=1></td>
|
617 |
|
</tr>
|
618 |
|
<tr>
|
619 |
|
<th align=right colspan=4>| . $locale->text('Decimalplaces') . qq|</th>
|
620 |
|
<td><input name=decimalplaces size=3 value="2"></td>
|
621 |
|
</tr>
|
622 |
|
|
623 |
|
$jsscript
|
624 |
|
|;
|
625 |
|
}
|
626 |
|
|
627 |
|
if ($form->{report} =~ /^tax_/) {
|
628 |
|
$form->{db} = ($form->{report} =~ /_collected/) ? "ar" : "ap";
|
629 |
|
|
630 |
|
RP->get_taxaccounts(\%myconfig, \%$form);
|
631 |
|
|
632 |
|
print qq|
|
633 |
|
<input type=hidden name=nextsub value=generate_tax_report>
|
634 |
|
<tr>
|
635 |
|
<th align=right>| . $locale->text('From') . qq|</th>
|
636 |
|
<td><input name=fromdate size=11 title="$myconfig{dateformat}" value=$form->{fromdate}></td>
|
637 |
|
<th align=right>| . $locale->text('Bis') . qq|</th>
|
638 |
|
<td><input name=todate size=11 title="$myconfig{dateformat}"></td>
|
639 |
|
</tr>
|
640 |
|
<tr>
|
641 |
|
<th align=right>| . $locale->text('Report for') . qq|</th>
|
642 |
|
<td colspan=3>
|
643 |
|
|;
|
644 |
|
|
645 |
|
$checked = "checked";
|
646 |
|
foreach my $ref (@{ $form->{taxaccounts} }) {
|
647 |
|
|
648 |
|
print
|
649 |
|
qq|<input name=accno class=radio type=radio value=$ref->{accno} $checked> $ref->{description}
|
650 |
|
|
651 |
|
<input name="$ref->{accno}_description" type=hidden value="$ref->{description}">
|
652 |
|
<input name="$ref->{accno}_rate" type=hidden value="$ref->{rate}">|;
|
653 |
|
|
654 |
|
$checked = "";
|
655 |
|
|
656 |
|
}
|
657 |
|
|
658 |
|
print qq|
|
659 |
|
<input type=hidden name=db value=$form->{db}>
|
660 |
|
<input type=hidden name=sort value=transdate>
|
661 |
|
|
662 |
|
</td>
|
663 |
|
</tr>
|
664 |
|
<tr>
|
665 |
|
<th align=right>| . $locale->text('Method') . qq|</th>
|
666 |
|
<td colspan=3><input name=method class=radio type=radio value=accrual $accrual>| . $locale->text('Accrual') . qq|
|
667 |
|
<input name=method class=radio type=radio value=cash $cash>| . $locale->text('EUR') . qq|</td>
|
668 |
|
</tr>
|
669 |
|
</table>
|
670 |
|
</td>
|
671 |
|
</tr>
|
672 |
|
<tr>
|
673 |
|
<td>
|
674 |
|
<table>
|
675 |
|
<tr>
|
676 |
|
<th align=right>| . $locale->text('Include in Report') . qq|</th>
|
677 |
|
<td>
|
678 |
|
<table>
|
679 |
|
<tr>
|
680 |
|
<td><input name="l_id" class=checkbox type=checkbox value=Y></td>
|
681 |
|
<td>| . $locale->text('ID') . qq|</td>
|
682 |
|
<td><input name="l_invnumber" class=checkbox type=checkbox value=Y checked></td>
|
683 |
|
<td>| . $locale->text('Invoice') . qq|</td>
|
684 |
|
<td><input name="l_transdate" class=checkbox type=checkbox value=Y checked></td>
|
685 |
|
<td>| . $locale->text('Date') . qq|</td>
|
686 |
|
</tr>
|
687 |
|
<tr>
|
688 |
|
<td><input name="l_name" class=checkbox type=checkbox value=Y checked></td>
|
689 |
|
<td>|;
|
690 |
|
|
691 |
|
if ($form->{db} eq 'ar') {
|
692 |
|
print $locale->text('Customer');
|
693 |
|
}
|
694 |
|
if ($form->{db} eq 'ap') {
|
695 |
|
print $locale->text('Vendor');
|
696 |
|
}
|
697 |
|
|
698 |
|
print qq|</td>
|
699 |
|
<td><input name="l_netamount" class=checkbox type=checkbox value=Y checked></td>
|
700 |
|
<td>| . $locale->text('Amount') . qq|</td>
|
701 |
|
<td><input name="l_tax" class=checkbox type=checkbox value=Y checked></td>
|
702 |
|
<td>| . $locale->text('Tax') . qq|</td>
|
703 |
|
<td><input name="l_amount" class=checkbox type=checkbox value=Y></td>
|
704 |
|
<td>| . $locale->text('Total') . qq|</td>
|
705 |
|
</tr>
|
706 |
|
<tr>
|
707 |
|
<td><input name="l_subtotal" class=checkbox type=checkbox value=Y></td>
|
708 |
|
<td>| . $locale->text('Subtotal') . qq|</td>
|
709 |
|
</tr>
|
710 |
|
</table>
|
711 |
|
</td>
|
712 |
|
</tr>
|
713 |
|
|;
|
714 |
|
|
715 |
|
}
|
716 |
|
|
717 |
|
if ($form->{report} =~ /^nontaxable_/) {
|
718 |
|
$form->{db} = ($form->{report} =~ /_sales/) ? "ar" : "ap";
|
719 |
|
|
720 |
|
print qq|
|
721 |
|
<input type=hidden name=nextsub value=generate_tax_report>
|
722 |
|
|
723 |
|
<input type=hidden name=db value=$form->{db}>
|
724 |
|
<input type=hidden name=sort value=transdate>
|
725 |
|
<input type=hidden name=report value=$form->{report}>
|
726 |
|
|
727 |
|
<tr>
|
728 |
|
<th align=right>| . $locale->text('From') . qq|</th>
|
729 |
|
<td><input name=fromdate size=11 title="$myconfig{dateformat}" value=$form->{fromdate}></td>
|
730 |
|
<th align=right>| . $locale->text('Bis') . qq|</th>
|
731 |
|
<td><input name=todate size=11 title="$myconfig{dateformat}"></td>
|
732 |
|
</tr>
|
733 |
|
<tr>
|
734 |
|
<th align=right>| . $locale->text('Method') . qq|</th>
|
735 |
|
<td colspan=3><input name=method class=radio type=radio value=accrual $accrual>|
|
736 |
|
. $locale->text('Accrual') . qq|
|
737 |
|
<input name=method class=radio type=radio value=cash $cash>|
|
738 |
|
. $locale->text('EUR') . qq|</td>
|
739 |
|
</tr>
|
740 |
|
<tr>
|
741 |
|
<th align=right>| . $locale->text('Include in Report') . qq|</th>
|
742 |
|
<td colspan=3>
|
743 |
|
<table>
|
744 |
|
<tr>
|
745 |
|
<td><input name="l_id" class=checkbox type=checkbox value=Y></td>
|
746 |
|
<td>| . $locale->text('ID') . qq|</td>
|
747 |
|
<td><input name="l_invnumber" class=checkbox type=checkbox value=Y checked></td>
|
748 |
|
<td>| . $locale->text('Invoice') . qq|</td>
|
749 |
|
<td><input name="l_transdate" class=checkbox type=checkbox value=Y checked></td>
|
750 |
|
<td>| . $locale->text('Date') . qq|</td>
|
751 |
|
</tr>
|
752 |
|
<tr>
|
753 |
|
<td><input name="l_name" class=checkbox type=checkbox value=Y checked></td>
|
754 |
|
<td>|;
|
755 |
|
|
756 |
|
if ($form->{db} eq 'ar') {
|
757 |
|
print $locale->text('Customer');
|
758 |
|
}
|
759 |
|
if ($form->{db} eq 'ap') {
|
760 |
|
print $locale->text('Vendor');
|
761 |
|
}
|
762 |
|
|
763 |
|
print qq|</td>
|
764 |
|
<td><input name="l_netamount" class=checkbox type=checkbox value=Y checked></td>
|
765 |
|
<td>| . $locale->text('Amount') . qq|</td>
|
766 |
|
<td><input name="l_amount" class=checkbox type=checkbox value=Y></td>
|
767 |
|
<td>| . $locale->text('Total') . qq|</td>
|
768 |
|
</tr>
|
769 |
|
<tr>
|
770 |
|
<td><input name="l_subtotal" class=checkbox type=checkbox value=Y></td>
|
771 |
|
<td>| . $locale->text('Subtotal') . qq|</td>
|
772 |
|
</tr>
|
773 |
|
</table>
|
774 |
|
</td>
|
775 |
|
</tr>
|
776 |
|
|;
|
777 |
|
|
778 |
|
}
|
|
156 |
my $is_projects = $::form->{report} eq "projects";
|
|
157 |
my $is_income_statement = $::form->{report} eq "income_statement";
|
|
158 |
my $is_bwa = $::form->{report} eq "bwa";
|
|
159 |
my $is_balance_sheet = $::form->{report} eq "balance_sheet";
|
|
160 |
my $is_trial_balance = $::form->{report} eq "trial_balance";
|
|
161 |
my $is_taxreport = $::form->{report} =~ /^tax_/;
|
|
162 |
my $is_nontaxable = $::form->{report} =~ /^nontaxable_/;
|
|
163 |
my $is_aging = $::form->{report} =~ /^a[rp]_aging$/;
|
|
164 |
my $is_payments = $::form->{report} =~ /(receipts|payments)$/;
|
|
165 |
|
|
166 |
# if (is_taxreport) {
|
|
167 |
# $::form->{db} = ($::form->{report} =~ /_collected/) ? "ar" : "ap";
|
|
168 |
# RP->get_taxaccounts(\%::myconfig, $::form);
|
|
169 |
# }
|
|
170 |
#
|
|
171 |
# if ($is_nontaxable) {
|
|
172 |
# $::form->{db} = ($::form->{report} =~ /_sales/) ? "ar" : "ap";
|
|
173 |
# }
|
779 |
174 |
|
780 |
175 |
my ($label, $nextsub, $vc);
|
781 |
|
if (($form->{report} eq "ar_aging") || ($form->{report} eq "ap_aging")) {
|
782 |
|
if ($form->{report} eq 'ar_aging') {
|
783 |
|
$label = $locale->text('Customer');
|
784 |
|
$form->{vc} = 'customer';
|
785 |
|
} else {
|
786 |
|
$label = $locale->text('Vendor');
|
787 |
|
$form->{vc} = 'vendor';
|
788 |
|
}
|
|
176 |
if ($is_aging) {
|
|
177 |
my $is_sales = $::form->{report} eq 'ar_aging';
|
|
178 |
$label = $is_sales ? $::locale->text('Customer') : $::locale->text('Vendor');
|
|
179 |
$::form->{vc} = $is_sales ? 'customer' : 'vendor';
|
789 |
180 |
|
790 |
|
$nextsub = "generate_$form->{report}";
|
|
181 |
$nextsub = "generate_$::form->{report}";
|
791 |
182 |
|
792 |
183 |
# setup vc selection
|
793 |
|
$form->all_vc(\%myconfig, $form->{vc},
|
794 |
|
($form->{vc} eq 'customer') ? "AR" : "AP");
|
795 |
|
|
796 |
|
map { $vc .= "<option>$_->{name}--$_->{id}\n" }
|
797 |
|
@{ $form->{"all_$form->{vc}"} };
|
798 |
|
|
799 |
|
$vc =
|
800 |
|
($vc)
|
801 |
|
? qq|<select name=$form->{vc}><option>\n$vc</select>|
|
802 |
|
: qq|<input name=$form->{vc} size=35>|;
|
803 |
|
|
804 |
|
print qq|
|
805 |
|
<tr>
|
806 |
|
<th align=right>| . $locale->text($label) . qq|</th>
|
807 |
|
<td>$vc</td>
|
808 |
|
</tr>
|
809 |
|
<tr>
|
810 |
|
<td>| . $locale->text('Review of Aging list') . qq|</td>
|
811 |
|
<td><select name="review_of_aging_list">
|
812 |
|
<option></option>
|
813 |
|
<option>0-30</option>
|
814 |
|
<option>30-60</option>
|
815 |
|
<option>60-90</option>
|
816 |
|
<option>90-120</option>
|
817 |
|
<option>> 120</option>
|
818 |
|
</select>
|
819 |
|
</td>
|
820 |
|
</tr>
|
821 |
|
<tr>
|
822 |
|
<td align=left colspan=4>| . $locale->text('From') . qq|
|
823 |
|
$button1
|
824 |
|
$button1_2
|
825 |
|
| . $locale->text('Bis') . qq|
|
826 |
|
$button2
|
827 |
|
$button2_2
|
828 |
|
</td>
|
829 |
|
</tr>
|
830 |
|
<input type=hidden name=type value=statement>
|
831 |
|
<input type=hidden name=format value=html>
|
832 |
|
<input type=hidden name=media value=screen>
|
833 |
|
|
834 |
|
<input type=hidden name=nextsub value=$nextsub>
|
835 |
|
<input type=hidden name=action value=$nextsub>
|
836 |
|
|
837 |
|
$jsscript
|
838 |
|
|;
|
|
184 |
$::form->all_vc(\%::myconfig, $::form->{vc}, $is_sales ? "AR" : "AP");
|
|
185 |
$vc .= "<option>$_->{name}--$_->{id}\n" for @{ $::form->{"all_$::form->{vc}"} };
|
|
186 |
$vc = ($vc)
|
|
187 |
? qq|<select name=$::form->{vc}><option>\n$vc</select>|
|
|
188 |
: qq|<input name=$::form->{vc} size=35>|;
|
839 |
189 |
}
|
840 |
190 |
|
841 |
|
# above action can be removed if there is more than one input field
|
842 |
|
|
843 |
191 |
my ($selection, $paymentaccounts);
|
844 |
|
if ($form->{report} =~ /(receipts|payments)$/) {
|
845 |
|
$form->{db} = ($form->{report} =~ /payments$/) ? "ap" : "ar";
|
|
192 |
if ($is_payments) {
|
|
193 |
$::form->{db} = $::form->{report} =~ /payments$/ ? "ap" : "ar";
|
846 |
194 |
|
847 |
|
RP->paymentaccounts(\%myconfig, \%$form);
|
|
195 |
RP->paymentaccounts(\%::myconfig, $::form);
|
848 |
196 |
|
849 |
197 |
$selection = "<option>\n";
|
850 |
|
foreach my $ref (@{ $form->{PR} }) {
|
|
198 |
for my $ref (@{ $::form->{PR} }) {
|
851 |
199 |
$paymentaccounts .= "$ref->{accno} ";
|
852 |
200 |
$selection .= "<option>$ref->{accno}--$ref->{description}\n";
|
853 |
201 |
}
|
854 |
|
|
855 |
|
chop $paymentaccounts;
|
856 |
|
|
857 |
|
print qq|
|
858 |
|
<input type=hidden name=nextsub value=list_payments>
|
859 |
|
<tr>
|
860 |
|
<th align=right nowrap>| . $locale->text('Account') . qq|</th>
|
861 |
|
<td colspan=3><select name=account>$selection</select>
|
862 |
|
<input type=hidden name=paymentaccounts value="$paymentaccounts">
|
863 |
|
</td>
|
864 |
|
</tr>
|
865 |
|
<tr>
|
866 |
|
<th align=right>| . $locale->text('Reference') . qq|</th>
|
867 |
|
<td colspan=3><input name=reference></td>
|
868 |
|
</tr>
|
869 |
|
<tr>
|
870 |
|
<th align=right nowrap>| . $locale->text('Source') . qq|</th>
|
871 |
|
<td colspan=3><input name=source></td>
|
872 |
|
</tr>
|
873 |
|
<tr>
|
874 |
|
<th align=right nowrap>| . $locale->text('Memo') . qq|</th>
|
875 |
|
<td colspan=3><input name=memo size=30></td>
|
876 |
|
</tr>
|
877 |
|
<tr>
|
878 |
|
<th align=right>| . $locale->text('From') . qq|</th>
|
879 |
|
<td>
|
880 |
|
$button1
|
881 |
|
$button1_2
|
882 |
|
</td>
|
883 |
|
<th align=right>| . $locale->text('Bis') . qq|</th>
|
884 |
|
<td>
|
885 |
|
$button2
|
886 |
|
$button2_2
|
887 |
|
</td>
|
888 |
|
</tr>
|
889 |
|
<tr>
|
890 |
|
<td align=right><input type=checkbox style=checkbox name=fx_transaction value=1 checked></td>
|
891 |
|
<th align=left colspan=3>| . $locale->text('Include Exchangerate Difference') . qq|</td>
|
892 |
|
</tr>
|
893 |
|
|
894 |
|
$jsscript
|
895 |
|
|
896 |
|
<input type=hidden name=db value=$form->{db}>
|
897 |
|
<input type=hidden name=sort value=transdate>
|
898 |
|
|;
|
899 |
|
|
900 |
202 |
}
|
901 |
203 |
|
902 |
|
print qq|
|
903 |
|
|
904 |
|
</table>
|
905 |
|
</td>
|
906 |
|
</tr>
|
907 |
|
<tr>
|
908 |
|
<td><hr size=3 noshade></td>
|
909 |
|
</tr>
|
910 |
|
</table>
|
911 |
|
|
912 |
|
<br>
|
913 |
|
<input type=submit class=submit name=action value="| . $locale->text('Continue') . qq|">
|
914 |
|
|
915 |
|
</form>
|
916 |
|
|
917 |
|
</body>
|
918 |
|
</html>
|
919 |
|
|;
|
|
204 |
$::form->header;
|
|
205 |
print $::form->parse_html_template('rp/report', {
|
|
206 |
paymentaccounts => $paymentaccounts,
|
|
207 |
selection => $selection,
|
|
208 |
is_aging => $is_aging,
|
|
209 |
vc => $vc,
|
|
210 |
label => $label,
|
|
211 |
year => DateTime->today->year,
|
|
212 |
onload => $onload,
|
|
213 |
accrual => $::instance_conf->get_accounting_method ne 'cash',
|
|
214 |
cash => $::instance_conf->get_accounting_method eq 'cash',
|
|
215 |
is_payments => $is_payments,
|
|
216 |
is_trial_balance => $is_trial_balance,
|
|
217 |
is_balance_sheet => $is_balance_sheet,
|
|
218 |
is_bwa => $is_bwa,
|
|
219 |
is_income_statement => $is_income_statement,
|
|
220 |
is_projects => $is_projects,
|
|
221 |
});
|
920 |
222 |
|
921 |
|
$main::lxdebug->leave_sub();
|
|
223 |
$::lxdebug->leave_sub;
|
922 |
224 |
}
|
923 |
225 |
|
924 |
226 |
sub continue { call_sub($main::form->{"nextsub"}); }
|
rp.pl::report auf template umgestellt.
Bei der Umstellung sind die folgenden vier Funktionalitäten aufgefallen:
- tax_collected
- tax_apid
- nontaxable_purchases
- nontaxable_sales
Diese 4 Funktionen waren schon in der ältesten erhaltenen git Version von
Lx-Office deaktiviert, und laut Moritz nur für den amerikanischen Markt
brauchbar. Ich habe die Grundfunktionalität erhalten, und die HTML Blöcke
mitportiert, aber unkonditional deaktiviert. Ausserdem werden die dispatching
Variablen nicht an das Template weitergereicht.
Im gleichen Zuge ist die Funktion RP->get_taxaccounts aufgefallen. Die wird
anscheinend nur von den oben genannten benutzt und enthält seit 2007 einen
Typo, der sie nutzlos macht (ISE beim Aufruf). Da das nie aufgefallen ist, wird
sie wohl nicht anderweitig benutzt. Ich entferne sie nicht in diesem Commit,
weil es nichts mit der template Umstellung zu tun hat.