入库流程重复添加标准

This commit is contained in:
宋伟佳
2022-03-26 17:05:40 +08:00
parent 2dbb651a41
commit 8494e7dc3b
@@ -1450,6 +1450,7 @@ export default {
callback() callback()
} }
return { return {
textList: [],
gdType: '', //归档位置的赋值 gdType: '', //归档位置的赋值
standTypeModel: 'INLAND', standTypeModel: 'INLAND',
submitType: '', submitType: '',
@@ -2651,8 +2652,8 @@ export default {
}, },
// 代替政策编号确定 // 代替政策编号确定
replaceLawsNumModelBt() { replaceLawsNumModelBt() {
let subFlag = true
let textArr = [] let textArr = []
if (typeof this.value === 'string') { if (typeof this.value === 'string') {
if (this.value) { if (this.value) {
textArr = this.value.split(',') textArr = this.value.split(',')
@@ -2677,7 +2678,23 @@ export default {
} else { } else {
texts = item.standSort !== null ? item.standSort + ' ' + item.standNumber : item.standNumber texts = item.standSort !== null ? item.standSort + ' ' + item.standNumber : item.standNumber
} }
textArr.push(texts) // textArr.push(texts)
if(this.textList.length < 1){
textArr.push(texts)
}else{
this.textList.forEach(item =>{
if(item !== texts){
textArr.push(texts)
}else{
this.$message.warning('请勿重复添加数据')
subFlag = false
return
}
})
}
if(!subFlag){
textArr = []
}
textArr = [...new Set(textArr)] textArr = [...new Set(textArr)]
this.replaceLawsNumModel = false this.replaceLawsNumModel = false
}) })
@@ -2722,6 +2739,15 @@ export default {
this.getReplaceLawsNumRow() this.getReplaceLawsNumRow()
}, },
selectLaws(type) { selectLaws(type) {
if(type === 'dtbjh'){
this.textList = this.form.dtbjh.split(',')
}else if(type === 'bfbdtbzh'){
this.textList = this.form.bfbdtbzh.split(',')
}else if(type === 'cbbh'){
this.textList = this.form.cbbh.split(',')
}else if(type === 'yybj'){
this.textList = this.form.yybj.split(',')
}
// if (this.standNumFlag === 1) { // if (this.standNumFlag === 1) {
// this.$refs.selections.selectAll(false) // this.$refs.selections.selectAll(false)
// } // }