diff options
author | jeff <jeff> | 2008-02-13 23:46:52 +0000 |
---|---|---|
committer | jeff <jeff> | 2008-02-13 23:46:52 +0000 |
commit | ba5deb42e573673383c8e9dac0dfe3e4296c4b6d (patch) | |
tree | 675988f0a7acb0daf3cdfa7464811c9389ab2e62 | |
parent | 117b59b69ddc3dab173ec531762686d8c49ad08f (diff) |
package class selection for one-time charges RT#1322
-rw-r--r-- | FS/FS/cust_main.pm | 4 | ||||
-rw-r--r-- | httemplate/edit/process/quick-charge.cgi | 1 | ||||
-rw-r--r-- | httemplate/edit/quick-charge.html | 1 |
3 files changed, 5 insertions, 1 deletions
diff --git a/FS/FS/cust_main.pm b/FS/FS/cust_main.pm index 398ff04..73bdc14 100644 --- a/FS/FS/cust_main.pm +++ b/FS/FS/cust_main.pm @@ -4632,13 +4632,14 @@ the error, otherwise returns false. sub charge { my $self = shift; - my ( $amount, $pkg, $comment, $taxclass, $additional ); + my ( $amount, $pkg, $comment, $taxclass, $additional, $classnum ); if ( ref( $_[0] ) ) { $amount = $_[0]->{amount}; $pkg = exists($_[0]->{pkg}) ? $_[0]->{pkg} : 'One-time charge'; $comment = exists($_[0]->{comment}) ? $_[0]->{comment} : '$'. sprintf("%.2f",$amount); $taxclass = exists($_[0]->{taxclass}) ? $_[0]->{taxclass} : ''; + $classnum = exists($_[0]->{classnum}) ? $_[0]->{classnum} : ''; $additional = $_[0]->{additional}; }else{ $amount = shift; @@ -4665,6 +4666,7 @@ sub charge { 'plan' => 'flat', 'freq' => 0, 'disabled' => 'Y', + 'classnum' => $classnum ? $classnum : '', 'taxclass' => $taxclass, } ); diff --git a/httemplate/edit/process/quick-charge.cgi b/httemplate/edit/process/quick-charge.cgi index 3c7cac5..22f9685 100644 --- a/httemplate/edit/process/quick-charge.cgi +++ b/httemplate/edit/process/quick-charge.cgi @@ -42,6 +42,7 @@ unless ( $error ) { 'amount' => $amount, 'pkg' => scalar($cgi->param('pkg')), 'taxclass' => scalar($cgi->param('taxclass')), + 'classnum' => scalar($cgi->param('classnum')), 'additional' => \@description, } ); } diff --git a/httemplate/edit/quick-charge.html b/httemplate/edit/quick-charge.html index e8df371..95ec70c 100644 --- a/httemplate/edit/quick-charge.html +++ b/httemplate/edit/quick-charge.html @@ -82,6 +82,7 @@ function validate_quick_charge () { <TD> $<INPUT TYPE="text" NAME="amount" SIZE=6 VALUE="<% $amount %>" onChange="enable_quick_charge()" onKeyPress="enable_quick_charge_amount()"> </TD> +<% include('/elements/tr-select-pkg_class.html', '') %> <% include('/elements/tr-select-taxclass.html') %> </TR> <TD>Description:</TD> |