X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fedit%2Fprocess%2Fcust_pkg_discount.html;h=4a71f69753953993faaf7a6e6ca0910aaaa94273;hb=622d9a5930f47dad0c2897fed1b523138cb3e5c5;hp=4a31b922aeec31c353509c72cd6a4c1537d6bf3d;hpb=481011e14852aa62181bed0c7ae34b1e37ebff18;p=freeside.git diff --git a/httemplate/edit/process/cust_pkg_discount.html b/httemplate/edit/process/cust_pkg_discount.html index 4a31b922a..4a71f6975 100644 --- a/httemplate/edit/process/cust_pkg_discount.html +++ b/httemplate/edit/process/cust_pkg_discount.html @@ -29,22 +29,19 @@ my $cust_pkg = qsearchs({ }); die 'unknown pkgnum' unless $cust_pkg; -#XXX something not unlike this for custom discounts -#if ( $cgi->param('locationnum') == -1 ) { -# my $cust_location = new FS::cust_location { -# 'custnum' => $cust_pkg->custnum, -# map { $_ => scalar($cgi->param($_)) } -# qw( address1 address2 city county state zip country ) -# }; -# $change{'cust_location'} = $cust_location; -#} - my $cust_pkg_discount = new FS::cust_pkg_discount { 'pkgnum' => $cust_pkg->pkgnum, 'discountnum' => scalar($cgi->param('discountnum')), 'months_used' => 0, 'end_date' => '', #XXX - 'otaker' => $curuser->username, + #for the create a new discount case + '_type' => scalar($cgi->param('discountnum__type')), + 'amount' => scalar($cgi->param('discountnum_amount')), + 'percent' => scalar($cgi->param('discountnum_percent')), + 'months' => scalar($cgi->param('discountnum_months')), + 'setup' => scalar($cgi->param('discountnum_setup')), + #'linked' => scalar($cgi->param('discountnum_linked')), + #'disabled' => $self->discountnum_disabled, }; my $error = $cust_pkg_discount->insert;