projects
/
kivitendo-erp.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4434d67
)
Beim Vergeben von neuen Angebotsnummern etc die "Breite" der Nummernkreisvorlagen...
author
Moritz Bunkus
<m.bunkus@linet-services.de>
Mon, 23 Apr 2007 14:38:34 +0000
(14:38 +0000)
committer
Moritz Bunkus
<m.bunkus@linet-services.de>
Mon, 23 Apr 2007 14:38:34 +0000
(14:38 +0000)
SL/Form.pm
patch
|
blob
|
history
diff --git
a/SL/Form.pm
b/SL/Form.pm
index
b9a13a1
..
252c4c1
100644
(file)
--- a/
SL/Form.pm
+++ b/
SL/Form.pm
@@
-2344,7
+2344,8
@@
sub update_defaults {
$sth->finish;
if ($var =~ /^(.*?)(\d+)$/) {
- $var = "$1" . ($2 + 1);
+ my $new_num = sprintf '%0' . length($2) . 'd', $2 + 1;
+ $var = "${1}${new_num}";
} else {
$var++;
}
@@
-2380,7
+2381,8
@@
sub update_business {
if ($var ne "") {
if ($var =~ /^(.*?)(\d+)$/) {
- $var = "$1" . ($2 + 1);
+ my $new_num = sprintf '%0' . length($2) . 'd', $2 + 1;
+ $var = "${1}${new_num}";
} else {
$var++;
}