|
@@ -288,7 +288,7 @@
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<el-dialog
|
|
<el-dialog
|
|
- title="请输入要添加到关联的标准术语(每行一个)"
|
|
|
|
|
|
+ :title="'请输入要添加到关联的标准术语(每行一个)'+'共'+len+'行'"
|
|
:visible.sync="dialogVisible"
|
|
:visible.sync="dialogVisible"
|
|
width="30%"
|
|
width="30%"
|
|
@close="cancel"
|
|
@close="cancel"
|
|
@@ -332,7 +332,6 @@ export default {
|
|
leftList: [],
|
|
leftList: [],
|
|
multipleSelection: [],
|
|
multipleSelection: [],
|
|
sign: 1,
|
|
sign: 1,
|
|
- len: 0,
|
|
|
|
searchtext: '',
|
|
searchtext: '',
|
|
searchtext2: '',
|
|
searchtext2: '',
|
|
dialogVisible: false,
|
|
dialogVisible: false,
|
|
@@ -356,7 +355,10 @@ export default {
|
|
collectionLibName: [
|
|
collectionLibName: [
|
|
{ required: true, message: '请选择术语集合名称', trigger: 'change' }
|
|
{ required: true, message: '请选择术语集合名称', trigger: 'change' }
|
|
]
|
|
]
|
|
- }
|
|
|
|
|
|
+ },
|
|
|
|
+ Math: 88,
|
|
|
|
+ English: 77,
|
|
|
|
+ chemistry: 99
|
|
};
|
|
};
|
|
},
|
|
},
|
|
created() {
|
|
created() {
|
|
@@ -507,7 +509,7 @@ export default {
|
|
conceptLibName: row.conceptName
|
|
conceptLibName: row.conceptName
|
|
};
|
|
};
|
|
this.excludedConceptIds.push(row.conceptId);
|
|
this.excludedConceptIds.push(row.conceptId);
|
|
- this.leftList.push(concepts);
|
|
|
|
|
|
+ this.form.concepts.push(concepts);
|
|
this.conceptList = [];
|
|
this.conceptList = [];
|
|
this.$nextTick(() => {
|
|
this.$nextTick(() => {
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
@@ -519,17 +521,22 @@ export default {
|
|
this.multipleSelection = val;
|
|
this.multipleSelection = val;
|
|
},
|
|
},
|
|
add() {
|
|
add() {
|
|
|
|
+ this.processing(this.multipleSelection);
|
|
|
|
+ },
|
|
|
|
+ //处理数据
|
|
|
|
+ processing(arr) {
|
|
if (this.whether) {
|
|
if (this.whether) {
|
|
return;
|
|
return;
|
|
}
|
|
}
|
|
- this.multipleSelection.forEach(it => {
|
|
|
|
|
|
+ arr.forEach(it => {
|
|
let concepts = {
|
|
let concepts = {
|
|
conceptId: it.conceptId,
|
|
conceptId: it.conceptId,
|
|
- conceptLibType: it.libType,
|
|
|
|
|
|
+ conceptLibType: it.libType ? it.libType : it.conceptLibType,
|
|
conceptLibName: it.conceptName
|
|
conceptLibName: it.conceptName
|
|
};
|
|
};
|
|
this.excludedConceptIds.push(it.conceptId);
|
|
this.excludedConceptIds.push(it.conceptId);
|
|
this.leftList.push(concepts);
|
|
this.leftList.push(concepts);
|
|
|
|
+ this.form.concepts.push(concepts);
|
|
});
|
|
});
|
|
this.conceptList = [];
|
|
this.conceptList = [];
|
|
this.$nextTick(() => {
|
|
this.$nextTick(() => {
|
|
@@ -554,14 +561,10 @@ export default {
|
|
if (item.conceptId == row.conceptId) {
|
|
if (item.conceptId == row.conceptId) {
|
|
this.form.concepts.splice(index, 1);
|
|
this.form.concepts.splice(index, 1);
|
|
this.excludedConceptIds.splice(index, 1);
|
|
this.excludedConceptIds.splice(index, 1);
|
|
- this.leftList.splice(index, 1);
|
|
|
|
}
|
|
}
|
|
});
|
|
});
|
|
this.getTreeSearchList();
|
|
this.getTreeSearchList();
|
|
},
|
|
},
|
|
- getchk(num) {
|
|
|
|
- return num % 2 == 0 ? '偶数' : '奇数'; //判断是否能整除2
|
|
|
|
- },
|
|
|
|
saveSet() {
|
|
saveSet() {
|
|
let params = {
|
|
let params = {
|
|
...this.form,
|
|
...this.form,
|
|
@@ -598,14 +601,17 @@ export default {
|
|
const data = res.data.data;
|
|
const data = res.data.data;
|
|
let text = '';
|
|
let text = '';
|
|
if (data.unMatchList.length > 0) {
|
|
if (data.unMatchList.length > 0) {
|
|
|
|
+ console.log(65);
|
|
data.unMatchList.forEach(it => {
|
|
data.unMatchList.forEach(it => {
|
|
text += it.conceptLibName + '\n';
|
|
text += it.conceptLibName + '\n';
|
|
});
|
|
});
|
|
|
|
+ } else if (data.matchList.length > 0) {
|
|
|
|
+ console.log(123);
|
|
|
|
+ this.processing(data.matchList);
|
|
|
|
+ this.dialogVisible = false;
|
|
}
|
|
}
|
|
this.$refs.msg.innerHTML = text;
|
|
this.$refs.msg.innerHTML = text;
|
|
this.innerText = text;
|
|
this.innerText = text;
|
|
- } else {
|
|
|
|
- this.dialogVisible = true;
|
|
|
|
}
|
|
}
|
|
})
|
|
})
|
|
.catch(error => {
|
|
.catch(error => {
|
|
@@ -620,16 +626,6 @@ export default {
|
|
this.getTreeSearchList();
|
|
this.getTreeSearchList();
|
|
}
|
|
}
|
|
},
|
|
},
|
|
- computed: {
|
|
|
|
- conceptCollectionVO() {
|
|
|
|
- let conceptCollectionVO = [];
|
|
|
|
- this.innerText.forEach(it => {
|
|
|
|
- console.log(123);
|
|
|
|
- conceptCollectionVO.push(it);
|
|
|
|
- });
|
|
|
|
- return conceptCollectionVO;
|
|
|
|
- }
|
|
|
|
- },
|
|
|
|
watch: {
|
|
watch: {
|
|
form: {
|
|
form: {
|
|
handler(newName, oldName) {
|
|
handler(newName, oldName) {
|
|
@@ -665,6 +661,16 @@ export default {
|
|
return (
|
|
return (
|
|
this.form.collectionLibType != '' && this.form.collectionLibName != ''
|
|
this.form.collectionLibType != '' && this.form.collectionLibName != ''
|
|
);
|
|
);
|
|
|
|
+ },
|
|
|
|
+ len() {
|
|
|
|
+ let arr = this.innerText.split('\n');
|
|
|
|
+ let len = 0;
|
|
|
|
+ arr.forEach(it => {
|
|
|
|
+ if (it != '') {
|
|
|
|
+ len++;
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ return len;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
};
|
|
};
|