diff --git a/.env.development b/.env.development index 1eca0332..8ad6dbf4 100644 --- a/.env.development +++ b/.env.development @@ -16,17 +16,17 @@ VUE_APP_PJ = '' # VUE_APP_API_BASEURL = http://127.0.0.1:8887/api #测试环境 - VUE_APP_API_BASEURL = http://10.50.211.228:2250/api +# VUE_APP_API_BASEURL = http://10.50.211.228:2250/api #VUE_APP_API_BASEURL = http://127.0.0.1:2226/api - VUE_APP_BASEURL = http://10.50.211.228:2250/ +# VUE_APP_BASEURL = http://10.50.211.228:2250/ # VUE_APP_BASEURL = http://127.0.0.1:8887 #VUE_APP_BASEURL = http://127.0.0.1:2226 # #光子 -# VUE_APP_API_BASEURL = http://49.232.14.174:2226/api -# VUE_APP_BASEURL = http://49.232.14.174:2226 +VUE_APP_API_BASEURL = http://49.232.14.174:2226/api +VUE_APP_BASEURL = http://49.232.14.174:2226 # # 本地端口 VUE_APP_PORT = 2800 diff --git a/package.json b/package.json index 204bc5ef..ba21488e 100644 --- a/package.json +++ b/package.json @@ -29,7 +29,7 @@ "dagre-d3": "^0.6.4", "dhtmlx-gantt": "^8.0.6", "echarts": "^5.5.1", - "element-plus": "^2.7.4", + "element-plus": "^2.8.4", "file-saver": "^2.0.5", "html2canvas": "^1.4.1", "json-editor-vue3": "^1.0.6", @@ -42,7 +42,6 @@ "three": "^0.155.0", "tinymce": "6.3.2", "vue": "3.2.47", - "vue-echarts": "^7.0.3", "vue-i18n": "9.2.2", "vue-router": "4.1.6", "vuedraggable": "4.0.3", diff --git a/src/components/ehsSelect/xselect.vue b/src/components/ehsSelect/xselect.vue deleted file mode 100644 index ada217b6..00000000 --- a/src/components/ehsSelect/xselect.vue +++ /dev/null @@ -1,105 +0,0 @@ - - - diff --git a/src/components/scTable/index.vue b/src/components/scTable/index.vue index 2c2249ad..61bd7604 100644 --- a/src/components/scTable/index.vue +++ b/src/components/scTable/index.vue @@ -26,7 +26,7 @@ - + diff --git a/src/views/qm/process2.vue b/src/views/qm/process2.vue index 41551372..407e80f9 100644 --- a/src/views/qm/process2.vue +++ b/src/views/qm/process2.vue @@ -102,6 +102,16 @@ + + + @@ -111,13 +121,17 @@ @choseChange="choseChange" > + + + diff --git a/src/views/setting/print/A4.vue b/src/views/setting/print/A4.vue index 8e9272c0..9094c2dc 100644 --- a/src/views/setting/print/A4.vue +++ b/src/views/setting/print/A4.vue @@ -2,27 +2,29 @@ - 导出 - 打印 -
+
+ + +
  • 入库信息单
    -
  • 入库信息单编号
  • -
  • 入库日期
  • -
  • 执行部门-工段
  • -
  • 交送人
  • -
  • 仓库接收人
  • -
  • 仓库
  • -
  • 采购订单
  • -
  • 供应商名称
  • +
  • 入库信息单编号
  • +
  • 入库日期
  • +
  • 执行部门-工段
  • +
  • 交送人
  • +
  • 仓库接收人
  • +
  • 仓库
  • +
  • 采购订单
  • +
  • 供应商名称
  • {{baseData.number}}
  • -
  • {{baseData.submit_time.slice(0,16)}}
  • +
  • {{baseData.inout_date}}
  • +
  • {{baseData.belong_dept_name}}
  • {{baseData.do_user_name}}
  • {{baseData.mio_user_name}}
  • @@ -35,17 +37,17 @@
  • 物料清单
    -
  • 物料名称
  • -
  • 型号
  • -
  • 所在工序
  • -
  • 批次号
  • -
  • 数量
  • +
  • 物料名称
  • + +
  • 所在工序
  • +
  • 批次号
  • +
  • 数量
    -
  • {{ item.material_name }}
  • -
  • {{ item.material_.model }}
  • +
  • {{ item.material_name }}
  • +
  • {{ item.material_.process_name }}
  • -
  • {{ item.batch }}
  • +
  • {{ item.batch }}
  • {{ item.count }}
