zhangweicheng 6 лет назад
Родитель
Сommit
bc79a0085a
1 измененных файлов с 2 добавлено и 2 удалено
  1. 2 2
      web/maintain/ration_repository/js/installation.js

+ 2 - 2
web/maintain/ration_repository/js/installation.js

@@ -473,7 +473,7 @@ let sectionObj = {
     },
     onSelectionChanged: function (sender, info) {
         let me = sectionObj;
-        if(info.oldSelections.length === 0 && info.newSelections.length > 0 || info.oldSelections[0].row !== info.newSelections[0].row){
+        if(info.oldSelections && info.oldSelections.length === 0 && info.newSelections.length > 0 || info.oldSelections[0].row !== info.newSelections[0].row){
             let row = info.newSelections[0].row;
             let section = me.cache[row];
             me.initSelection(section);
@@ -784,7 +784,7 @@ let feeRuleObj = {
     },
     onSelectionChanged: function (sender, info) {
         let me = feeRuleObj, se = sectionObj;
-        if(info.oldSelections.length === 0 && info.newSelections.length > 0 || info.oldSelections[0].row !== info.newSelections[0].row){
+        if(info.oldSelections && info.oldSelections.length === 0 && info.newSelections.length > 0 || info.oldSelections[0].row !== info.newSelections[0].row){
             if(me.isDef(me.updateObj) && !me.validRCJ(me.updateObj)){
                 $('#rcjAlert').modal('show');
                 $('#aleCanceBtn').bind('click', function () {