[freeside-commits] freeside/httemplate/search report_cdr.html, 1.12, 1.13 cdr.html, 1.18, 1.19
Ivan,,,
ivan at wavetail.420.am
Thu Nov 19 01:47:04 PST 2009
Update of /home/cvs/cvsroot/freeside/httemplate/search
In directory wavetail.420.am:/tmp/cvs-serv32369/httemplate/search
Modified Files:
report_cdr.html cdr.html
Log Message:
proper cdr_batch table, RT#6386
Index: report_cdr.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/search/report_cdr.html,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -d -r1.12 -r1.13
--- report_cdr.html 11 Oct 2009 01:45:24 -0000 1.12
+++ report_cdr.html 19 Nov 2009 09:47:02 -0000 1.13
@@ -132,7 +132,7 @@
startdate answerdate enddate duration billsec
disposition amaflags accountcode userfield
rated_price upstream_price carrierid
- svcnum freesidestatus freesiderewritestatus cdrbatch
+ svcnum freesidestatus freesiderewritestatus
);
my %show_default = map { $_=>1 } @show_default;
Index: cdr.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/search/cdr.html,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -d -r1.18 -r1.19
--- cdr.html 6 Jul 2009 23:14:13 -0000 1.18
+++ cdr.html 19 Nov 2009 09:47:02 -0000 1.19
@@ -179,18 +179,30 @@
}
###
-# cdrbatch
+# cdrbatchnum (or legacy cdrbatch)
###
-if ( $cgi->param('cdrbatch') ne '__ALL__' ) {
- if ( $cgi->param('cdrbatch') eq '' ) {
- my $search = "( cdrbatch IS NULL OR cdrbatch = '' )";
+if ( $cgi->param('cdrbatch') ) {
+
+ my $cdr_batch =
+ qsearchs('cdr_batch', { 'cdrbatch' => scalar($cgi->param('cdrbatch')) } );
+ if ( $cdr_batch ) {
+ push @search, 'cdrbatchnum = '. $cdr_batch->cdrbatchnum;
+ } else {
+ die "unknown cdrbatch ". $cgi->param('cdrbatch');
+ }
+
+} elsif ( $cgi->param('cdrbatchnum') ne '__ALL__' ) {
+
+ if ( $cgi->param('cdrbatchnum') eq '' ) {
+ my $search = "( cdrbatchnum IS NULL )";
push @qsearch, $search;
push @search, $search;
- } else {
- $hashref->{cdrbatch} = $cgi->param('cdrbatch');
- push @search, 'cdrbatch = '. dbh->quote($cgi->param('cdrbatch'));
+ } elsif ( $cgi->param('cdrbatchnum') =~ /^(\d+)$/ ) {
+ $hashref->{cdrbatchnum} = $1;
+ push @search, "cdrbatchnum = $1";
}
+
}
###
More information about the freeside-commits
mailing list