X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/4dbb09950c9f5596646537c12d991c99086fe7c1..fbcd5580:/bin/mozilla/ic.pl
diff --git a/bin/mozilla/ic.pl b/bin/mozilla/ic.pl
index 3df2e51ed..2aae5cdd5 100644
--- a/bin/mozilla/ic.pl
+++ b/bin/mozilla/ic.pl
@@ -24,2591 +24,571 @@
# 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 module
#
#======================================================================
+use POSIX qw(strftime);
+use List::Util qw(first max);
+use List::MoreUtils qw(any);
+use SL::AM;
+use SL::CVar;
use SL::IC;
+use SL::Helper::Flash qw(flash);
+use SL::HTML::Util;
+use SL::ReportGenerator;
-require "$form->{path}/io.pl";
+#use SL::PE;
-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} = ($form->{item} eq 'service') ? $locale->text('hr') : $locale->text('ea');
-
- &link_part;
- &display_form;
+use strict;
+#use warnings;
- $lxdebug->leave_sub();
-}
-
-sub search {
- $lxdebug->enter_sub();
+# global imports
+our ($form, $locale, %myconfig, $lxdebug, $auth);
- $form->{title} = (ucfirst $form->{searchitems})."s";
- $form->{title} = $locale->text($form->{title});
+require "bin/mozilla/io.pl";
+require "bin/mozilla/common.pl";
+require "bin/mozilla/reportgenerator.pl";
- # 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;
+1;
+# Parserhappy(R):
+# type=submit $locale->text('Add Part')
+# type=submit $locale->text('Add Service')
+# type=submit $locale->text('Add Assembly')
+# type=submit $locale->text('Edit Part')
+# type=submit $locale->text('Edit Service')
+# type=submit $locale->text('Edit Assembly')
# $locale->text('Parts')
# $locale->text('Services')
+# $locale->text('Inventory quantity must be zero before you can set this part obsolete!')
+# $locale->text('Inventory quantity must be zero before you can set this assembly obsolete!')
+# $locale->text('Part Number missing!')
+# $locale->text('Service Number missing!')
+# $locale->text('Assembly Number missing!')
+# $locale->text('ea');
- # use JavaScript Calendar or not
- $form->{jsscript} = $jscalendar;
- $jsscript = "";
- if ($form->{jsscript})
- {
- # with JavaScript Calendar
- $button1 = qq|
-