[freeside-commits] freeside/httemplate/elements menu.html, 1.59, 1.60 select-taxclass.html, 1.7, 1.8 tr-select-taxclass.html, 1.5, 1.6
Ivan,,,
ivan at wavetail.420.am
Tue Jun 30 12:38:59 PDT 2009
Update of /home/cvs/cvsroot/freeside/httemplate/elements
In directory wavetail.420.am:/tmp/cvs-serv2795/httemplate/elements
Modified Files:
menu.html select-taxclass.html tr-select-taxclass.html
Log Message:
disabling a taxclass, RT#5472
Index: select-taxclass.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/elements/select-taxclass.html,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- select-taxclass.html 29 Aug 2008 00:23:56 -0000 1.7
+++ select-taxclass.html 30 Jun 2009 19:38:57 -0000 1.8
@@ -30,9 +30,9 @@
unless ( $opt{'taxclasses'} ) {
#my $sth = dbh->prepare('SELECT DISTINCT taxclass FROM cust_main_county')
- my $sth = dbh->prepare('SELECT taxclass FROM part_pkg_taxclass')
+ my $sth = dbh->prepare("SELECT taxclass FROM part_pkg_taxclass WHERE disabled IS NULL OR disabled = '' OR taxclass = ?")
or die dbh->errstr;
- $sth->execute or die $sth->errstr;
+ $sth->execute($selected_taxclass) or die $sth->errstr;
my %taxclasses = map { $_->[0] => 1 } @{$sth->fetchall_arrayref};
@{ $opt{'taxclasses'} } = grep $_, keys %taxclasses;
Index: menu.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/elements/menu.html,v
retrieving revision 1.59
retrieving revision 1.60
diff -u -d -r1.59 -r1.60
--- menu.html 30 Jun 2009 01:42:56 -0000 1.59
+++ menu.html 30 Jun 2009 19:38:57 -0000 1.60
@@ -319,6 +319,8 @@
$config_billing{'View/Edit call rates and regions'} = [ \%config_billing_rates, 'Manage rate plans, regions and prefixes for VoIP and call billing' ];
$config_billing{'View/Edit locales and tax rates (old tax class system)'} = [ $fsurl.'browse/cust_main_county.cgi', 'Change tax rates, or break down a country into states, or a state into counties and assign different tax rates to each' ];
$config_billing{'View/Edit tax rates (new tax products system)'} = [ $fsurl.'browse/tax_rate.cgi', 'Edit tax rates for the new tax products system' ];
+ $config_billing{'View/Edit tax classes'} = [ $fsurl.'browse/part_pkg_taxclass.html', 'Edit tax classes' ]
+ if $conf->exists('enable_taxclasses');
$config_billing{'View/Edit credit reason types'} = [ $fsurl.'browse/reason_type.html?class=R', 'Credit reason types define groups of reasons, for reporting and convenience purposes.' ];
$config_billing{'View/Edit credit reasons'} = [ $fsurl.'browse/reason.html?class=R', 'Credit reasons explain why a credit was issued.' ];
}
Index: tr-select-taxclass.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/elements/tr-select-taxclass.html,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- tr-select-taxclass.html 29 Aug 2008 00:23:55 -0000 1.5
+++ tr-select-taxclass.html 30 Jun 2009 19:38:57 -0000 1.6
@@ -23,9 +23,9 @@
unless ( $opt{'taxclasses'} ) {
#my $sth = dbh->prepare('SELECT DISTINCT taxclass FROM cust_main_county')
- my $sth = dbh->prepare('SELECT taxclass FROM part_pkg_taxclass')
+ my $sth = dbh->prepare("SELECT taxclass FROM part_pkg_taxclass WHERE disabled IS NULL OR disabled = '' OR taxclass = ?")
or die dbh->errstr;
- $sth->execute or die $sth->errstr;
+ $sth->execute($selected_taxclass) or die $sth->errstr;
my %taxclasses = map { $_->[0] => 1 } @{$sth->fetchall_arrayref};
@{ $opt{'taxclasses'} } = grep $_, keys %taxclasses;
More information about the freeside-commits
mailing list