In der Datenbank werden f. Währungen drei Zeichen gespeichert. Eine
Währung mit zwei Zeichen hat dann ein Leerzeichen am Ende und der
Vergleich in den Maske schlägt fehl, wenn es dort bleibt.
$self->{$key} = $ref->{$key};
}
$self->{$key} = $ref->{$key};
}
+ # remove any trailing whitespace
+ $self->{currency} =~ s/\s*$//;
+
my $transdate = "current_date";
if ($self->{transdate}) {
$transdate = $dbh->quote($self->{transdate});
my $transdate = "current_date";
if ($self->{transdate}) {
$transdate = $dbh->quote($self->{transdate});
map { $self->{$_} = $ref->{$_} } values %column_map;
map { $self->{$_} = $ref->{$_} } values %column_map;
+ # remove any trailing whitespace
+ $self->{currency} =~ s/\s*$// if $self->{currency};
+
$main::lxdebug->leave_sub();
}
$main::lxdebug->leave_sub();
}
$ref = selectfirst_hashref_query($form, $dbh, $query, conv_i($form->{id}));
map { $form->{$_} = $ref->{$_} } keys %$ref;
$ref = selectfirst_hashref_query($form, $dbh, $query, conv_i($form->{id}));
map { $form->{$_} = $ref->{$_} } keys %$ref;
+ # remove any trailing whitespace
+ $form->{currency} =~ s/\s*$//;
+
$form->{exchangerate} = $form->get_exchangerate($dbh, $form->{currency}, $form->{invdate}, "sell");
# get shipto
$form->{exchangerate} = $form->get_exchangerate($dbh, $form->{currency}, $form->{invdate}, "sell");
# get shipto
$ref = selectfirst_hashref_query($form, $dbh, $query, $id);
map { $form->{$_} = $ref->{$_} } keys %{ $ref };
$ref = selectfirst_hashref_query($form, $dbh, $query, $id);
map { $form->{$_} = $ref->{$_} } keys %{ $ref };
+ # remove any trailing whitespace
+ $form->{currency} =~ s/\s*$//;
$form->{exchangerate} = $form->get_exchangerate($dbh, $form->{currency}, $form->{invdate}, "buy");
$form->{exchangerate} = $form->get_exchangerate($dbh, $form->{currency}, $form->{invdate}, "buy");
if ($ref) {
map { $form->{$_} = $ref->{$_} } keys %$ref;
if ($ref) {
map { $form->{$_} = $ref->{$_} } keys %$ref;
+ # remove any trailing whitespace
+ $form->{currency} =~ s/\s*$//;
+
$form->{saved_xyznumber} = $form->{$form->{type} =~ /_quotation$/ ? "quonumber" : "ordnumber"};
# set all entries for multiple ids blank that yield different information
$form->{saved_xyznumber} = $form->{$form->{type} =~ /_quotation$/ ? "quonumber" : "ordnumber"};
# set all entries for multiple ids blank that yield different information