diff --git a/src/views/modules/changeManagement/changeRecord.vue b/src/views/modules/changeManagement/changeRecord.vue index c56f6c7..29be6e4 100644 --- a/src/views/modules/changeManagement/changeRecord.vue +++ b/src/views/modules/changeManagement/changeRecord.vue @@ -141,8 +141,8 @@ ECN种类 - 审批人员 - 审批人员 + TP工程师 + TP工程师 @@ -1448,11 +1448,45 @@ } } }, + uploadDialog (newValue,oldValue) { if (newValue === false) { this.getChangeFileList() } }, + + 'costImpactData.productionProductFlag': function(newVal) { + if (newVal !== 'Y') { + this.costImpactData.productionProductNumber = '' + this.costImpactData.productionProductOpinions = '' + this.costImpactData.productionProductScrapAmount = 0 + this.costImpactData.productionProductExecutor = '' + this.costImpactData.productionProductExecutorName = '' + } + }, + 'costImpactData.inventoryProductFlag': function(newVal) { + if (newVal !== 'Y') { + this.costImpactData.inventoryProductNumber = '' + this.costImpactData.inventoryProductOpinions = '' + this.costImpactData.inventoryProductScrapAmount = 0 + this.costImpactData.inventoryProductExecutor = '' + this.costImpactData.inventoryProductExecutorName = '' + } + }, + 'costImpactData.newOrderFlag': function(newVal) { + if (newVal !== 'Y') { + this.costImpactData.newOrderNumber = '' + } + }, + 'costImpactData.affectedFlag': function(newVal) { + if (newVal !== 'Y') { + this.costImpactData.affectedNumber = '' + this.costImpactData.affectedOpinions = '' + this.costImpactData.affectedScrapAmount = 0 + this.costImpactData.affectedExecutor = '' + this.costImpactData.affectedExecutorName = '' + } + }, }, data () { @@ -4007,76 +4041,30 @@ // } if (this.costImpactData.productionProductFlag === 'Y') { // 在生产品 - if (this.costImpactData.productionProductNumber == null || this.costImpactData.productionProductNumber === '') { - this.$message.warning('请填写在生产品数量!') - return - } - if (this.costImpactData.productionProductNumber <= 0) { - this.$message.warning('在生产品数量不能小于等于0!') - return - } if (this.costImpactData.productionProductOpinions == null || this.costImpactData.productionProductOpinions === '') { this.$message.warning('请填写在生产品处理意见!') return } - if (this.costImpactData.productionProductScrapAmount === 0) { - this.$message.warning('请填写在生产品报废金额!') - return - } if (this.costImpactData.productionProductExecutor == null || this.costImpactData.productionProductExecutor === '') { this.$message.warning('请填写在生产品执行人!') return } } if (this.costImpactData.inventoryProductFlag === 'Y') { // 成品库存 - if (this.costImpactData.inventoryProductNumber == null || this.costImpactData.inventoryProductNumber === '') { - this.$message.warning('请填写成品库存数量!') - return - } - if (this.costImpactData.inventoryProductNumber <= 0) { - this.$message.warning('成品库存数量不能小于等于0!') - return - } if (this.costImpactData.inventoryProductOpinions == null || this.costImpactData.inventoryProductOpinions === '') { this.$message.warning('请填写成品库存处理意见!') return } - if (this.costImpactData.inventoryProductScrapAmount === 0) { - this.$message.warning('请填写成品库存报废金额!') - return - } if (this.costImpactData.inventoryProductExecutor == null || this.costImpactData.inventoryProductExecutor === '') { this.$message.warning('请填写成品库存执行人!') return } } - if (this.costImpactData.newOrderFlag === 'Y') { // 新订单 - if (this.costImpactData.newOrderNumber == null || this.costImpactData.newOrderNumber === '') { - this.$message.warning('请填写新订单数量!') - return - } - if (this.costImpactData.newOrderNumber <= 0) { - this.$message.warning('新订单数量不能小于等于0!') - return - } - } if (this.costImpactData.affectedFlag === 'Y') { // 影响的原材料及其库存量 - if (this.costImpactData.affectedNumber == null || this.costImpactData.affectedNumber === '') { - this.$message.warning('请填写影响的原材料及其库存量数量!') - return - } - if (this.costImpactData.affectedNumber <= 0) { - this.$message.warning('影响的原材料及其库存量数量不能小于等于0!') - return - } if (this.costImpactData.affectedOpinions == null || this.costImpactData.affectedOpinions === '') { this.$message.warning('请填写影响的原材料及其库存量处理意见!') return } - if (this.costImpactData.affectedScrapAmount === 0) { - this.$message.warning('请填写影响的原材料及其库存量报废金额!') - return - } if (this.costImpactData.affectedExecutor == null || this.costImpactData.affectedExecutor === '') { this.$message.warning('请填写影响的原材料及其库存量执行人!') return diff --git a/src/views/modules/changeManagement/changeRequest.vue b/src/views/modules/changeManagement/changeRequest.vue index fd31894..67e126c 100644 --- a/src/views/modules/changeManagement/changeRequest.vue +++ b/src/views/modules/changeManagement/changeRequest.vue @@ -149,7 +149,7 @@ ECN种类 - 审批人员 + TP工程师 @@ -939,6 +939,39 @@ } } }, + + 'costImpactData.productionProductFlag': function(newVal) { + if (newVal !== 'Y') { + this.costImpactData.productionProductNumber = '' + this.costImpactData.productionProductOpinions = '' + this.costImpactData.productionProductScrapAmount = 0 + this.costImpactData.productionProductExecutor = '' + this.costImpactData.productionProductExecutorName = '' + } + }, + 'costImpactData.inventoryProductFlag': function(newVal) { + if (newVal !== 'Y') { + this.costImpactData.inventoryProductNumber = '' + this.costImpactData.inventoryProductOpinions = '' + this.costImpactData.inventoryProductScrapAmount = 0 + this.costImpactData.inventoryProductExecutor = '' + this.costImpactData.inventoryProductExecutorName = '' + } + }, + 'costImpactData.newOrderFlag': function(newVal) { + if (newVal !== 'Y') { + this.costImpactData.newOrderNumber = '' + } + }, + 'costImpactData.affectedFlag': function(newVal) { + if (newVal !== 'Y') { + this.costImpactData.affectedNumber = '' + this.costImpactData.affectedOpinions = '' + this.costImpactData.affectedScrapAmount = 0 + this.costImpactData.affectedExecutor = '' + this.costImpactData.affectedExecutorName = '' + } + }, }, data() { return { @@ -2460,76 +2493,30 @@ } // 库存成本影响校验 if (this.costImpactData.productionProductFlag === 'Y') { // 在生产品 - if (this.costImpactData.productionProductNumber == null || this.costImpactData.productionProductNumber === '') { - this.$message.warning('请填写在生产品数量!') - return - } - if (this.costImpactData.productionProductNumber <= 0) { - this.$message.warning('在生产品数量不能小于等于0!') - return - } if (this.costImpactData.productionProductOpinions == null || this.costImpactData.productionProductOpinions === '') { this.$message.warning('请填写在生产品处理意见!') return } - if (this.costImpactData.productionProductScrapAmount === 0) { - this.$message.warning('请填写在生产品报废金额!') - return - } if (this.costImpactData.productionProductExecutor == null || this.costImpactData.productionProductExecutor === '') { this.$message.warning('请填写在生产品执行人!') return } } if (this.costImpactData.inventoryProductFlag === 'Y') { // 成品库存 - if (this.costImpactData.inventoryProductNumber == null || this.costImpactData.inventoryProductNumber === '') { - this.$message.warning('请填写成品库存数量!') - return - } - if (this.costImpactData.inventoryProductNumber <= 0) { - this.$message.warning('成品库存数量不能小于等于0!') - return - } if (this.costImpactData.inventoryProductOpinions == null || this.costImpactData.inventoryProductOpinions === '') { this.$message.warning('请填写成品库存处理意见!') return } - if (this.costImpactData.inventoryProductScrapAmount === 0) { - this.$message.warning('请填写成品库存报废金额!') - return - } if (this.costImpactData.inventoryProductExecutor == null || this.costImpactData.inventoryProductExecutor === '') { this.$message.warning('请填写成品库存执行人!') return } } - if (this.costImpactData.newOrderFlag === 'Y') { // 新订单 - if (this.costImpactData.newOrderNumber == null || this.costImpactData.newOrderNumber === '') { - this.$message.warning('请填写新订单数量!') - return - } - if (this.costImpactData.newOrderNumber <= 0) { - this.$message.warning('新订单数量不能小于等于0!') - return - } - } if (this.costImpactData.affectedFlag === 'Y') { // 影响的原材料及其库存量 - if (this.costImpactData.affectedNumber == null || this.costImpactData.affectedNumber === '') { - this.$message.warning('请填写影响的原材料及其库存量数量!') - return - } - if (this.costImpactData.affectedNumber <= 0) { - this.$message.warning('影响的原材料及其库存量数量不能小于等于0!') - return - } if (this.costImpactData.affectedOpinions == null || this.costImpactData.affectedOpinions === '') { this.$message.warning('请填写影响的原材料及其库存量处理意见!') return } - if (this.costImpactData.affectedScrapAmount === 0) { - this.$message.warning('请填写影响的原材料及其库存量报废金额!') - return - } if (this.costImpactData.affectedExecutor == null || this.costImpactData.affectedExecutor === '') { this.$message.warning('请填写影响的原材料及其库存量执行人!') return