[freeside-commits] freeside/httemplate/edit/process
quick-charge.cgi, 1.3, 1.4 part_pkg.cgi, 1.14, 1.15
Ivan,,,
ivan at wavetail.420.am
Fri Oct 7 17:47:22 PDT 2005
Update of /home/cvs/cvsroot/freeside/httemplate/edit/process
In directory wavetail:/tmp/cvs-serv2080/httemplate/edit/process
Modified Files:
quick-charge.cgi part_pkg.cgi
Log Message:
fix tax class selection in package add/edit too
Index: quick-charge.cgi
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/edit/process/quick-charge.cgi,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- quick-charge.cgi 7 Oct 2005 02:25:41 -0000 1.3
+++ quick-charge.cgi 8 Oct 2005 00:47:20 -0000 1.4
@@ -13,7 +13,7 @@
if ( $cgi->param('taxclass') eq '(select)' ) {
- $error = "Must select a tax class";
+ $error = 'Must select a tax class';
} else {
my $cust_main = qsearchs('cust_main', { 'custnum' => $custnum } )
Index: part_pkg.cgi
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/edit/process/part_pkg.cgi,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -d -r1.14 -r1.15
--- part_pkg.cgi 10 Mar 2005 08:58:02 -0000 1.14
+++ part_pkg.cgi 8 Oct 2005 00:47:20 -0000 1.15
@@ -29,12 +29,18 @@
my $error;
my $custnum = '';
-if ( $pkgpart ) {
+if ( $cgi->param('taxclass') eq '(select)' ) {
+
+ $error = 'Must select a tax class';
+
+} elsif ( $pkgpart ) {
+
$error = $new->replace( $old,
pkg_svc => \%pkg_svc,
primary_svc => scalar($cgi->param('pkg_svc_primary')),
);
} else {
+
$error = $new->insert( pkg_svc => \%pkg_svc,
primary_svc => scalar($cgi->param('pkg_svc_primary')),
cust_pkg => $cgi->param('pkgnum'),
@@ -42,6 +48,7 @@
);
$pkgpart = $new->pkgpart;
}
+
if ( $error ) {
$cgi->param('error', $error );
print $cgi->redirect(popurl(2). "part_pkg.cgi?". $cgi->query_string );
More information about the freeside-commits
mailing list