]> wagnertech.de Git - mfinanz.git/blobdiff - js/kivi.Part.js
kivi.Validator: Spezialbehandlung von 0 für heute wieder hergestellt
[mfinanz.git] / js / kivi.Part.js
index f949f257df68e9607273a036fe00233c7ff50ad3..dd6010b2cdf5f4d413e64688ef099ebe322d8930 100644 (file)
@@ -154,7 +154,7 @@ namespace('kivi.Part', function(ns) {
   };
 
   ns.add_assortment_item = function() {
-    if ($('#add_assortment_item_id').val() === '') return;
+    if ($('#assortment_picker').val() === '') return;
 
     $('#row_table_id thead a img').remove();
 
@@ -168,7 +168,7 @@ namespace('kivi.Part', function(ns) {
   };
 
   ns.add_assembly_item = function() {
-    if ($('#add_assembly_item_id').val() === '') return;
+    if ($('#assembly_picker').val() === '') return;
 
     var data = $('#assembly :input').serializeArray();
     data.push({ name: 'action', value: 'Part/add_assembly_item' },
@@ -241,7 +241,7 @@ namespace('kivi.Part', function(ns) {
   };
 
   ns.add_makemodel_row = function() {
-    if ($('#add_makemodelid').val() === '') return;
+    if ($('#add_makemodel').val() === '') return;
 
     var data = $('#makemodel_table :input').serializeArray();
     data.push({ name: 'action', value: 'Part/add_makemodel_row' });
@@ -424,6 +424,7 @@ namespace('kivi.Part', function(ns) {
           self.handle_changed_text();
         }
         if (event.which == KEY.ENTER) {
+          event.preventDefault();
           self.handle_changed_text({
             match_none: self.o.action.commit_none,
             match_one:  self.o.action.commit_one,