|
@@ -21,7 +21,7 @@
|
|
|
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"> -->
|
|
@@ -184,7 +184,7 @@
|
|
|
type="primary"
|
|
|
size="medium "
|
|
|
@click="submitForm('ruleForm')"
|
|
|
- >立即创建</el-button
|
|
|
+ >确定</el-button
|
|
|
>
|
|
|
</div>
|
|
|
</el-form-item>
|
|
@@ -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);
|
|
|
+ }
|
|
|
}
|
|
|
});
|
|
|
},
|
|
@@ -321,6 +323,7 @@ export default {
|
|
|
params.klRuleInfoSaveSub.forEach((ite) => {
|
|
|
delete ite.groupId;
|
|
|
delete ite.groupChildId;
|
|
|
+ delete ite.rowIndex;
|
|
|
delete ite.baseTypes;
|
|
|
delete ite.baseTermTypeList;
|
|
|
delete ite.conceptList;
|
|
@@ -593,6 +596,24 @@ export default {
|
|
|
});
|
|
|
}
|
|
|
},
|
|
|
+ watch: {
|
|
|
+ "form.klRuleByIdSub": {
|
|
|
+ handler(val) {
|
|
|
+ console.log("000000000");
|
|
|
+ this.form.klRuleByIdSub.forEach((item, i, arr) => {
|
|
|
+ if (i == 0) {
|
|
|
+ item.rowIndex = 1;
|
|
|
+ } else if (item.groupId == arr[i - 1].groupId) {
|
|
|
+ item.rowIndex = arr[i - 1].rowIndex;
|
|
|
+ } else {
|
|
|
+ item.rowIndex = arr[i - 1].rowIndex + 1;
|
|
|
+ }
|
|
|
+ });
|
|
|
+ console.log(this.form.klRuleByIdSub);
|
|
|
+ },
|
|
|
+ deep: true
|
|
|
+ }
|
|
|
+ },
|
|
|
computed: {
|
|
|
disable: function () {
|
|
|
return Object.keys(this.firstPlace || {}).length > 0;
|