summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authoreinhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46>2008-01-12 06:23:30 +0000
committereinhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46>2008-01-12 06:23:30 +0000
commitf058158efb8dae52129bd78526a62af6ed69c2a1 (patch)
tree055151d3c4b07e4c97bb0ed913163f7cb6fe3fc6 /bin
parente348cc7c0ed47b6995fc3dad9a9eb107e1a9ba00 (diff)
Fixing 1812792, (discount box blank after part lookup in ir.pl) and similar bugs in is.pl and oe.pl
git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/branches/1.2@2041 4979c152-3d1c-0410-bac9-87ea11338e46
Diffstat (limited to 'bin')
-rwxr-xr-xbin/ir.pl7
-rwxr-xr-xbin/is.pl6
-rwxr-xr-xbin/oe.pl6
3 files changed, 9 insertions, 10 deletions
diff --git a/bin/ir.pl b/bin/ir.pl
index 9d38f5f9..ba3c3524 100755
--- a/bin/ir.pl
+++ b/bin/ir.pl
@@ -798,7 +798,6 @@ sub update {
if ( $form->{import_text} ) {
&import_text;
}
-
$form->{exchangerate} =
$form->parse_amount( \%myconfig, $form->{exchangerate} );
@@ -932,9 +931,9 @@ sub update {
for ( keys %{ $form->{item_list}[0] } ) {
$form->{"${_}_$i"} = $form->{item_list}[0]{$_};
}
-
- $form->{"discount_$i"} = $form->{discount} * 100;
-
+ if (! defined $form->{"discount_$i"}){
+ $form->{"discount_$i"} = $form->{discount} * 100;
+ }
if ($sellprice) {
$form->{"sellprice_$i"} = $sellprice;
diff --git a/bin/is.pl b/bin/is.pl
index 3338018a..f615a234 100755
--- a/bin/is.pl
+++ b/bin/is.pl
@@ -951,9 +951,9 @@ sub update {
for ( keys %{ $form->{item_list}[0] } ) {
$form->{"${_}_$i"} = $form->{item_list}[0]{$_};
}
-
- $form->{"discount_$i"} = $form->{discount} * 100;
-
+ if (! defined $form->{"discount_$i"}){
+ $form->{"discount_$i"} = $form->{discount} * 100;
+ }
if ($sellprice) {
$form->{"sellprice_$i"} = $sellprice;
diff --git a/bin/oe.pl b/bin/oe.pl
index 0d98b5e4..d14167a4 100755
--- a/bin/oe.pl
+++ b/bin/oe.pl
@@ -1048,9 +1048,9 @@ sub update {
for ( keys %{ $form->{item_list}[0] } ) {
$form->{"${_}_$i"} = $form->{item_list}[0]{$_};
}
-
- $form->{"discount_$i"} = $form->{discount} * 100;
-
+ if (! defined $form->{"discount_$i"}){
+ $form->{"discount_$i"} = $form->{discount} * 100;
+ }
if ($sellprice) {
$form->{"sellprice_$i"} = $sellprice;