Browse Source

2024.9.18 一、物料成本信息维护(第二版)

二、加工中心功能改造
三、标准工序(第二版)
四、商品组 - 标准工序(第二版)
五、商品组 - Process Time Matrix(第一版)
java8
yuejiayang 1 year ago
parent
commit
78c2849dea
  1. 4
      src/views/modules/part/partProductGroupInformation.vue
  2. 41
      src/views/modules/part/standardRoutingOperation.vue

4
src/views/modules/part/partProductGroupInformation.vue

@ -378,10 +378,10 @@
</div> </div>
<div v-else> <div v-else>
<el-select style="width: 100%;" v-if="scope.row.valueTypeDb === 'text'" v-model="scope.row.textValue"> <el-select style="width: 100%;" v-if="scope.row.valueTypeDb === 'text'" v-model="scope.row.textValue">
<el-option :value="i.availableValue" :label="i.availableValue" v-for="(i,key) in scope.row.list" :key="key"></el-option>
<el-option :value="i.availableValue" :label="i.availableValue" v-for="(i,key) in scope.row.availableValueList" :key="key"></el-option>
</el-select> </el-select>
<el-select style="width: 100%;" v-else v-model="scope.row.numValue"> <el-select style="width: 100%;" v-else v-model="scope.row.numValue">
<el-option :value="i.availableValue" :label="i.availableValue" v-for="(i,key) in scope.row.list" :key="key"></el-option>
<el-option :value="i.availableValue" :label="i.availableValue" v-for="(i,key) in scope.row.availableValueList" :key="key"></el-option>
</el-select> </el-select>
</div> </div>
</div> </div>

41
src/views/modules/part/standardRoutingOperation.vue

@ -715,7 +715,10 @@ export default {
/** /**
* 分类信息新增/编辑 * 分类信息新增/编辑
*/ */
saveData () {
async saveData () {
await this.workCenterBlur(216)
await this.laborClassBlur(217)
await this.setupLaborClassBlur(217)
if (this.modalData.bu === '' || this.modalData.bu == null) { if (this.modalData.bu === '' || this.modalData.bu == null) {
this.$message.warning('请选择BU!') this.$message.warning('请选择BU!')
return return
@ -825,13 +828,14 @@ export default {
}, },
// //
workCenterBlur (tagNo) {
async workCenterBlur (tagNo) {
if (this.modalData.workCenterNo != null && this.modalData.workCenterNo !== '') { if (this.modalData.workCenterNo != null && this.modalData.workCenterNo !== '') {
let tempData = { let tempData = {
tagno: tagNo, tagno: tagNo,
conditionSql: " and work_center_no = '" + this.modalData.workCenterNo + "'" + " and site = '" + this.modalData.bu.split('_')[0] + "'" + " and bu_no = '" + this.modalData.bu.split('_')[1] + "'" conditionSql: " and work_center_no = '" + this.modalData.workCenterNo + "'" + " and site = '" + this.modalData.bu.split('_')[0] + "'" + " and bu_no = '" + this.modalData.bu.split('_')[1] + "'"
} }
verifyData(tempData).then(({data}) => {
// Promise
return verifyData(tempData).then(({ data }) => {
if (data && data.code === 0) { if (data && data.code === 0) {
if (data.baseListData.length > 0) { if (data.baseListData.length > 0) {
this.modalData.workCenterDesc = data.baseListData[0].work_center_desc this.modalData.workCenterDesc = data.baseListData[0].work_center_desc
@ -842,20 +846,26 @@ export default {
this.$message.warning(data.msg) this.$message.warning(data.msg)
this.modalData.workCenterDesc = '' this.modalData.workCenterDesc = ''
} }
})
}).catch(error => {
console.error(error);
this.$message.error('校验失败,请重试');
this.modalData.workCenterDesc = '';
});
} else { } else {
this.modalData.workCenterDesc = '' this.modalData.workCenterDesc = ''
return Promise.resolve(); // itemNo resolved Promise
} }
}, },
// //
setupLaborClassBlur (tagNo) {
async setupLaborClassBlur (tagNo) {
if (this.modalData.setupLaborClassNo != null && this.modalData.setupLaborClassNo !== '') { if (this.modalData.setupLaborClassNo != null && this.modalData.setupLaborClassNo !== '') {
let tempData = { let tempData = {
tagno: tagNo, tagno: tagNo,
conditionSql: " and class_no = '" + this.modalData.setupLaborClassNo + "'" + " and site = '" + this.modalData.bu.split('_')[0] + "'" + " and bu_no = '" + this.modalData.bu.split('_')[1] + "'" conditionSql: " and class_no = '" + this.modalData.setupLaborClassNo + "'" + " and site = '" + this.modalData.bu.split('_')[0] + "'" + " and bu_no = '" + this.modalData.bu.split('_')[1] + "'"
} }
verifyData(tempData).then(({data}) => {
// Promise
return verifyData(tempData).then(({data}) => {
if (data && data.code === 0) { if (data && data.code === 0) {
if (data.baseListData.length > 0) { if (data.baseListData.length > 0) {
this.modalData.setupLaborClassDesc = data.baseListData[0].class_desc this.modalData.setupLaborClassDesc = data.baseListData[0].class_desc
@ -864,23 +874,27 @@ export default {
} }
} else { } else {
this.$message.warning(data.msg) this.$message.warning(data.msg)
this.modalData.setupLaborClassNo = ''
this.modalData.setupLaborClassDesc = '' this.modalData.setupLaborClassDesc = ''
} }
})
}).catch(error => {
console.error(error);
this.$message.error('校验失败,请重试');
this.modalData.setupLaborClassDesc = '';
});
} else { } else {
this.modalData.setupLaborClassDesc = '' this.modalData.setupLaborClassDesc = ''
return Promise.resolve(); // itemNo resolved Promise
} }
}, },
// //
laborClassBlur (tagNo) {
async laborClassBlur (tagNo) {
if (this.modalData.laborClassNo != null && this.modalData.laborClassNo !== '') { if (this.modalData.laborClassNo != null && this.modalData.laborClassNo !== '') {
let tempData = { let tempData = {
tagno: tagNo, tagno: tagNo,
conditionSql: " and class_no = '" + this.modalData.laborClassNo + "'" + " and site = '" + this.modalData.bu.split('_')[0] + "'" + " and bu_no = '" + this.modalData.bu.split('_')[1] + "'" conditionSql: " and class_no = '" + this.modalData.laborClassNo + "'" + " and site = '" + this.modalData.bu.split('_')[0] + "'" + " and bu_no = '" + this.modalData.bu.split('_')[1] + "'"
} }
verifyData(tempData).then(({data}) => {
return verifyData(tempData).then(({data}) => {
if (data && data.code === 0) { if (data && data.code === 0) {
if (data.baseListData.length > 0) { if (data.baseListData.length > 0) {
this.modalData.laborClassDesc = data.baseListData[0].class_desc this.modalData.laborClassDesc = data.baseListData[0].class_desc
@ -891,9 +905,14 @@ export default {
this.$message.warning(data.msg) this.$message.warning(data.msg)
this.modalData.laborClassDesc = '' this.modalData.laborClassDesc = ''
} }
})
}).catch(error => {
console.error(error);
this.$message.error('校验失败,请重试');
this.modalData.laborClassDesc = '';
});
}else { }else {
this.modalData.laborClassDesc = '' this.modalData.laborClassDesc = ''
return Promise.resolve(); // itemNo resolved Promise
} }
}, },

Loading…
Cancel
Save