diff --git a/changelog.md b/changelog.md index 90e51275..3ff43142 100644 --- a/changelog.md +++ b/changelog.md @@ -1,3 +1,14 @@ +## 2.6.2025040316 + +- fix: 问题修复 + - 出入库时物料选择更换组件xselect [shijing] + - 批次统计完善 [shijing] + - fix:性能检验析晶选型纠正 [shijing] + - dag优化 [shijing] + - 成品检验时批次选择实用xselect组件 [shijing] + - 登录页展示前后端版本号 [shijing] + - 扭转工段mlog中不填设备和人员;mlogb中选择设备、操作人、开始时间和结束时间 [shijing] + - 检验表中添加检验物料搜索时,展示full_name [shijing] ## 2.6.2025040209 - feat: 新增功能 diff --git a/src/api/model/mtm.js b/src/api/model/mtm.js index ad286a5a..339cc355 100644 --- a/src/api/model/mtm.js +++ b/src/api/model/mtm.js @@ -440,8 +440,8 @@ export default { }, copy:{ name: "复制", - req: async function (id,data) { - return await http.post(`${config.API_URL}/mtm/routepack/${id}/copy/`,data) + req: async function (data) { + return await http.post(`${config.API_URL}/mtm/routepack/copy/`,data) } }, togglestate:{ diff --git a/src/components/scDegra.vue b/src/components/scDegra.vue index 86fe9a63..f2a3bde3 100644 --- a/src/components/scDegra.vue +++ b/src/components/scDegra.vue @@ -58,7 +58,7 @@ export default { let that = this; that.$nextTick(() => { if(that.g!==null){ - that.updataGraph(); + that.updateGraph(); }else{ that.g = new dagreD3.graphlib.Graph().setGraph({ rankdir: that.rankdir, @@ -104,7 +104,6 @@ export default { let mySvgWdith =document.getElementsByClassName("output")[0].getBoundingClientRect().width+150 ; document.getElementById('mySvg').setAttribute("height", mySvgHeight); document.getElementById('mySvg').setAttribute("width", mySvgWdith); - svg.selectAll("g.node").on("click", function(event, d) { // 改变节点的颜色 const node = d3.select(this); @@ -125,15 +124,17 @@ export default { }); // 自定义方法:在节点点击时触发 function onNodeClick(nodeData) { - console.log("Node clicked:", nodeData); - this.$emit("nodeClick", nodeData); + let batch = ""; + that.nodes.forEach((item) => { + if (item.id === nodeData){ + batch = item.label; + } + }) + that.$emit("nodeClick", batch); // 你可以在这里处理更多的逻辑,例如显示一个提示框,更新图形状态等 } } }) - }, - updataGraph(){ - }, // 假设你有一个方法来更新节点和边的数据 updateGraph() { diff --git a/src/config/index.js b/src/config/index.js index de058dc9..d57120a0 100644 --- a/src/config/index.js +++ b/src/config/index.js @@ -6,7 +6,7 @@ const DEFAULT_CONFIG = { DASHBOARD_URL: "/dashboard", //版本号 - APP_VER: "2.6.2025040209", + APP_VER: "2.6.2025040813", //内核版本号 CORE_VER: "1.6.9", diff --git a/src/views/home/chatTest.vue b/src/views/home/chatTest.vue new file mode 100644 index 00000000..f5441472 --- /dev/null +++ b/src/views/home/chatTest.vue @@ -0,0 +1,202 @@ + + + + + + 新建聊天 + + + + + + + + + + + + + + + + + + 前端有哪些性能优化? + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/views/inm/mioitem_check.vue b/src/views/inm/mioitem_check.vue index fc465ae2..abcfd610 100644 --- a/src/views/inm/mioitem_check.vue +++ b/src/views/inm/mioitem_check.vue @@ -799,7 +799,6 @@ { if (!(item.testitem_name in this.form)) { - this.form[item.testitem_name] = '' + this.form[item.testitem_name] = null; } }); }, @@ -1090,17 +1088,17 @@ export default { that.qct_testitems = []; res.qct_testitems.forEach((item2) => { let obj2 = Object.assign({}, item2); - obj2.value = ''; + obj2.value = null; obj2.addto_wpr = item2.addto_wpr; if(item2.testitem_field_type=='input-number'||item2.testitem_field_type=='input-int'){ - obj2.value = 0; - that.addTemplate[item2.testitem_name] = 0; + obj2.value =null; + that.addTemplate[item2.testitem_name] = null; } if(item2.testitem_field_type=='select-text'||item2.testitem_field_type=='selects-text'){ let str = obj2.testitem_choices.replace(/'/g, '"'); let arr = JSON.parse(str); obj2.testitem_choices = arr; - that.addTemplate[item2.testitem_name] = ''; + that.addTemplate[item2.testitem_name] = null; } that.qct_testitems.push(obj2); }) @@ -1123,7 +1121,7 @@ export default { if(res0.qct_defects.length>0){ res0.qct_defects.forEach((item1) => { let obj = Object.assign({}, item1); - obj.value = ''; + obj.value = false; that.qct_defects.push(obj); }) }else{ @@ -1132,7 +1130,7 @@ export default { if(res0.qct_testitems.length>0){ res0.qct_testitems.forEach((item2) => { let obj2 = Object.assign({}, item2); - obj2.value = ''; + obj2.value = null; if(obj2.testitem_field_type=='select-text'||obj2.testitem_field_type=='selects-text'){ let str = obj2.testitem_choices.replace(/'/g, '"'); let arr = JSON.parse(str); @@ -1186,11 +1184,12 @@ export default { obj[item1.defect_name] = false; }) that.qct_testitems.forEach((item2) => { - if(item2.testitem_field_type=='input-number'||item.testitem_field_type=='input-int'){ - obj[item2.testitem_name] = 0; - }else{ - obj[item2.testitem_name] = ""; - } + obj[item2.testitem_name] = null; + // if(item2.testitem_field_type=='input-number'||item.testitem_field_type=='input-int'){ + // obj[item2.testitem_name] = null; + // }else{ + // obj[item2.testitem_name] = ""; + // } }) } that.mioitemwList.push(obj); @@ -1394,27 +1393,32 @@ export default { if(row.ftest!==null){ ftestdefects = row.ftest.ftestdefects; ftestdefects.forEach((item) => { + item.test_user = that.formbw.test_user; + item.test_date = that.formbw.test_date; item.has = row[item.defect_name]?row[item.defect_name]:false; }) ftestitems = row.ftest.ftestitems; ftestitems.forEach((item1) => { - item1.test_val_json = row[item1.testitem_name]?row[item1.testitem_name]:""; + item1.test_user = that.formbw.test_user; + item1.test_date = that.formbw.test_date; + item1.test_val_json = row[item1.testitem_name]?row[item1.testitem_name]:null; }) }else{ - that.qct_testitems.forEach((item) => { let obj0 = {}; obj0.testitem = item.testitem; - obj0.test_user = row.test_user; + obj0.test_user = that.formbw.test_user; + obj0.test_date = that.formbw.test_date; obj0.testitem_name = item.testitem_name; - obj0.test_val_json = row[item.testitem_name]?row[item.testitem_name]:""; + obj0.test_val_json = row[item.testitem_name]?row[item.testitem_name]:null; ftestitems.push(obj0); }) that.qct_defects.forEach((item1) => { let obj1 = {}; obj1.defect = item1.defect; - obj1.test_user = row.test_user; + obj1.test_user = that.formbw.test_user; obj1.defect_name = item1.defect_name; + obj1.test_date = that.formbw.test_date; obj1.has = row[item1.defect_name]?row[item1.defect_name]:false; ftestdefects.push(obj1); }) diff --git a/src/views/inm/mioitem_form.vue b/src/views/inm/mioitem_form.vue index 8b0ce3ba..14b818ea 100644 --- a/src/views/inm/mioitem_form.vue +++ b/src/views/inm/mioitem_form.vue @@ -15,7 +15,18 @@ - + + + @@ -83,7 +94,6 @@ style="width: 100%" @change="selectBatchChange" @clear="selectBatchClear" - :disabled="selectBatchDisable" > { - this.materialOptions = res; - }); + this.query = query; + this.apiObj=this.$API.mtm.material.list; + // this.$API.mtm.material.list.req(query).then((res) => { + // this.materialOptions = res; + // }); }, async initAssemb(item) { this.selectBatchDisable = true; @@ -423,15 +437,14 @@ export default { }) }, - selectMaterialChange(item) { + selectMaterialChange() { var that = this; var type = this.form.type; - var material = item.id; - that.form.material = material; - that.mTracking = item.tracking; + that.form.material = that.selectObj.id; + that.mTracking = that.selectObj.tracking; if (type == "do_in") { - if (item.is_assemb) { - this.initAssemb(item); + if (that.selectObj.is_assemb) { + this.initAssemb(that.selectObj); } else { this.selectBatchDisable = false; this.components = []; diff --git a/src/views/login/index.vue b/src/views/login/index.vue index efdd85bb..d4d78cb3 100644 --- a/src/views/login/index.vue +++ b/src/views/login/index.vue @@ -62,7 +62,8 @@ 刷脸登录 --> - VERSION @ {{ config_index.APP_VER }} + WEB版本:{{ config_index.APP_VER }} + SERVER版本:{{ baseConfig.sys_version }} @@ -406,10 +407,13 @@ export default { } .version { position: absolute; - bottom: 30px; - left: 30px; - font-size: 16px; - color: #fff; + bottom: 15px; + right: 30px; + font-size: 14px; + color: rgb(36, 93, 116); +} +.version_web{ + bottom: 40px; } .copyright { position: absolute; diff --git a/src/views/mtm/routepack.vue b/src/views/mtm/routepack.vue index 239440af..cf66411b 100644 --- a/src/views/mtm/routepack.vue +++ b/src/views/mtm/routepack.vue @@ -93,14 +93,14 @@ @click="table_show(scope.row, scope.$index)" >查看 - + + + + + + + + + + + + + + + + + + + + + + + + + + + 保存 + 取消 + + { + that.materialIn = res; + }); + }, + getMaterialOut() { + let that = this; + that.$API.mtm.material.list.req({ page: 0, type__in: "10,20",is_hidden: false}).then((res) => { + that.materialOut = res; + }); + }, getType(state) { if (state == 10) { return "warning"; @@ -252,13 +331,30 @@ export default { }, //复制 table_copy(row){ - this.$API.mtm.routepack.copy.req(row.id).then((res) => { - this.$message.success("复制成功"); - this.$refs.table.refresh(); - return res; - }).catch((err) => { - return err; - }); + let that = this; + that.form.routepack = row.id; + that.form.new_name = ''; + that.form.material_in = ''; + that.form.material_out =''; + that.dialogVisible = true; + }, + form_save(){ + let that = this; + that.$refs.dialogForm.validate(async (valid) => { + if (valid) { + that.isSaveing = true; + that.$API.mtm.routepack.copy.req(that.form).then((res) => { + that.$message.success("复制成功"); + that.$refs.table.refresh(); + that.isSaveing = false; + that.dialogVisible = false; + return res; + }).catch((err) => { + that.isSaveing = false; + return err; + }); + } + }) }, // handleWatch(row) { // let that = this; diff --git a/src/views/mtm/routepack_form.vue b/src/views/mtm/routepack_form.vue index 5d76ed91..bf566638 100644 --- a/src/views/mtm/routepack_form.vue +++ b/src/views/mtm/routepack_form.vue @@ -45,18 +45,18 @@ - {{ form.material_name }} + - - + + @@ -134,6 +134,11 @@ + + + {{ tracking_[scope.row.material_out_tracking] }} + + @@ -224,12 +229,18 @@ export default { apiworkerObj: null, materials: [], apiObj: null, + apiObjM:this.$API.mtm.material.list, query: { routepack: "", }, + selectObj:{}, rules: { name: [{ required: true, message: "请输入" }], }, + tracking_:{ + 10:"批次", + 20:"单个", + }, nodes:[], edges:[], routepack: "", @@ -242,7 +253,7 @@ export default { this.isSaveing = false; this.project_code = this.$TOOL.data.get("BASE_INFO").base.base_code; this.getInit(); - this.getMaterials(); + // this.getMaterials(); }, methods: { open(mode) { diff --git a/src/views/ops/setting.vue b/src/views/ops/setting.vue index 701a3991..96ee95db 100644 --- a/src/views/ops/setting.vue +++ b/src/views/ops/setting.vue @@ -12,6 +12,7 @@ > {{ form.base_name }} SERVER版本: {{ form.sys_version }} + WEB版本: {{ config.APP_VER }} @@ -54,7 +55,7 @@ + + diff --git a/src/views/wpm_bx/mlog_detail.vue b/src/views/wpm_bx/mlog_detail.vue index c24ff130..a3420f7b 100644 --- a/src/views/wpm_bx/mlog_detail.vue +++ b/src/views/wpm_bx/mlog_detail.vue @@ -727,6 +727,9 @@ export default { //表单提交方法 mlogSubmit() { let that = this; + if(that.mlogItem.work_end_time==''||that.mlogItem.work_end_time==null){ + that.mlogItem.handle_date = that.$TOOL.dateFormat2(new Date()); + } that.$API.wpm.mlog.submit.req(that.mlogItem.id).then((res) => { that.isSaveing = false; that.visible = false; diff --git a/src/views/wpm_bx/mlog_form.vue b/src/views/wpm_bx/mlog_form.vue index 7b1a35d7..326d0e44 100644 --- a/src/views/wpm_bx/mlog_form.vue +++ b/src/views/wpm_bx/mlog_form.vue @@ -96,7 +96,7 @@ - + - + - - + - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 提交 @@ -144,8 +215,10 @@ export default { ] }, wm_in:'', + route_code:"", mlogbIns:[], options: [], + optionsEq: [], mlogbInOptions:[], materialOptions: [], mgroup_code:'', @@ -168,6 +241,7 @@ export default { }; }, mounted() { + this.route_code = this.$route.path.split("/")[2]; this.form.mlog = this.mlog; this.params.mlog = this.mlog; let arr = this.$route.path.split("/"); @@ -176,6 +250,7 @@ export default { this.getMtask(); this.getMaterial(); this.getParentList(); + this.getEquipment(); }, methods: { open() { @@ -195,6 +270,17 @@ export default { that.mlogbIns = res; }) }, + getEquipment() { + let that = this; + this.$API.em.equipment.list.req({ page: 0, type: 10,mgroup:that.mgroup}).then((res) => { + res.forEach((item) => { + let obj = {}; + Object.assign(obj, item); + obj.label = item.name+'-'+item.number; + that.optionsEq.push(obj); + }); + }); + }, getParentList(){ let that = this; that.$API.wpm.mlogb.list.req(that.params).then((res) => { @@ -350,8 +436,6 @@ export default { that.form.batch = ''; that.form.parent = ''; that.form.count_use = 0; - // that.scanKyes!=='mat'&&that.mlogbInCount>1 - // that.bwItemForm.wpr!="" if(that.scanKyes!=='mat'&&that.mlogbInCount>1){ that.bwItemForm.mlogb = res.id; that.$API.wpm.mlogbw.create.req(that.bwItemForm).then((res) => { diff --git a/src/views/wpm_bx/mlogbw_check.vue b/src/views/wpm_bx/mlogbw_check.vue index 6b0927c3..58fd1fdb 100644 --- a/src/views/wpm_bx/mlogbw_check.vue +++ b/src/views/wpm_bx/mlogbw_check.vue @@ -42,7 +42,7 @@ {{ scope.row.number }} {{ scope.row.number }} + + + + + {{item.name}} + {{item.number}} + + + + + + + + + + + + + + + 取消 + + diff --git a/src/views/wpm_gx/f_mlogs_form.vue b/src/views/wpm_gx/f_mlogs_form.vue index db84b377..a12a11fa 100644 --- a/src/views/wpm_gx/f_mlogs_form.vue +++ b/src/views/wpm_gx/f_mlogs_form.vue @@ -354,6 +354,7 @@ export default { }, qct:'', codeText:'', + codeBatch:'', mgroupName:'', materialCount:1,//领料批次现有库存数 material_in:'', @@ -481,7 +482,7 @@ export default { that.materialOptions = res; if(that.codeText!==''){ res.forEach(item=>{ - if(item.batch == that.codeText){ + if(item.batch == that.codeBatch){ that.form.wm_in = item.id; that.form.batch = item.batch; that.materialCount = that.form.count_use = that.form.count_ok = item.count_cando; @@ -506,12 +507,21 @@ export default { }, //显示 open(mode = "add",codeText) { - this.mode = mode; - this.visible = true; - if(codeText){ - this.codeText = codeText; + let that = this; + that.mode = mode; + that.visible = true; + if(codeText!==''){ + that.codeText = codeText; + let id = codeText.split('#')[1]; + that.$API.cm.labelmat.item.req(id).then((res) => { + that.codeBatch = res.batch; + that.getMaterial(); + }).catch((err) => { + that.getMaterial(); + }) + }else{ + that.getMaterial(); } - this.getMaterial(); return this; }, //表单注入数据 diff --git a/src/views/wpm_gx/fmlog_detail.vue b/src/views/wpm_gx/fmlog_detail.vue index 7b0058bd..0847c493 100644 --- a/src/views/wpm_gx/fmlog_detail.vue +++ b/src/views/wpm_gx/fmlog_detail.vue @@ -173,8 +173,8 @@ { + this.codeTextChange(codeText); + }) + + } this.visible = true; }, @@ -290,8 +304,6 @@ export default { let that = this; that.$API.wpm.fmlog.item.req(that.fmlogId).then((res) => { that.fmlogItem = res; - that.mgroup = res.mgroup; - that.mtask = res.mtask; that.paramsWm.mgroup = res.mgroup; that.$API.wpm.mlog.list.req(that.params).then((res) => { that.tableData = res; @@ -301,9 +313,6 @@ export default { }) that.paramsWm.search = that.batchContains; that.apiObjWm = that.$API.wpm.wmaterial.list; - if(that.codeText!=""){ - this.codeTextChange(that.codeText); - } }else{} }); }); @@ -316,21 +325,19 @@ export default { table_add() { this.dialog.save = true; this.$nextTick(() => { - this.$refs.saveDialog.open('add'); + this.$refs.saveDialogs.open('add'); }); }, codeTextChange(codeText){ - let that = this; - that.codeText = codeText; - that.dialog.save = true; - that.$nextTick(() => { - that.$refs.saveDialog.open('add',codeText); + this.dialog.save = true; + this.$nextTick(() => { + this.$refs.saveDialogs.open('add',codeText); }); }, table_edit(row){ this.dialog.save = true; this.$nextTick(() => { - this.$refs.saveDialog.open('edit').setData(row); + this.$refs.saveDialogs.open('edit').setData(row); }); }, //表单提交方法 diff --git a/src/views/wpm_gx/fmlogs.vue b/src/views/wpm_gx/fmlogs.vue index 379bdc89..d504aac3 100644 --- a/src/views/wpm_gx/fmlogs.vue +++ b/src/views/wpm_gx/fmlogs.vue @@ -148,6 +148,8 @@ { @@ -271,30 +274,23 @@ export default { codeTextChange(codeText){ let that = this; that.codeText = codeText; - //根据扫描内容获取物料 - let obj = {}; - obj.page=0; - obj.tag = 'todo'; - obj.mgroup=that.mgroupId; - obj.batch=that.codeText; - that.$API.wpm.wmaterial.list.req(obj).then(res=>{ - //根据物料获取任务 + let id = codeText.split('#')[1]; + that.$API.cm.labelmat.item.req(id).then((res) => { let params = {} params.page = 0; params.state = 20; params.mgroup = that.mgroupId; - params.route__material_in = res[0].material; + params.route__material_in = res.material; that.$API.pm.mtask.list.req(params).then(res1=>{ if(res1.length==1){//只有一个任务,直接打开日志详情 that.mtaskId =res1[0].id; that.changeMtask(); - // that.table_detail(res2[0]); }else{//多个任务时,弹出任务选择框 that.mtaskoptions = res1; that.dialog.mtask = true; } }) - }) + }).catch((err) => {}) }, changeMtask(){ let that = this; diff --git a/src/views/wpm_gx/handover_form.vue b/src/views/wpm_gx/handover_form.vue index cc1d9657..957315c6 100644 --- a/src/views/wpm_gx/handover_form.vue +++ b/src/views/wpm_gx/handover_form.vue @@ -186,7 +186,6 @@
SERVER版本: {{ form.sys_version }}
WEB版本: {{ config.APP_VER }}