From: Thomas Heck Date: Mon, 2 Dec 2013 15:57:15 +0000 (+0100) Subject: "Kunden/Lieferanten Erfassen"-Button führt zum Controller X-Git-Tag: release-3.1.0beta1~22^2~106 X-Git-Url: http://wagnertech.de/git?a=commitdiff_plain;h=95795aa002c50ae10bf8306ff43305fe6bdd63bb;p=kivitendo-erp.git "Kunden/Lieferanten Erfassen"-Button führt zum Controller --- diff --git a/bin/mozilla/ct.pl b/bin/mozilla/ct.pl index 513a7ff21..f3a90ae3d 100644 --- a/bin/mozilla/ct.pl +++ b/bin/mozilla/ct.pl @@ -54,6 +54,7 @@ use SL::DB::Business; use SL::DB::Default; use SL::Helper::Flash; use SL::ReportGenerator; +use SL::MoreCommon qw(uri_encode); require "bin/mozilla/common.pl"; require "bin/mozilla/reportgenerator.pl"; @@ -66,18 +67,13 @@ use strict; sub add { $main::lxdebug->enter_sub(); - $main::auth->assert('customer_vendor_edit'); - - my $form = $main::form; - my %myconfig = %main::myconfig; - - $form->{title} = "Add"; - $form->{callback} = "$form->{script}?action=add&db=$form->{db}" unless $form->{callback}; + my $url = 'controller.pl?action=CustomerVendor/add&db='. ($::form->{db} eq 'vendor' ? 'vendor' : 'customer'); - CT->populate_drop_down_boxes(\%myconfig, \%$form); + if ( $::form->{callback} ) { + $url .= '&callback='. uri_encode($::form->{callback}); + } - &form_header; - &form_footer; + print $::form->redirect_header($url); $main::lxdebug->leave_sub(); }