[freeside-commits] freeside/httemplate/search cdr.html, 1.17, 1.18 report_cdr.html, 1.10, 1.11

Ivan,,, ivan at wavetail.420.am
Mon Jul 6 16:14:16 PDT 2009


Update of /home/cvs/cvsroot/freeside/httemplate/search
In directory wavetail.420.am:/tmp/cvs-serv6600

Modified Files:
	cdr.html report_cdr.html 
Log Message:
search cdr by acctid

Index: report_cdr.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/search/report_cdr.html,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- report_cdr.html	5 Jul 2009 21:35:52 -0000	1.10
+++ report_cdr.html	6 Jul 2009 23:14:14 -0000	1.11
@@ -84,6 +84,11 @@
   <% include( '/elements/tr-select-cdrbatch.html' ) %>
 
   <TR>
+    <TD ALIGN="right">Acct ID (one per-line):</TD>
+    <TD><TEXTAREA NAME="acctid"></TEXTAREA></TD>
+  </TR>
+
+  <TR>
     <TH BGCOLOR="#e8e8e8" COLSPAN=2>&nbsp;</TH>
   </TR>
 

Index: cdr.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/search/cdr.html,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -d -r1.17 -r1.18
--- cdr.html	5 Jul 2009 23:17:31 -0000	1.17
+++ cdr.html	6 Jul 2009 23:14:13 -0000	1.18
@@ -194,6 +194,23 @@
 }
 
 ###
+# acctid
+###
+
+if ( $cgi->param('acctid') =~ /\d/ ) {
+  my $acctid = $cgi->param('acctid');
+  $acctid =~ s/\r\n/\n/g; #browsers?
+  my @acctid = map  { /^\s*(\d+)\s*$/ or die "guru meditation #4"; $1; }
+               grep { /^\s*(\d+)\s*$/ }
+               split(/\n/, $acctid);
+  if ( @acctid ) {
+    my $search = 'acctid IN ( '. join(',', @acctid). ' )';
+    push @qsearch, $search;
+    push @search,  $search;
+  }
+}
+
+###
 # finish it up
 ###
 



More information about the freeside-commits mailing list