X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=httemplate%2Fedit%2Fprocess%2Fquick-cust_pkg.cgi;h=6a346e0be5a5ac4b832d3fcd18e235b68156c35b;hp=da5afe4403b4ec43e3ffa6b285c5fbf80c239663;hb=49cacb5122d8daacd41903d709681901501be0e5;hpb=e3dbd4594395231687cc1b92cbe32d2f82693392 diff --git a/httemplate/edit/process/quick-cust_pkg.cgi b/httemplate/edit/process/quick-cust_pkg.cgi index da5afe440..6a346e0be 100644 --- a/httemplate/edit/process/quick-cust_pkg.cgi +++ b/httemplate/edit/process/quick-cust_pkg.cgi @@ -189,7 +189,18 @@ if ( $quotationnum ) { ) : (); - #XXX handle new location + if ( $locationnum == -1 ) { + my $cust_location = FS::cust_location->new({ + 'custnum' => $custnum, + 'prospectnum' => $prospectnum, + map { $_ => scalar($cgi->param($_)) } + FS::cust_main->location_fields + }); + $opt{'cust_location'} = $cust_location; + } else { + $opt{'locationnum'} = $locationnum; + } + $error = $quotation_pkg->insert(%opt); } else {