fix(企标、计划立项、计划管控): 起草人带入部门
This commit is contained in:
@@ -1123,7 +1123,12 @@ export default {
|
|||||||
}
|
}
|
||||||
this.modalshowflag2 = true;
|
this.modalshowflag2 = true;
|
||||||
},
|
},
|
||||||
|
unique (newArr) {
|
||||||
|
const res = new Map();
|
||||||
|
return newArr.filter((newArr) => !res.has(newArr) && res.set(newArr, 1));
|
||||||
|
},
|
||||||
checkedRole2 (data) {
|
checkedRole2 (data) {
|
||||||
|
/*
|
||||||
const unList = []
|
const unList = []
|
||||||
const uidList = []
|
const uidList = []
|
||||||
let idList = '', nameList = ''
|
let idList = '', nameList = ''
|
||||||
@@ -1170,11 +1175,24 @@ export default {
|
|||||||
unIdList.push(item)
|
unIdList.push(item)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
*/
|
||||||
|
let idList = '';
|
||||||
|
let nameList = '';
|
||||||
|
data.forEach(item => {
|
||||||
|
if (nameList.length > 0) {
|
||||||
|
nameList += ',';
|
||||||
|
idList += ',';
|
||||||
|
}
|
||||||
|
idList += item.id;
|
||||||
|
nameList += item.name;
|
||||||
|
});
|
||||||
|
const institutionIdList = this.unique(data.map(item => item.institutionId)).join(',')
|
||||||
|
const institutionNameList = this.unique(data.map(item => item.institutionCascade)).join(',')
|
||||||
if(this.roleType === '1') {
|
if(this.roleType === '1') {
|
||||||
this.$set(this.qbfsForm, 'drafter', idList)
|
this.$set(this.qbfsForm, 'drafter', idList)
|
||||||
this.$set(this.qbfsForm, 'drafterName', nameList)
|
this.$set(this.qbfsForm, 'drafterName', nameList)
|
||||||
this.$set(this.qbfsForm, 'unit', unIdList.join(','))
|
this.$set(this.qbfsForm, 'unit', institutionIdList)
|
||||||
this.$set(this.qbfsForm, 'unitName', unNameList.join(','))
|
this.$set(this.qbfsForm, 'unitName', institutionNameList)
|
||||||
}else if(this.roleType === '2') {
|
}else if(this.roleType === '2') {
|
||||||
this.$set(this.qbfsForm, 'resPerson', idList)
|
this.$set(this.qbfsForm, 'resPerson', idList)
|
||||||
this.$set(this.qbfsForm, 'resPersonName', nameList)
|
this.$set(this.qbfsForm, 'resPersonName', nameList)
|
||||||
|
|||||||
@@ -1170,7 +1170,12 @@ export default {
|
|||||||
}
|
}
|
||||||
this.modalshowflag2 = true;
|
this.modalshowflag2 = true;
|
||||||
},
|
},
|
||||||
|
unique (newArr) {
|
||||||
|
const res = new Map();
|
||||||
|
return newArr.filter((newArr) => !res.has(newArr) && res.set(newArr, 1));
|
||||||
|
},
|
||||||
checkedRole2 (data) {
|
checkedRole2 (data) {
|
||||||
|
/*
|
||||||
const unList = []
|
const unList = []
|
||||||
const uidList = []
|
const uidList = []
|
||||||
let idList = '', nameList = ''
|
let idList = '', nameList = ''
|
||||||
@@ -1217,11 +1222,24 @@ export default {
|
|||||||
unIdList.push(item)
|
unIdList.push(item)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
*/
|
||||||
|
let idList = '';
|
||||||
|
let nameList = '';
|
||||||
|
data.forEach(item => {
|
||||||
|
if (nameList.length > 0) {
|
||||||
|
nameList += ',';
|
||||||
|
idList += ',';
|
||||||
|
}
|
||||||
|
idList += item.id;
|
||||||
|
nameList += item.name;
|
||||||
|
});
|
||||||
|
const institutionIdList = this.unique(data.map(item => item.institutionId)).join(',')
|
||||||
|
const institutionNameList = this.unique(data.map(item => item.institutionCascade)).join(',')
|
||||||
if(this.type === '1') {
|
if(this.type === '1') {
|
||||||
this.$set(this.qbfsForm, 'drafter', idList)
|
this.$set(this.qbfsForm, 'drafter', idList)
|
||||||
this.$set(this.qbfsForm, 'drafterName', nameList)
|
this.$set(this.qbfsForm, 'drafterName', nameList)
|
||||||
this.$set(this.qbfsForm, 'unit', unIdList.join(','))
|
this.$set(this.qbfsForm, 'unit', institutionIdList)
|
||||||
this.$set(this.qbfsForm, 'unitName', unNameList.join(','))
|
this.$set(this.qbfsForm, 'unitName', institutionNameList)
|
||||||
}else if(this.type === '2') {
|
}else if(this.type === '2') {
|
||||||
this.$set(this.qbfsForm, 'resPerson', idList)
|
this.$set(this.qbfsForm, 'resPerson', idList)
|
||||||
this.$set(this.qbfsForm, 'resPersonName', nameList)
|
this.$set(this.qbfsForm, 'resPersonName', nameList)
|
||||||
|
|||||||
@@ -963,6 +963,8 @@ export default {
|
|||||||
if(this.roleType === '1') {
|
if(this.roleType === '1') {
|
||||||
this.$set(this.addQblxData, 'drafter', data[0].id)
|
this.$set(this.addQblxData, 'drafter', data[0].id)
|
||||||
this.$set(this.addQblxData, 'drafterName', data[0].name)
|
this.$set(this.addQblxData, 'drafterName', data[0].name)
|
||||||
|
this.$set(this.addQblxData, 'unit', data[0].institutionId)
|
||||||
|
this.$set(this.addQblxData, 'unitName', data[0].institutionCascade)
|
||||||
}else {
|
}else {
|
||||||
this.$set(this.addQblxData, 'wgLeader', data[0].id)
|
this.$set(this.addQblxData, 'wgLeader', data[0].id)
|
||||||
this.$set(this.addQblxData, 'wgLeaderName', data[0].name)
|
this.$set(this.addQblxData, 'wgLeaderName', data[0].name)
|
||||||
|
|||||||
@@ -381,7 +381,7 @@
|
|||||||
v-model="roleForm.countersignerName"
|
v-model="roleForm.countersignerName"
|
||||||
readonly
|
readonly
|
||||||
placeholder="选择会签人员"
|
placeholder="选择会签人员"
|
||||||
@click.native="choicePeoples('1')"
|
@click.native="choicePeoples('3')"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
@@ -1538,6 +1538,10 @@ export default {
|
|||||||
}
|
}
|
||||||
this.modalshowflag2 = true;
|
this.modalshowflag2 = true;
|
||||||
},
|
},
|
||||||
|
unique (newArr) {
|
||||||
|
const res = new Map();
|
||||||
|
return newArr.filter((newArr) => !res.has(newArr) && res.set(newArr, 1));
|
||||||
|
},
|
||||||
checkedRolePeoples (data) {
|
checkedRolePeoples (data) {
|
||||||
let idList = '';
|
let idList = '';
|
||||||
let nameList = '';
|
let nameList = '';
|
||||||
@@ -1550,7 +1554,14 @@ export default {
|
|||||||
nameList += item.name;
|
nameList += item.name;
|
||||||
});
|
});
|
||||||
console.log(nameList)
|
console.log(nameList)
|
||||||
if(this.roleType == '1') {
|
if (this.roleType === '1') {
|
||||||
|
this.qbfsForm.drafter = idList;
|
||||||
|
this.qbfsForm.drafterName = nameList;
|
||||||
|
const institutionIdList = this.unique(data.map(item => item.institutionId)).join(',')
|
||||||
|
const institutionNameList = this.unique(data.map(item => item.institutionCascade)).join(',')
|
||||||
|
this.$set(this.qbfsForm, 'unit', institutionIdList)
|
||||||
|
this.$set(this.qbfsForm, 'unitName', institutionNameList)
|
||||||
|
}else if(this.roleType == '3') {
|
||||||
this.roleForm.countersigner = idList;
|
this.roleForm.countersigner = idList;
|
||||||
this.roleForm.countersignerName = nameList;
|
this.roleForm.countersignerName = nameList;
|
||||||
}else{
|
}else{
|
||||||
|
|||||||
+8
@@ -4390,6 +4390,10 @@ export default {
|
|||||||
this.drawerTitle = title
|
this.drawerTitle = title
|
||||||
this.modalShowRoleFlag1 = true
|
this.modalShowRoleFlag1 = true
|
||||||
},
|
},
|
||||||
|
unique (newArr) {
|
||||||
|
const res = new Map();
|
||||||
|
return newArr.filter((newArr) => !res.has(newArr) && res.set(newArr, 1));
|
||||||
|
},
|
||||||
checkedRole2 (data) {
|
checkedRole2 (data) {
|
||||||
let idList = ''
|
let idList = ''
|
||||||
let nameList = ''
|
let nameList = ''
|
||||||
@@ -4411,7 +4415,11 @@ export default {
|
|||||||
this.sarBussionessSearch['QCRBUSS'] = nameList
|
this.sarBussionessSearch['QCRBUSS'] = nameList
|
||||||
}
|
}
|
||||||
if (this.drawerTitle === '选择起草人') {
|
if (this.drawerTitle === '选择起草人') {
|
||||||
|
const institutionIdList = this.unique(data.map(item => item.institutionId)).join(',')
|
||||||
|
const institutionNameList = this.unique(data.map(item => item.institutionCascade)).join(',')
|
||||||
this.$set(this.sarBussionessStandEO, 'QCRBUSS', nameList)
|
this.$set(this.sarBussionessStandEO, 'QCRBUSS', nameList)
|
||||||
|
this.$set(this.sarBussionessStandEO, 'QCDWId', institutionIdList)
|
||||||
|
this.$set(this.sarBussionessStandEO, 'QCDW', institutionNameList)
|
||||||
if (this.sarBussionessStandEO.QCRBUSS) {
|
if (this.sarBussionessStandEO.QCRBUSS) {
|
||||||
this.$refs.sarBussionessStandForm.validateField('QCRBUSS')
|
this.$refs.sarBussionessStandForm.validateField('QCRBUSS')
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user