X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;ds=sidebyside;f=bin%2Fmozilla%2Fic.pl;h=5f16184e8a5a1fd06c43476aaf592abaf60fad2d;hb=9fb8eec834ac3be77f5995053694b32ec140c877;hp=56c698e80e472cb4db65d76efff583b823de33a4;hpb=8ec0d29a33e23ce962b807e87cc8b577c8c98ec2;p=kivitendo-erp.git
diff --git a/bin/mozilla/ic.pl b/bin/mozilla/ic.pl
index 56c698e80..5f16184e8 100644
--- a/bin/mozilla/ic.pl
+++ b/bin/mozilla/ic.pl
@@ -30,1461 +30,371 @@
# Inventory Control module
#
#======================================================================
-#$locale->text('ea');
+
+use POSIX qw(strftime);
+use List::Util qw(max);
use SL::IC;
+use SL::ReportGenerator;
#use SL::PE;
-require "$form->{path}/io.pl";
-
-1;
-
-# end of main
-
-sub add {
- $lxdebug->enter_sub();
-
- $form->{title} = $locale->text('Add ' . ucfirst $form->{item});
-
- $form->{callback} =
- "$form->{script}?action=add&item=$form->{item}&path=$form->{path}&login=$form->{login}&password=$form->{password}"
- unless $form->{callback};
-
- $form->{"unit_changeable"} = 1;
-
- IC->get_pricegroups(\%myconfig, \%$form);
- &link_part;
- &display_form;
-
- $lxdebug->leave_sub();
-}
-
-sub search {
- $lxdebug->enter_sub();
-
- $form->{title} = (ucfirst $form->{searchitems}) . "s";
- $form->{title} = $locale->text($form->{title});
-
- # switch for backward sorting
- $form->{revers} = 0;
-
- # memory for which table was sort at last time
- $form->{lastsort} = "";
-
- # counter for added entries to top100
- $form->{ndxs_counter} = 0;
-
- # $locale->text('Parts')
- # $locale->text('Services')
-
- # use JavaScript Calendar or not
- $form->{jsscript} = $jscalendar;
- $jsscript = "";
- if ($form->{jsscript}) {
-
- # with JavaScript Calendar
- $button1 = qq|
-
|
- text('button') . qq|> |
- |;
- $button2 = qq|
- |
- text('button') . qq|> |
- |;
-
- #write Trigger
- $jsscript =
- Form->write_trigger(\%myconfig, "2", "transdatefrom", "BL", "trigger1",
- "transdateto", "BL", "trigger2");
- } else {
-
- # without JavaScript Calendar
- $button1 = qq|
- | |;
- $button2 = qq|
- | |;
- }
-
- unless ($form->{searchitems} eq 'service') {
-
- $onhand = qq|
- |
- . $locale->text('On Hand') . qq|
- |
- . $locale->text('Short') . qq|
-|;
-
- $makemodel = qq|
-
- | . $locale->text('Make') . qq| |
- |
- | . $locale->text('Model') . qq| |
- |
-
-|;
-
- $serialnumber = qq|
- | . $locale->text('Serial Number') . qq| |
- |
-|;
-
- $l_serialnumber = qq|
- |
- . $locale->text('Serial Number') . qq| |
-|;
-
- }
-
- if ($form->{searchitems} eq 'assembly') {
-
- $form->{title} = $locale->text('Assemblies');
-
- $toplevel = qq|
-
- |
-
- |
- . $locale->text('Top Level') . qq|
- |
- . $locale->text('Individual Items') . qq|
- |
-
-|;
-
- $bought = qq|
-
- |
-
-
-
-
-
- |
- |
- | . $locale->text('From') . qq| |
- $button1
- | . $locale->text('To (time)') . qq| |
- $button2
-
-
- |
-
-|;
-
- } else {
-
- $bought = qq|
-
- |
-
-
-
-
-
- |
- |
-
-
-
- | . $locale->text('From') . qq| |
- $button1
- | . $locale->text('To (time)') . qq| |
- $button2
-
-
- |
-
-
- |
-
-|;
- }
-
- $form->header;
-
- print qq|
-
-
-
-
-
-