Selaa lähdekoodia

fixbug disabled错误

reaper 4 vuotta sitten
vanhempi
commit
375ddb14b9
1 muutettua tiedostoa jossa 9 lisäystä ja 7 poistoa
  1. 9 7
      src/components/knowledgeExtra/AddNewRule.vue

+ 9 - 7
src/components/knowledgeExtra/AddNewRule.vue

@@ -17,11 +17,11 @@
     width: 100%;
   }
   .tip_text {
-    margin-top: -8px;
+    // margin-top: -8px;
     font-size: 12px;
     color: red;
     line-height: 16px;
-    // transform: scale(.8, .8); 
+    // transform: scale(.8, .8);
   }
   .form_btn {
     width: 100%;
@@ -36,7 +36,7 @@
       :title="title"
       :param="$route.params"
       linkTo="ZskRuleManager"
-    ></crumbs>  
+    ></crumbs>
     <div class="AddRuleContent">
       <el-form size="mini" :model="form" :rules="rules" ref="ruleForm">
         <!-- <div class="table_form"> -->
@@ -293,10 +293,12 @@ export default {
         }
 
         // disable
-        if (arr[i - 1] && arr[i - 1].groupId == item.groupId) {
-          this.$set(item, "disabled", false);
-        } else {
-          this.$set(item, "disabled", true);
+        if (this.form.parHasSub && this.firstPlace) {
+          if (arr[i - 1] && arr[i - 1].groupId == item.groupId) {
+            this.$set(item, "disabled", false);
+          } else {
+            this.$set(item, "disabled", true);
+          }
         }
       });
     },