[freeside-commits] freeside/httemplate/elements did_order_item.html, 1.1.2.4, 1.1.2.5

Erik Levinson levinse at wavetail.420.am
Fri Apr 22 16:17:42 PDT 2011


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

Modified Files:
      Tag: FREESIDE_2_1_BRANCH
	did_order_item.html 
Log Message:
bulk DID orders/inventory improvements, RT11291

Index: did_order_item.html
===================================================================
RCS file: /home/cvs/cvsroot/freeside/httemplate/elements/did_order_item.html,v
retrieving revision 1.1.2.4
retrieving revision 1.1.2.5
diff -u -w -d -r1.1.2.4 -r1.1.2.5
--- did_order_item.html	15 Apr 2011 03:09:52 -0000	1.1.2.4
+++ did_order_item.html	22 Apr 2011 23:17:40 -0000	1.1.2.5
@@ -14,6 +14,7 @@
                  SIZE  = "3"
                  VALUE = "<% scalar($cgi->param($name."_quantity"))
                              || $value |h %>"
+                 <% $onchange %>
           >
           <BR><FONT SIZE="-1">Quantity</FONT>
       </TD>
@@ -26,6 +27,7 @@
                  SIZE  = "3"
                  VALUE = "<% scalar($cgi->param($name."_npa"))
                              || $value |h %>"
+                 <% $onchange %>
           >
           <BR><FONT SIZE="-1">NPA</FONT>
       </TD>
@@ -109,6 +111,15 @@
 
 my $curr_value = $opt{'curr_value'} || $opt{'value'};
 
+my $onchange = '';
+if ( $opt{'onchange'} ) {
+  $onchange = $opt{'onchange'};
+  $onchange .= '(this)' unless $onchange =~ /\(\w*\);?$/;
+  $onchange =~ s/\(what\);/\(this\);/g; #ugh, terrible hack.  all onchange
+                                        #callbacks should act the same
+ $onchange = 'onChange="'. $onchange. '"';
+}
+
 my $item;
 if ( $curr_value ) {
   $item = qsearchs('did_order_item', { 'orderitemnum' => $curr_value } );



More information about the freeside-commits mailing list