维护评分规则id1

This commit is contained in:
fan 2024-03-01 16:45:06 +08:00
parent 1aca5f00ab
commit ff33bec539

View File

@ -32,21 +32,11 @@ export default {
};
},
methods: {
handleData(list, index) {
list.forEach((elem, i) => {
elem.id = index + '_' + i;
if (elem.children && elem.children.length) {
this.handleData(elem.children, elem.id);
}
});
},
doShow(id) {
this.dialogVisible = true;
this.loading = true;
getContextScoreDetail(id).then(resp => {
const data = resp.data.rule ? resp.data.rule.units : [];
this.handleData(data, '1');
this.tableData = data;
this.tableData = resp.data.rule ? resp.data.rule.units : [];
this.loading = false;
}).catch(() => { this.$message.error('初始化数据失败!'); this.loading = false; this.tableData = []; });
},