diff --git a/src/views/modules/part/partInformation.vue b/src/views/modules/part/partInformation.vue index 5e0cddc..6966693 100644 --- a/src/views/modules/part/partInformation.vue +++ b/src/views/modules/part/partInformation.vue @@ -3,12 +3,12 @@ - + + :value = "i.buNo"> @@ -1044,7 +1044,7 @@ } from '@/api/part/partInformation.js' import {getFileContentList, downLoadObjectFile} from '@/api/eam/eam_object_list.js' import {deleteObjectFile} from '@/api/eam/eam.js' - import {getSiteAndBuByUserName} from "@/api/eam/eam.js" + import {getSiteAndBuByUserName, getSiteAndBuByUserName2} from "@/api/qc/qc.js" import {getTableDefaultListLanguage, getTableUserListLanguage} from "@/api/table.js" import Chooselist from '@/views/modules/common/Chooselist_eam' import partUploadFile from "./part_upload_file" @@ -1105,6 +1105,7 @@ exportFooter: [], resultList: [], userBuList: [], + buList: [], // ======== 行高 ======== height: 200, secondHeight: 200, @@ -1118,7 +1119,7 @@ searchData: { site: '', userName: this.$store.state.user.name, - buDesc: '', + buNo: '', partNo: '', startDate: '', endDate: '', @@ -2145,6 +2146,8 @@ this.getButtonAuthData() // 获取用户的 site 和 bu this.getSiteAndBuByUserName() + // 获取用户的 site 和 bu + this.getSiteAndBuByUserName2() // 动态列 this.getTableUserColumn(this.$route.meta.menuId+'table1',1) if (!this.authSearch) { @@ -2154,6 +2157,18 @@ }, methods: { + // 获取用户的bu + getSiteAndBuByUserName2 () { + let tempData = { + username: this.$store.state.user.name, + } + getSiteAndBuByUserName2(tempData).then(({data}) => { + if (data.code === 0) { + this.buList = data.rows + } + }) + }, + // 获取用户的bu getSiteAndBuByUserName () { let tempData = { @@ -3578,8 +3593,8 @@ }) } } else { - this.modalData.codeNo = val.Code_no - this.$set(this.modalData, 'codeDesc', val.Code_desc) + this.modalData.codeNo = val.code_no + this.$set(this.modalData, 'codeDesc', val.code_desc) } } }, diff --git a/src/views/modules/part/routingManagement.vue b/src/views/modules/part/routingManagement.vue index 62507c6..c45c53c 100644 --- a/src/views/modules/part/routingManagement.vue +++ b/src/views/modules/part/routingManagement.vue @@ -3375,6 +3375,13 @@ export default { this.tagNo1 = type this.$nextTick(() => { let strVal = '' + let conSql = '' + if (this.modalData.bu === null || this.modalData.bu === '') { + this.$message.warning("请选择BU!") + return + } else { + conSql = " and site = '" + this.modalData.bu.split('_')[0] + "'" + " and bu_no = '" + this.modalData.bu.split('_')[1] + "'" + } if (val === 217) { if(type === 1) { strVal = this.componentData.laborClassNo @@ -3385,10 +3392,7 @@ export default { if (val === 216) { strVal = this.componentData.workCenterNo } - if (val === 122) { - strVal = this.routingToolData.toolId - } - this.$refs.baseList.init(val, strVal) + this.$refs.baseList.init(val, strVal, conSql) }) }, /** @@ -3409,10 +3413,6 @@ export default { this.componentData.workCenterNo = val.work_center_no this.componentData.workCenterDesc = val.work_center_desc } - if (this.tagNo === 122) { - this.routingToolData.toolId = val.tool_id - this.routingToolData.toolDescription = val.tool_description - } }, // 机器调机时间改变