X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/5570a18e7da5c73191f82c5f71c08eeb7ec6dccb..bcc996e65643:/SL/AM.pm diff --git a/SL/AM.pm b/SL/AM.pm index 7616edbe5..e48f55ac3 100644 --- a/SL/AM.pm +++ b/SL/AM.pm @@ -114,7 +114,7 @@ sub get_account { } # get new accounts (Folgekonto). Find all charts with the same link - $form->{NEWACCOUNT} = $chart_obj->db->dbh->selectall_arrayref('select id, accno,description from chart where link = ? order by accno', {Slice => {}}, $chart_obj->link); + $form->{NEWACCOUNT} = $chart_obj->db->dbh->selectall_arrayref('select id, accno,description from chart where link = ? and id != ? order by accno', {Slice => {}}, $chart_obj->link, $form->{id}); } else { # set to orphaned for new charts, so chart_type can be changed (needed by $AccountIsPosted) $form->{orphaned} = 1; @@ -1305,12 +1305,14 @@ sub get_warehouse { map { $form->{$_} = $ref->{$_} } keys %{ $ref }; $query = <{BINS} = selectall_hashref_query($form, $dbh, $query, conv_i($form->{id}));