@@ -119,8 +121,8 @@
  • {{ item.count }}
  • - -
    + +
    • XXX检验结果
    @@ -160,6 +162,7 @@
  • +
    • 厚度
    • 气泡
    • @@ -184,6 +187,99 @@
    • {{baseData.count_n_cpyd}}
    • {{baseData.count_n_cptxd}}
    +
    + +
    +
      +
    • 尺寸检验
    • +
    • 外观检验
    • +
    +
      +
    • 批次号
    • +
    • 总数
    • +
    • 检验数
    • +
    • 检验人
    • +
    • 检验日期
    • +
    • 班次
    • +
    +
      +
    • {{ baseData.material_mame }}
    • +
    • {{ baseData.count_real }}
    • +
    • {{ baseData.count_use }}
    • +
    • {{ baseData.handle_user_name }}
    • +
    • {{ baseData.count_ok }}
    • +
    • {{ baseData.test_time }}
    • +
    +
      +
    • 合格数
    • +
    • 不合格数
    • +
    • +
    • +
    • +
    • +
    +
      +
    • {{ baseData.count_ok }}
    • +
    • {{baseData.count_notok}}
    • +
    • +
    • +
    • +
    • +
    + +
      +
    • 黑圈内径
    • +
    • 黑圈内径圆度
    • +
    • 黑圈外径
    • +
    • 黑圈外径圆度
    • +
    • 产品外径
    • +
    • 产品圆度
    • +
    • 产品同心度
    • +
    • 厚度
    • +
    • 准合格
    • +
    • 圆准
    • +
    + +
      +
    • +
    • 气泡
    • +
    • 水纹
    • +
    • 崩边
    • +
    • 棕边
    • +
    • 棕圈
    • +
    • 划伤
    • +
    • 麻点
    • +
    • 黑圈变形
    • +
    • 倒角
    • +
    • 破损
    • +
    • 蓝圈
    • +
    +
      +
    • {{baseData.count_n_hd}}
    • +
    • {{baseData.count_n_qp}}
    • +
    • {{baseData.count_n_swen}}
    • +
    • {{baseData.count_n_bb}}
    • +
    • {{baseData.count_n_hs}}
    • +
    • {{baseData.count_n_md}}
    • +
    • {{baseData.count_n_xh}}
    • +
    • {{baseData.count_n_cpwj}}
    • +
    • {{baseData.count_n_cpyd}}
    • +
    • {{baseData.count_n_cptxd}}
    • +
    +
      +
    • {{baseData.count_n_hd}}
    • +
    • {{baseData.count_n_qp}}
    • +
    • {{baseData.count_n_swen}}
    • +
    • {{baseData.count_n_bb}}
    • +
    • {{baseData.count_n_hs}}
    • +
    • {{baseData.count_n_md}}
    • +
    • {{baseData.count_n_xh}}
    • +
    • {{baseData.count_n_cpwj}}
    • +
    • {{baseData.count_n_cpyd}}
    • +
    • {{baseData.count_n_cptxd}}
    • +
    • {{baseData.count_n_cptxd}}
    • +
    • {{baseData.count_n_cptxd}}
    • +
    @@ -192,101 +288,155 @@
    • 任务编号
    • -
    • 工艺路线
    • +
    • 所在工段
    • 产品名称
    • 任务总数量
      -
    • 11111111111
    • -
    • CNC
    • -
    • CNC玻璃
    • -
    • 100000
    • +
    • {{ baseData.number }}
    • +
    • {{ baseData.mgroup_name }}
    • +
    • {{ baseData.material_out_name }}
    • +
    • {{ baseData.count }}
    • 任务分解表
      -
    • 子任务编号
    • 人员
    • 数量
    -
      -
    • 11111111101
    • -
    • 张三
    • -
    • 5000
    • +
        +
      • {{ item.handle_user_name }}
      • +
      • {{ item.count }}
    -
    +
    • 日志记录
    • 任务编号
    • 工艺路线
    • -
    • 产品名称
    • -
    • 任务总数
    • +
    • 备注
    • +
      -
    • 11111111111
    • -
    • CNC
    • -
    • CNC玻璃
    • -
    • 100000
    • +
    • {{baseData.mtask_number}}
    • +
    • {{baseData.routepack_name}}
    • +
    • {{baseData.note}}
    • +
    • 物料清单
    -
    -
    1
    +
    +
    {{ index+1 }}
    • 设备编号
    • 操作人
    • 班次
    • 开始时间
    • -
    • 温度
    • -
    • 保温时间
    • -
    • 冷却时间
    • -
    • 预估结束时间
    • -
    • 备注层数
      -
    • TH11101
    • -
    • 张三
    • -
    • 白班
    • -
    • 19:00
    • -
    • 温度
    • -
    • 600
    • -
    • 120
    • -
    • 05:00
    • -
    • 1到10层
    • +
    • {{ item.equipment_name }}
    • +
    • {{ item.handle_user_name }}
    • +
    • {{ item.shift_name }}
    • +
    • {{ item.work_start_time }}
      -
    • 输入物料批次号
    • +
    • 输入物料批次号
    • 领料数量
    • 加工数量
    • 加工前不良数量
    • -
    • 输出物料批次号
    • +
    • 输出物料批次号
    • 合格数量
    • 不合格数量
    • -
    • 不合格原因
    • + +
      -
    • 20241011
    • -
    • 5000
    • -
    • 4000
    • -
    • 10
    • -
    • 20241011-TH01
    • -
    • 3950
    • -
    • 40
    • -
    • 崩边
    • - +
    • {{item.mlogb_full[0].batch}}
    • +
    • {{item.mlogb_full[0].count_use}}
    • +
    • {{item.count_real}}
    • +
    • {{ item.count_pn_jgqbl }}
    • +
    • {{item.mlogb_full[1].batch}}
    • +
    • {{item.count_ok}}
    • +
    • {{item.count_notok}}
    • + +
    +
    +
    +
    + +
    +
      +
    • 日志记录
    • +
    +
      +
    • 工艺路线
    • +
    • 工段
    • +
    • 输入物料
    • +
    • 输出物料
    • +
    • 生产设备
    • +
    • 处理人
    • +
    • 开始时间
    • + +
    +
      +
    • {{baseData.routepack_name}}
    • +
    • {{baseData.mgroup_name}}
    • +
    • {{baseData.material_in_name}}
    • +
    • {{baseData.material_out_name}}
    • +
    • {{baseData.equipment_name}}
    • +
    • {{baseData.handle_user_name}}
    • +
    • {{baseData.work_start_time}}
    • + +
    +
      +
    • 温度
    • +
    • 保温时间
    • +
    • 冷却时间
    • +
    • 预估结束时间
    • +
    • 备注层数
    • +
    +
      +
    • 温度
    • +
    • 600
    • +
    • 120
    • +
    • 05:00
    • +
    • 1到10层
    • +
    +
      +
    • 物料清单
    • +
    + +
    +
    {{ index+1 }}
    +
    +
      +
    • 输入物料批次号
    • +
    • 领料数量
    • +
    • 加工数量
    • +
    • 加工前不良数
    • +
    • 输出物料批次号
    • +
    • 合格数量
    • +
    • 不合格数量
    • +
    +
      +
    • {{item.batch}}
    • +
    • {{item.count_use}}
    • +
    • {{item.count_real}}
    • +
    • {{ item.count_pn_jgqbl }}
    • +
    • {{tableData2[index].batch}}
    • +
    • {{tableData2[index].count_ok}}
    • +
    • {{tableData2[index].count_notok}}
    -
    @@ -303,27 +453,27 @@
  • 备注
    • -
    • 1111
    • -
    • 2222
    • -
    • 3333
    • -
    • 4444
    • -
    • 5555
    • -
    • 6666
    • -
    • 7777
    • +
    • {{ baseData.send_mgroup_name }}
    • +
    • {{ baseData.send_user_name }}
    • +
    • {{ baseData.recive_mgroup_name }}
    • +
    • {{ baseData.recive_user_name }}
    • +
    • {{ baseData.send_date }}
    • +
    • {{ baseData.recive_date }}
    • +
    • {{ baseData.note }}
    • 物料清单
      -
    • 物料名称
    • +
    • 批次号
    • 数量
    -
      -
    • 11111111111
    • -
    • 22222222222
    • -
    • 33333333333
    • +
        + +
      • {{ item.batch }}
      • +
      • {{ item.count }}
    @@ -391,6 +541,8 @@
    + 导出 + 打印 @@ -419,6 +571,12 @@ return []; }, }, + tableData2: { + type: Array, + default: () => { + return []; + }, + }, mgroupId: { type: String, default: "", @@ -431,37 +589,36 @@ data() { return { mainLoading: false, - issave: false, //控制基本信息提交 - search: { - keyword: null, - }, - oplcateCode: 'fire', - operationId: "", - oplId: "", - ticketId:'', + codeVisible:false, + value:'' }; }, mounted() { - let that = this; - this.$nextTick(()=>{}) - - - // 'BARCODE 0,130,"128",108,0,0,2,4,"' + let that = this; + that.printId = that.baseData.id; + that.value = that.type + ":" + that.printId+",url:'/wpm_gx/qiepian'"; + that.codeVisible = true; + // var canvas = document.getElementById("barcode"); + // var context = canvas.getContext("2d"); + // context.clearRect(0, 0, context.width, context.height); + // JsBarcode("#barcode", that.printId, { + // format: "CODE128", + // displayValue: true, + // fontSize: 20, + // lineColor: "#000000", + // }); + }, methods: { handlePrint(){ this.$PRINT("#exportDiv"); + this.$emit('closePrint') }, handleExport() { let exportDiv = document.getElementById('exportDiv') // 需要导出部分页面的id名 this.pdfDownLoader = new PdfLoader(exportDiv, '作业许可证', 'exportDiv') // fileName -->导出文件名, question-table -->防止被截断的class名 this.pdfDownLoader.outPutPdfFn('test'); - }, - //作业人员列表 - getworkerList() { - this.$API.opm.worker.list.req({opl: this.oplId, page: 0}).then((res) => { - this.workerData = res; - }); + this.$emit('closePrint'); }, }, } @@ -496,5 +653,17 @@ } .export_ulli_title{ text-align: center; + /* color: #ffffff; */ + background-color: #e3e3e3; +} +.export_ulli_h{ + background-color: #e3e3e3; +} +.flex2{ + flex:2 +} +#barcode { + width: 200px; + height: 60px; } diff --git a/src/views/template/scan.vue b/src/views/template/scan.vue new file mode 100644 index 00000000..46e4d518 --- /dev/null +++ b/src/views/template/scan.vue @@ -0,0 +1,40 @@ + + \ No newline at end of file diff --git a/src/views/wpm_gx/fmlog_detail.vue b/src/views/wpm_gx/fmlog_detail.vue index 6252bce0..4469d483 100644 --- a/src/views/wpm_gx/fmlog_detail.vue +++ b/src/views/wpm_gx/fmlog_detail.vue @@ -6,9 +6,10 @@ destroy-on-close @closed="$emit('closed')" > - - +
    + + 打印 {{ fmlogItem.routepack_name @@ -21,13 +22,9 @@ }} - - - - + {{props.row.count_n_ps}} + + {{props.row.count_n_wj}} + + + {{props.row.count_n_xh}} + + + {{props.row.count_n_yd}} + + + {{props.row.count_n_ps}} +
    @@ -126,7 +135,31 @@ - + + + + + + + + + + + + + + + + + -
    + + + +
    diff --git a/src/views/wpm_gx/handover.vue b/src/views/wpm_gx/handover.vue index 99f86c3c..cc59cead 100644 --- a/src/views/wpm_gx/handover.vue +++ b/src/views/wpm_gx/handover.vue @@ -226,9 +226,13 @@ 保存 + + + diff --git a/src/views/wpm_gx/inm.vue b/src/views/wpm_gx/inm.vue index 14368946..0f002568 100644 --- a/src/views/wpm_gx/inm.vue +++ b/src/views/wpm_gx/inm.vue @@ -93,7 +93,7 @@ fixed="right" align="center" width="120" - v-if="mgroupName!=='size'&&mgroupName!=='facade'" + > @@ -208,6 +209,7 @@ export default { process:'', materialType: "wm", visibleDrawer: false, + printer_name:localStorage.getItem("printer_name") }; }, mounted() { @@ -312,6 +314,32 @@ export default { this.dialog.save = false; this.$refs.table.refresh(); }, + //打印物料标签 + printMaterial(row){ + let that = this; + that.$API.cm.labelmat.fromWm.req({tid:row.id}).then((res) => { + console.log(res) + let code = res.code_label; + let str = [ + "SIZE 40 mm,70 mm", + "GAP 7 mm,7 mm", + "CLS", + "REFERENCE 0,0", + 'QRCODE 30,400,H,5,A,0,"' +code +'"', + "WINTEXT 200,550,28,90,0,0,Simhei," + res.material_name, + "WINTEXT 240,550,28,90,0,0,Simhei," + res.batch, + ]; + if(res.notok_sign!==null){ + str.push("WINTEXT 280,550,28,90,0,0,Simhei," +res.notok_sign_name,) + } + str.push("PRINT 1",) + let obj = {}; + obj.printer_commands = str; + obj.printer_name = that.printer_name; + this.$API.wpm.prints.req(obj).then((response) => {}); + }) + + }, }, }; diff --git a/src/views/wpm_gx/inm_record.vue b/src/views/wpm_gx/inm_record.vue index ab7520f8..43164ae6 100644 --- a/src/views/wpm_gx/inm_record.vue +++ b/src/views/wpm_gx/inm_record.vue @@ -264,6 +264,11 @@ show-overflow-tooltip > + + + - + @@ -336,6 +341,7 @@ export default { userOptions: [],//部门执行人 deptOptions: [], mgroupOptions: [], + printer_name:localStorage.getItem("printer_name") }; }, mounted() { @@ -465,9 +471,34 @@ export default { }); }, submitOut() {}, + //打印 handlePrint(){ this.printVisible = true; - },//打印 + }, + //打印物料标签 + printMaterial(row){ + let that = this; + that.$API.cm.labelmat.fromMioitem.req({tid:row.id}).then((res) => { + let code = res.code_label; + let str = [ + "SIZE 40 mm,70 mm", + "GAP 7 mm,7 mm", + "CLS", + "REFERENCE 0,0", + 'QRCODE 30,400,H,5,A,0,"' +code +'"', + "WINTEXT 200,550,28,90,0,0,Simhei," + res.material_name, + "WINTEXT 240,550,28,90,0,0,Simhei," + res.batch, + ]; + if(res.notok_sign!==null){ + str.push("WINTEXT 280,550,28,90,0,0,Simhei," +res.notok_sign_name,) + } + str.push("PRINT 1",) + let obj = {}; + obj.printer_commands = str; + obj.printer_name = that.printer_name; + this.$API.wpm.prints.req(obj).then((response) => {}); + }) + }, //本地更新数据 handleSaveSuccess() { this.$refs.tables.refresh(); diff --git a/src/views/wpm_gx/mlog_detail.vue b/src/views/wpm_gx/mlog_detail.vue index 2b9ea28e..8ede54f4 100644 --- a/src/views/wpm_gx/mlog_detail.vue +++ b/src/views/wpm_gx/mlog_detail.vue @@ -8,6 +8,7 @@ >
    + 打印 {{ mlogItem.routepack_name @@ -275,6 +276,30 @@ + + + + + + + + + + + + + + + + + + +
    @@ -392,6 +420,7 @@ import editDialog from "./mlog_form.vue"; import saveDialog from "./mlogb_form.vue"; import checkDialog from "./mlogb_check.vue"; +import print from "./../setting/print/A4.vue"; export default { props: { mlogId: { @@ -403,6 +432,7 @@ export default { editDialog, saveDialog, checkDialog, + print }, emits: ["success", "closed"], data() { @@ -416,6 +446,12 @@ export default { check: false, }, apiObj: null, + apiObjWm:null, + paramsWm: { + page: 0, + search:'', + mgroup:'' + }, paramsIn: { page: 0, mlog: "", @@ -449,13 +485,17 @@ export default { 5: "已关闭", }, fileList:[], + tableDataWm:[], test_file:'', deptId: "", visible: false, isSaveing: false, options: [], + tableData:[], + tableData2:[], saveInDialog: false, ticketDialog:false, + printVisible:false, setFiltersVisible: false, rules: { count_use: [ @@ -466,20 +506,25 @@ export default { }, ], }, + batchContains:'' }; }, mounted() { - this.getMlogItem(); + let that = this; this.paramsIn.mlog = this.mlogId; this.paramsOut.mlog = this.mlogId; this.apiObj = this.$API.wpm.mlogb.list; this.getInit(); + that.$API.wpm.mlogb.list.req(that.paramsIn).then((res) => { + that.tableData = res; + }) + that.getMlogItem(); + }, methods: { open() { this.visible = true; }, - getMlogItem() { let that = this; that.$API.wpm.mlog.item.req(that.mlogId).then((res) => { @@ -489,10 +534,22 @@ export default { that.form.test_file = res.test_file; } that.mgroup = res.mgroup; + that.paramsWm.mgroup = res.mgroup; that.materialIn = res.material_in; that.deptId = res.belong_dept; + that.$API.wpm.mlogb.list.req(that.paramsOut).then((res) => { + that.tableData2 = res; + if(res.length>0){ + res.forEach((item) => { + that.batchContains+= item.batch + " "; + }) + that.paramsWm.search = that.batchContains; + that.apiObjWm = that.$API.wpm.wmaterial.list; + } + }) }); }, + //表单注入数据 setData(data) { Object.assign(this.form, data); @@ -638,6 +695,35 @@ export default { this.selectionFilters = filters; this.setFiltersVisible = true; }, + handlePrint(){ + let that = this; + that.printVisible = true; + }, + //打印物料标签 + printMaterial(row){ + let that = this; + that.$API.cm.labelmat.fromWm.req({tid:row.id}).then((res) => { + let code = res.code_label; + let str = [ + "SIZE 40 mm,70 mm", + "GAP 7 mm,7 mm", + "CLS", + "REFERENCE 0,0", + 'QRCODE 30,400,H,5,A,0,"' +code +'"', + "WINTEXT 200,550,28,90,0,0,Simhei," + res.material_name, + "WINTEXT 240,550,28,90,0,0,Simhei," + res.batch, + ]; + if(res.notok_sign!==null){ + str.push("WINTEXT 280,550,28,90,0,0,Simhei," +res.notok_sign_name,) + } + str.push("PRINT 1",) + let obj = {}; + obj.printer_commands = str; + obj.printer_name = that.printer_name; + this.$API.wpm.prints.req(obj).then((response) => {}); + }) + + }, }, }; diff --git a/src/views/wpm_gx/mtask_deliver.vue b/src/views/wpm_gx/mtask_deliver.vue index ea4332fd..2a814cda 100644 --- a/src/views/wpm_gx/mtask_deliver.vue +++ b/src/views/wpm_gx/mtask_deliver.vue @@ -7,6 +7,7 @@ @closed="$emit('closed')" >
    + 打印 {{ @@ -67,10 +68,15 @@ 提交
    + + + diff --git a/src/ehs.js b/src/xui.js similarity index 69% rename from src/ehs.js rename to src/xui.js index 4ccca94b..7c01d58e 100644 --- a/src/ehs.js +++ b/src/xui.js @@ -1,12 +1,14 @@ import ehsUserSelect from './components/ehsSelect/userselect' import ehsEpSelect from './components/ehsSelect/epselect' import ehsSelect from './components/ehsSelect/select' -import xSelect from './components/ehsSelect/xselect.vue' +import ehsTableSelect from './components/ehsSelect/tableSelect' +import xSelect from './components/xSelect/index.vue' export default { install(app) { app.component('ehsUserSelect', ehsUserSelect); app.component('ehsEpSelect', ehsEpSelect); app.component('ehsSelect', ehsSelect); + app.component('ehsTableSelect', ehsTableSelect); app.component('xSelect', xSelect); } }