X-Git-Url: http://wagnertech.de/git?a=blobdiff_plain;f=bin%2Fmozilla%2Fgl.pl;h=e7d9654216870ada786f342fd09eed85073c7d96;hb=b5157f97d47413e5f33cced1d0de527979ff3d61;hp=e3a7a471e53725836030e1d60d082ba8be6061fd;hpb=8cef58b276ce4005c0e2ada350fecd5d7a103e89;p=kivitendo-erp.git diff --git a/bin/mozilla/gl.pl b/bin/mozilla/gl.pl index e3a7a471e..e7d965421 100644 --- a/bin/mozilla/gl.pl +++ b/bin/mozilla/gl.pl @@ -32,9 +32,10 @@ #====================================================================== use SL::GL; +use SL::IS; use SL::PE; -require "$form->{path}/arap.pl"; +require "bin/mozilla/arap.pl"; require "bin/mozilla/common.pl"; 1; @@ -75,7 +76,7 @@ sub add { $form->{title} = "Add"; $form->{callback} = - "$form->{script}?action=add&path=$form->{path}&login=$form->{login}&password=$form->{password}" + "$form->{script}?action=add&login=$form->{login}&password=$form->{password}" unless $form->{callback}; # we use this only to set a default date @@ -104,12 +105,14 @@ sub add { } (@{ $form->{all_departments} }); } + $form->{show_details} = $myconfig{show_form_details} unless defined $form->{show_details}; + &display_form(1); $lxdebug->leave_sub(); } -sub edit { +sub prepare_transaction { $lxdebug->enter_sub(); GL->transaction(\%myconfig, \%$form); @@ -178,15 +181,26 @@ sub edit { ($form->datetonum($form->{transdate}, \%myconfig) <= $form->datetonum($form->{closedto}, \%myconfig)); + $lxdebug->leave_sub(); +} + +sub edit { + $lxdebug->enter_sub(); + + prepare_transaction(); + $form->{title} = "Edit"; - &form_header; - &display_rows; - &form_footer; - $lxdebug->leave_sub(); + $form->{show_details} = $myconfig{show_form_details} unless defined $form->{show_details}; + + form_header(); + display_rows(); + form_footer(); + $lxdebug->leave_sub(); } + sub search { $lxdebug->enter_sub(); @@ -364,7 +378,6 @@ $jsscript -{path}> {login}> {password}> @@ -387,7 +400,7 @@ sub generate_report { GL->all_transactions(\%myconfig, \%$form); $callback = - "$form->{script}?action=generate_report&path=$form->{path}&login=$form->{login}&password=$form->{password}"; + "$form->{script}?action=generate_report&login=$form->{login}&password=$form->{password}"; $href = $callback; @@ -768,7 +781,7 @@ sub generate_report { $column_data{id} = "