X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/kivitendo-erp.git/blobdiff_plain/213317d3ebd9073e68ac4d0cc789b94c377f575e..95155b0d6ddca4b62319edce20397a3ceebac346:/SL/IS.pm diff --git a/SL/IS.pm b/SL/IS.pm index 6b69bb249..e5d61193d 100644 --- a/SL/IS.pm +++ b/SL/IS.pm @@ -2223,5 +2223,24 @@ sub get_pricegroups_for_parts { $main::lxdebug->leave_sub(); } +sub has_storno { + $main::lxdebug->enter_sub(); + + my ($self, $myconfig, $form) = @_; + + $main::lxdebug->leave_sub() and return 0 unless ($form->{id}); + + my $dbh = $form->dbconnect($myconfig); + + my $query = qq|SELECT storno FROM ar WHERE id = ?|; + my ($result) = selectrow_query($form, $dbh, $query, $form->{id}); + + $dbh->disconnect(); + + $main::lxdebug->leave_sub(); + + return $result; +} + 1;