X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/5239714c7d8af2d633ad05a91648b4dbe432a41e..aeeea53192101dd80e4f3a5fae86b0e979bff1e5:/SL/IC.pm diff --git a/SL/IC.pm b/SL/IC.pm index 2b3abf63b..a39e8ae8d 100644 --- a/SL/IC.pm +++ b/SL/IC.pm @@ -25,7 +25,8 @@ # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software -# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, +# MA 02110-1335, USA. #====================================================================== # # Inventory Control backend @@ -91,42 +92,6 @@ sub retrieve_buchungsgruppen { $main::lxdebug->leave_sub(); } -sub retrieve_assemblies { - $main::lxdebug->enter_sub(); - - my ($self, $myconfig, $form) = @_; - - # connect to database - my $dbh = $form->get_standard_dbh; - - my $where = qq|NOT p.obsolete|; - my @values; - - if ($form->{partnumber}) { - $where .= qq| AND (p.partnumber ILIKE ?)|; - push(@values, like($form->{partnumber})); - } - - if ($form->{description}) { - $where .= qq| AND (p.description ILIKE ?)|; - push(@values, like($form->{description})); - } - - # retrieve assembly items - my $query = - qq|SELECT p.id, p.partnumber, p.description, - p.onhand, p.rop, - (SELECT sum(p2.inventory_accno_id) - FROM parts p2, assembly a - WHERE (p2.id = a.parts_id) AND (a.id = p.id)) AS inventory - FROM parts p - WHERE NOT p.obsolete AND p.part_type = 'assembly' $where|; - - $form->{assembly_items} = selectall_hashref_query($form, $dbh, $query, @values); - - $main::lxdebug->leave_sub(); -} - sub assembly_item { $main::lxdebug->enter_sub();