diff --git a/src/views/modules/proofing/requestForProofing.vue b/src/views/modules/proofing/requestForProofing.vue index 966b32c..4adb492 100644 --- a/src/views/modules/proofing/requestForProofing.vue +++ b/src/views/modules/proofing/requestForProofing.vue @@ -2143,7 +2143,6 @@ export default { projectId: undefined, projectName: undefined, customerId: undefined, - status: '已完成', }, // 项目集合 projectList: [], @@ -3787,7 +3786,6 @@ export default { searchProjectInfoList() { this.projectList = []; this.searchProjectData.customerId = this.modalData.customerNo - this.searchProjectData.status = '已完成' searchProjectInfoList(this.searchProjectData).then(({data}) => { if (data && data.code === 0) { this.projectList = data.rows @@ -3805,7 +3803,6 @@ export default { projectId: undefined, projectName: undefined, customerId: undefined, - status: '已完成', } }, rowStyle({row}) { @@ -4060,8 +4057,6 @@ export default { this.lookupProject().then(ok => { if (ok === false) { this.$message.warning('项目号不存在,或不属于该客户') - } else if (ok && ok.result === 'status') { - this.$message.warning('仅项目单据状态为已完成时允许新增打样,当前状态:' + ok.status) } }) }, @@ -4111,12 +4106,6 @@ export default { } const rows = (data && data.rows) || [] if (rows.length === 1) { - if (this.modalData.flag === '1' && rows[0].status !== '已完成') { - const status = rows[0].status - this.modalData.projectId = '' - this.modalData.projectName = '' - return { result: 'status', status } - } this.modalData.projectName = rows[0].projectName return true } @@ -4150,8 +4139,6 @@ export default { if (projectOk !== true) { if (projectOk === false) { this.$message.warning('项目号不存在,或不属于该客户') - } else if (projectOk && projectOk.result === 'status') { - this.$message.warning('仅项目单据状态为已完成时允许新增打样,当前状态:' + projectOk.status) } return false } diff --git a/src/views/modules/quotation/requestForQuote.vue b/src/views/modules/quotation/requestForQuote.vue index 1d010cd..52f535e 100644 --- a/src/views/modules/quotation/requestForQuote.vue +++ b/src/views/modules/quotation/requestForQuote.vue @@ -1000,7 +1000,7 @@ export default { projectId: undefined, projectName: undefined, customerId: undefined, - status: '已完成', + status: '', }, // 项目集合 projectList: [], @@ -3360,10 +3360,10 @@ export default { searchProjectInfoList() { this.projectList = []; this.searchProjectData.customerId = this.modalData.customerNo - this.searchProjectData.status = '已完成' + this.searchProjectData.status = '' searchProjectInfoList(this.searchProjectData).then(({data}) => { if (data && data.code === 0) { - this.projectList = data.rows + this.projectList = (data.rows || []).filter(row => row.status === '审批中' || row.status === '已完成') } else { this.projectList = [] } @@ -3378,7 +3378,7 @@ export default { projectId: undefined, projectName: undefined, customerId: undefined, - status: '已完成', + status: '', } }, projectClickRow(row) { @@ -3569,8 +3569,8 @@ export default { reject('未找到对应项目信息') return } - if (data.rows[0].status !== '已完成') { - reject('仅项目单据状态为已完成时允许' + actionText + ',当前状态:' + data.rows[0].status) + if (data.rows[0].status !== '审批中' && data.rows[0].status !== '已完成') { + reject('仅项目单据状态为审批中或已完成时允许' + actionText + ',当前状态:' + data.rows[0].status) return } resolve(data.rows[0]) @@ -3588,8 +3588,8 @@ export default { queryProjectByCustomer(params).then(({data})=>{ if (data && data.code === 0 ){ if (data.rows && data.rows.length === 1){ - if (this.modalData.flag === '1' && data.rows[0].status !== '已完成') { - this.$message.warning('仅项目单据状态为已完成时允许新增询价,当前状态:' + data.rows[0].status) + if (this.modalData.flag === '1' && data.rows[0].status !== '审批中' && data.rows[0].status !== '已完成') { + this.$message.warning('仅项目单据状态为审批中或已完成时允许新增询价,当前状态:' + data.rows[0].status) this.modalData.projectId = '' this.modalData.projectName = '' this.modalData.finalCustomerId = '' diff --git a/src/views/modules/quote/index.vue b/src/views/modules/quote/index.vue index d7d847c..a101bf5 100644 --- a/src/views/modules/quote/index.vue +++ b/src/views/modules/quote/index.vue @@ -1307,7 +1307,7 @@ export default { } if (val === 104) { strVal = this.saveQuote.projectNo - conSql = " and customer_id = '" + this.saveQuote.customerNo + "'" + conSql = " and customer_id = '" + this.saveQuote.customerNo + "' and status = '已完成'" } if (val === 2000) { strVal = this.saveQuote.purchase