f47aed9b by lihua

fix: 解决标签管理问题

1 parent 396a1871
......@@ -86,6 +86,9 @@ const tableInfo = ref({
formRows.value = labelRuleField.vagueMatchRule || [{ matchValue: '', position: '', name: '', disabled: false }];
let labelRuleContent = detail.labelRuleContent || {};
ruleContentFormItems.value[1].visible = labelRuleContent.ruleType == 1;
ruleContentFormItems.value[2].visible = labelRuleContent.ruleType == 2;
ruleContentFormItems.value.forEach(item => {
item.default = labelRuleContent[item.field];
if (item.field == 'regularTestData') {
......@@ -316,6 +319,8 @@ const newCreateLabelDialogInfo = ref({
newCreateLabelDialogInfo.value.submitBtnLoading = false;
proxy.$ElMessage.error(res.msg);
}
}).catch(() => {
newCreateLabelDialogInfo.value.submitBtnLoading = false;
});
} else {
newCreateLabelDialogInfo.value.submitBtnLoading = true;
......@@ -332,6 +337,8 @@ const newCreateLabelDialogInfo = ref({
newCreateLabelDialogInfo.value.submitBtnLoading = false;
proxy.$ElMessage.error(res.msg);
}
}).catch(() => {
newCreateLabelDialogInfo.value.submitBtnLoading = false;
});
}
}
......@@ -437,6 +444,8 @@ const handleCreate = () => {
matchEnValue.value.disabled = false;
formRows.value = [{ matchValue: '', position: '', name: '', disabled: false }];
ruleContentFormItems.value[1].visible = true;
ruleContentFormItems.value[2].visible = false;
ruleContentFormItems.value.forEach(item => {
item.default = item.field == 'ruleType' ? 1 : '';
if (item.field == 'regularTestData') {
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!