X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fedit%2Fprocess%2Fquick-cust_pkg.cgi;h=67cdb87e868d2d267fa7af4c315694da2b65ed2e;hb=d46254f9b36873e457424eefdcf3610b71ef889d;hp=7dcd232bcf2966b98ea112945a32f73da9687d60;hpb=ad46607a14730f6ce4d70cd796b803591d90070e;p=freeside.git diff --git a/httemplate/edit/process/quick-cust_pkg.cgi b/httemplate/edit/process/quick-cust_pkg.cgi index 7dcd232bc..67cdb87e8 100644 --- a/httemplate/edit/process/quick-cust_pkg.cgi +++ b/httemplate/edit/process/quick-cust_pkg.cgi @@ -110,10 +110,6 @@ my $error = ''; my %hash = ( 'pkgpart' => $pkgpart, 'quantity' => $quantity, - 'start_date' => ( scalar($cgi->param('start_date')) - ? parse_datetime($cgi->param('start_date')) - : '' - ), 'salesnum' => $salesnum, 'refnum' => $refnum, 'contactnum' => $contactnum, @@ -133,6 +129,14 @@ my %hash = ( ); $hash{'custnum'} = $cust_main->custnum if $cust_main; +if ( $cgi->param('start') eq 'on_hold' ) { + $hash{'susp'} = 'now'; +} elsif ( $cgi->param('start') eq 'on_date' ) { + $hash{'start_date'} = scalar($cgi->param('start_date')) + ? parse_datetime($cgi->param('start_date')) + : ''; +} + if ( $quotationnum ) { $quotation_pkg = new FS::quotation_pkg \%hash; @@ -140,7 +144,7 @@ if ( $quotationnum ) { $quotation_pkg->prospectnum($prospect_main->prospectnum) if $prospect_main; #XXX handle new location - $error = $quotation_pkg->insert; + $error = $quotation_pkg->insert || $quotation_pkg->estimate; } else {