]> wagnertech.de Git - mfinanz.git/blobdiff - templates/webpages/order/tabs/basic_data.html
Auftrags-Controller: linetotal nach Ändern von Menge/Preis/Rabatt neu berechnen.
[mfinanz.git] / templates / webpages / order / tabs / basic_data.html
index 480a0c5ab5c14ec7d6b6503be848845943bb5f65..2c9598d52c99a61ad6ec3a13360bd99619e4200c 100644 (file)
@@ -216,6 +216,12 @@ function recalc_amounts_and_taxes() {
   $.post("controller.pl", data, kivi.eval_json_result);
 }
 
+function redisplay_linetotals(data) {
+  $('.row_entry [name="linetotal"]').each(function(idx, elt) {
+    $(elt).html(data[idx]);    
+  });
+}
+
 function row_table_scroll_down() {
   $('#row_table_scroll_id').scrollTop($('#row_table_scroll_id')[0].scrollHeight);
 }
@@ -227,8 +233,6 @@ function row_set_keyboard_events_by_id(item_id) {
 }
 
 function row_set_keyboard_events(rows) {
-  console.log(rows);
-
   $(rows).keydown(function(event) {
     if(event.keyCode == 40 && event.shiftKey == true) {
       // shift arrow down
@@ -266,6 +270,7 @@ $(function(){
     }
   });
   row_set_keyboard_events($('.row_entry'));
+  $('.recalc').change(recalc_amounts_and_taxes);
 });
 
 </script>