diff options
author | jeff <jeff> | 2008-02-13 23:45:42 +0000 |
---|---|---|
committer | jeff <jeff> | 2008-02-13 23:45:42 +0000 |
commit | 72fc66f5f5882d670ccce2dfe17d03bb7faad390 (patch) | |
tree | 086ba3d2926b206bc5b9a6ca866890d0dc59b8af | |
parent | fc6c22c40f3b5362f46eb3ad4739580351bb4076 (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 d3f9b877a..3d7011d10 100644 --- a/FS/FS/cust_main.pm +++ b/FS/FS/cust_main.pm @@ -4131,13 +4131,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; @@ -4164,6 +4165,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 3c7cac51d..22f96852f 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 e8df37103..95ec70c54 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> |