96 |
96 |
$form->{addition} = "ADDED";
|
97 |
97 |
$form->save_history($form->dbconnect(\%myconfig));
|
98 |
98 |
}
|
99 |
|
# /saving the history
|
100 |
|
|
|
99 |
# /saving the history
|
|
100 |
|
101 |
101 |
$form->{title} = "Add";
|
102 |
102 |
$form->{callback} = "ar.pl?action=add" unless $form->{callback};
|
103 |
103 |
|
... | ... | |
318 |
318 |
|
319 |
319 |
my $n = ($form->{creditremaining} =~ /-/) ? "0" : "1";
|
320 |
320 |
|
321 |
|
$customer = ($form->{selectcustomer})
|
322 |
|
? qq|<select name="customer" onchange="document.getElementById('update_button').click();">$form->{selectcustomer}</select>|
|
|
321 |
$customer = ($form->{selectcustomer})
|
|
322 |
? qq|<select name="customer" onchange="document.getElementById('update_button').click();">$form->{selectcustomer}</select>|
|
323 |
323 |
: qq|<input name=customer value="$form->{customer}" size=35>|;
|
324 |
324 |
|
325 |
325 |
$employee = qq|
|
... | ... | |
685 |
685 |
$column_data{exchangerate} = "<th>" . $locale->text('Exch') . "</th>";
|
686 |
686 |
$column_data{AR_paid} = "<th>" . $locale->text('Account') . "</th>";
|
687 |
687 |
$column_data{source} = "<th>" . $locale->text('Source') . "</th>";
|
688 |
|
$column_data{memo} = "<th>" . $locale->text('Memo') . "</th>";
|
689 |
|
$column_data{paid_project_id} = "<th>" . $locale->text('Project Number') . "</th>";
|
|
688 |
$column_data{memo} = "<th>" . $locale->text('Memo') . "</th>";
|
|
689 |
$column_data{paid_project_id} = "<th>" . $locale->text('Project Number') . "</th>";
|
690 |
690 |
|
691 |
691 |
print "
|
692 |
692 |
<tr>
|
... | ... | |
883 |
883 |
print qq| <input type=button class=submit onclick=set_history_window($form->{id}); name=history id=history value=| . $locale->text('history') . qq|> |;
|
884 |
884 |
}
|
885 |
885 |
# /button for saving history
|
886 |
|
# mark_as_paid button
|
887 |
|
if($form->{id} ne "") {
|
888 |
|
print qq|<input type="submit" class="submit" name="action" value="|
|
|
886 |
# mark_as_paid button
|
|
887 |
if($form->{id} ne "") {
|
|
888 |
print qq|<input type="submit" class="submit" name="action" value="|
|
889 |
889 |
. $locale->text('mark as paid') . qq|">|;
|
890 |
890 |
}
|
891 |
891 |
# /mark_as_paid button
|
... | ... | |
905 |
905 |
|
906 |
906 |
$auth->assert('general_ledger');
|
907 |
907 |
|
908 |
|
&mark_as_paid_common(\%myconfig,"ar");
|
|
908 |
&mark_as_paid_common(\%myconfig,"ar");
|
909 |
909 |
|
910 |
910 |
$lxdebug->leave_sub();
|
911 |
911 |
}
|
... | ... | |
1064 |
1064 |
my $transdate = $form->datetonum($form->{transdate}, \%myconfig);
|
1065 |
1065 |
$form->error($locale->text('Cannot post transaction for a closed period!')) if ($form->date_closed($form->{"transdate"}, \%myconfig));
|
1066 |
1066 |
|
1067 |
|
$form->error($locale->text('Zero amount posting!'))
|
|
1067 |
$form->error($locale->text('Zero amount posting!'))
|
1068 |
1068 |
unless grep $_*1, map $form->parse_amount(\%myconfig, $form->{"amount_$_"}), 1..$form->{rowcount};
|
1069 |
1069 |
|
1070 |
1070 |
$form->isblank("exchangerate", $locale->text('Exchangerate missing!'))
|
... | ... | |
1108 |
1108 |
$form->{addition} = "POSTED";
|
1109 |
1109 |
$form->save_history($form->dbconnect(\%myconfig));
|
1110 |
1110 |
}
|
1111 |
|
# /saving the history
|
|
1111 |
# /saving the history
|
1112 |
1112 |
remove_draft() if $form->{remove_draft};
|
1113 |
1113 |
|
1114 |
1114 |
$form->redirect($locale->text('Transaction posted!')) unless $inline;
|
... | ... | |
1128 |
1128 |
$form->{addition} = "POSTED AS NEW";
|
1129 |
1129 |
$form->save_history($form->dbconnect(\%myconfig));
|
1130 |
1130 |
}
|
1131 |
|
# /saving the history
|
|
1131 |
# /saving the history
|
1132 |
1132 |
&post;
|
1133 |
1133 |
|
1134 |
1134 |
$lxdebug->leave_sub();
|
... | ... | |
1201 |
1201 |
$form->{addition} = "DELETED";
|
1202 |
1202 |
$form->save_history($form->dbconnect(\%myconfig));
|
1203 |
1203 |
}
|
1204 |
|
# /saving the history
|
|
1204 |
# /saving the history
|
1205 |
1205 |
$form->redirect($locale->text('Transaction deleted!'));
|
1206 |
1206 |
}
|
1207 |
1207 |
$form->error($locale->text('Cannot delete transaction!'));
|
... | ... | |
1246 |
1246 |
| if $form->{selectdepartment};
|
1247 |
1247 |
|
1248 |
1248 |
$form->{title} = $locale->text('AR Transactions');
|
1249 |
|
|
|
1249 |
|
1250 |
1250 |
$form->{javascript} .= qq|<script type="text/javascript" src="js/common.js"></script>|;
|
1251 |
|
|
|
1251 |
|
1252 |
1252 |
# use JavaScript Calendar or not
|
1253 |
1253 |
$form->{jsscript} = 1;
|
1254 |
1254 |
$jsscript = "";
|
... | ... | |
1412 |
1412 |
<td align=right><input name="l_transaction_description" class=checkbox type=checkbox value=Y></td>
|
1413 |
1413 |
<td nowrap>| . $locale->text('Transaction description') . qq|</td>
|
1414 |
1414 |
</tr>
|
|
1415 |
<tr>
|
|
1416 |
<td colspan=4 align=left><b>| . $locale->text('Customer') . qq| </td>
|
|
1417 |
</tr>
|
|
1418 |
<tr>
|
|
1419 |
<td align=right><input name="l_customernumber" class=checkbox type=checkbox value=Y></td>
|
|
1420 |
<td nowrap>| . $locale->text('Customer Number') . qq|</td>
|
|
1421 |
<td align=right><input name="l_country" class=checkbox type=checkbox value=Y></td>
|
|
1422 |
<td nowrap>| . $locale->text('Country') . qq|</td>
|
|
1423 |
<td align=right><input name="l_ustid" class=checkbox type=checkbox value=Y></td>
|
|
1424 |
<td nowrap>| . $locale->text('USt-IdNr.') . qq|</td>
|
|
1425 |
<td align=right><input name="l_taxzone" class=checkbox type=checkbox value=Y></td>
|
|
1426 |
<td nowrap>| . $locale->text('Steuersatz') . qq|</td>
|
|
1427 |
</tr>
|
|
1428 |
<tr>
|
|
1429 |
<td align=right><input name="l_payment" class=checkbox type=checkbox value=Y></td>
|
|
1430 |
<td nowrap>| . $locale->text('Payment Terms') . qq|</td>
|
|
1431 |
</tr>
|
|
1432 |
|
1415 |
1433 |
</table>
|
1416 |
1434 |
</td>
|
1417 |
1435 |
</tr>
|
... | ... | |
1480 |
1498 |
@columns =
|
1481 |
1499 |
qw(transdate id type invnumber ordnumber name netamount tax amount paid
|
1482 |
1500 |
datepaid due duedate transaction_description notes salesman employee shippingpoint shipvia
|
1483 |
|
marge_total marge_percent globalprojectnumber);
|
|
1501 |
marge_total marge_percent globalprojectnumber customernumber country ustid taxzone payment_terms);
|
1484 |
1502 |
|
1485 |
1503 |
my @hidden_variables = map { "l_${_}" } @columns;
|
1486 |
1504 |
push @hidden_variables, "l_subtotal", qw(open closed customer invnumber ordnumber transaction_description notes project_id transdatefrom transdateto);
|
... | ... | |
1510 |
1528 |
'globalprojectnumber' => { 'text' => $locale->text('Project Number'), },
|
1511 |
1529 |
'marge_total' => { 'text' => $locale->text('Ertrag'), },
|
1512 |
1530 |
'marge_percent' => { 'text' => $locale->text('Ertrag prozentual'), },
|
|
1531 |
'customernumber' => { 'text' => $locale->text('Customer Number'), },
|
|
1532 |
'country' => { 'text' => $locale->text('Country'), },
|
|
1533 |
'ustid' => { 'text' => $locale->text('USt-IdNr.'), },
|
|
1534 |
'taxzone' => { 'text' => $locale->text('Steuersatz'), },
|
|
1535 |
'payment_terms' => { 'text' => $locale->text('Payment Terms'), },
|
1513 |
1536 |
);
|
1514 |
1537 |
|
1515 |
1538 |
foreach my $name (qw(id transdate duedate invnumber ordnumber name datepaid employee shippingpoint shipvia transaction_description)) {
|
... | ... | |
1657 |
1680 |
$form->{addition} = "STORNO";
|
1658 |
1681 |
$form->save_history($form->dbconnect(\%myconfig));
|
1659 |
1682 |
}
|
1660 |
|
# /saving the history
|
|
1683 |
# /saving the history
|
1661 |
1684 |
|
1662 |
|
$form->redirect(sprintf $locale->text("Transaction %d cancelled."), $form->{storno_id});
|
|
1685 |
$form->redirect(sprintf $locale->text("Transaction %d cancelled."), $form->{storno_id});
|
1663 |
1686 |
|
1664 |
1687 |
$lxdebug->leave_sub();
|
1665 |
1688 |
}
|
Anzeige von Kundendaten in der Verkaufsrechnungssuche.