From b64ed2c784bde6dea9d18149ca706ebe532c857d Mon Sep 17 00:00:00 2001 From: 懒羊羊 <15939171744@163.com> Date: 星期三, 13 三月 2024 08:37:51 +0800 Subject: [PATCH] 操作看板 --- jcdm-ui/src/views/main/kb/stationTerminal/index.vue | 98 +++++++++++++++++++++++++++++++++--------------- 1 files changed, 67 insertions(+), 31 deletions(-) diff --git a/jcdm-ui/src/views/main/kb/stationTerminal/index.vue b/jcdm-ui/src/views/main/kb/stationTerminal/index.vue index cca0c2a..e138770 100644 --- a/jcdm-ui/src/views/main/kb/stationTerminal/index.vue +++ b/jcdm-ui/src/views/main/kb/stationTerminal/index.vue @@ -13,7 +13,7 @@ </el-col> <el-col :span="10"> <el-card shadow="never"> - <span class="head-font">鎬绘垚缂栫爜 : {{headContent.sfcCode}}</span> + <span class="head-font">浜у搧搴忓垪鍙� : {{headContent.sfcCode}}</span> <!-- <el-input v-model="content" style="float: right;width: 150px;" placeholder="璇疯緭鍏ュ唴瀹�"></el-input>--> <!-- <el-button @click="scanCompleted" style="float: right" type="primary">鎵爜瀹屾垚</el-button>--> <el-button type="primary" style="float: right" icon="el-icon-search" size="mini" @click="serialLink">涓插彛杩炴帴</el-button> @@ -32,9 +32,9 @@ <el-descriptions :column="1" border :content-style="{'min-width': '140px'}"> <!-- <el-descriptions :column="1" :label-style="{'font-size': '15px'}" border :content-style="{'min-width': '150px'}">--> <el-descriptions-item label="宸ュ崟缂栧彿"> - <span>{{workpieceInformation.workOrderCode}}</span> + <span>{{workpieceInformation.workOrderNo}}</span> </el-descriptions-item> - <el-descriptions-item label="浜у搧缂栧彿"> + <el-descriptions-item label="浜у搧搴忓垪鍙�"> <span>{{workpieceInformation.productCode}}</span> </el-descriptions-item> <el-descriptions-item label="浜у搧鍨嬪彿"> @@ -43,9 +43,9 @@ <el-descriptions-item label="浜у搧鍚嶇О"> <span>{{workpieceInformation.productName}}</span> </el-descriptions-item> - <el-descriptions-item label="鑺傛媿"> - <span>{{workpieceInformation.beat}}</span> - </el-descriptions-item> +<!-- <el-descriptions-item label="鑺傛媿">--> +<!-- <span>{{workpieceInformation.beat}}</span>--> +<!-- </el-descriptions-item>--> </el-descriptions> <el-divider></el-divider> <el-row> @@ -95,9 +95,9 @@ <!-- </el-col>--> <!-- </el-row>--> -<!-- <el-row style="margin-top: 20px">--> -<!-- <el-button @click="Release" type="primary">鏀捐</el-button>--> -<!-- </el-row>--> + <el-row style="margin-top: 20px"> + <el-button @click="Release" type="primary">鏀捐</el-button> + </el-row> </el-card> </el-col> @@ -289,6 +289,9 @@ import {listFormulaChild, releaseCheck, updateResults, workpieceRelease} from "@/api/main/bs/formulaChild/formulaChild"; import MySerialPort from "@/utils/MySerialPort"; import USBDevice from "@/utils/usb.json"; +import {listProductionOrde} from "@/api/main/om/productionOrde/productionOrde"; +import {addPassingStationCollection} from "@/api/main/da/passingStationCollection/passingStationCollection"; +import {addBasicParameters, addParamCollection} from "@/api/main/da/paramCollection/paramCollection"; export default { name: "stationTerminal", @@ -312,7 +315,7 @@ sfcCode: '10', }, workpieceInformation: { - workOrderCode: null, + workOrderNo: null, productCode: null, productModel: null, productName: null, @@ -366,6 +369,8 @@ isShowSendArea: false, readType: 1, title: "", + + passingStationForm: {}, } }, beforeDestroy() { @@ -406,28 +411,41 @@ this.open1 = true }, Release(){ - //鍒ゆ柇鏄惁鍙互閲婃斁 - let formulaChildParams = { - productCode: this.workpieceInformation.productCode, - processesCode: this.headContent.processesCode + // this.$message('portsList锛�'+this.portsList.length); + if(this.btnType === "danger"){ + this.$message('杩炴帴浜嗭紒'); + + }else { + this.$message('mei杩炴帴浜嗭紒'); + } - releaseCheck(formulaChildParams).then(response => { - if(response.data === 0){ - //鏀瑰彉鐘舵�� - workpieceRelease(formulaChildParams).then(response => { - }); - this.$message('鏀捐鎴愬姛锛�'); - this.formulaChildList = [] - this.getListFormulaChild() - // this.resetting() - }else { - this.$message('姝ラ鏈畬鎴愪笉璁告斁琛岋紒'); - } - }); + + // //鍒ゆ柇鏄惁鍙互閲婃斁 + // let formulaChildParams = { + // productCode: this.workpieceInformation.productCode, + // processesCode: this.headContent.processesCode + // } + // releaseCheck(formulaChildParams).then(response => { + // if(response.data === 0){ + // //鏀瑰彉鐘舵�� + // workpieceRelease(formulaChildParams).then(response => { + // }); + // this.$message('鏀捐鎴愬姛锛�'); + // this.formulaChildList = [] + // this.getListFormulaChild() + // // this.resetting() + // }else { + // this.$message('姝ラ鏈畬鎴愪笉璁告斁琛岋紒'); + // } + // }); }, serialPortMethod(value){ let formulaChildParams = { - materialCode: value + materialCode: value, + workOrderNo: this.workpieceInformation.workOrderNo, + productCode: this.workpieceInformation.productCode, + locationCode: this.headContent.processesCode, + collectionTime: new Date() } updateResults(formulaChildParams).then(response => { this.getListFormulaChild() @@ -466,12 +484,12 @@ this.cakeLamp.startWork = 1 }, - /** 鏌ヨ鎶ュ伐璁板綍 琛ㄥ垪琛� */ + /** 鏌ヨ宸ュ崟鍒楄〃 */ async getList() { - await listWorkReport(this.queryParams).then(response => { + await listProductionOrde(this.queryParams).then(response => { let rowsData = response.rows[0]; console.log(rowsData) - this.workpieceInformation.workOrderCode = rowsData.workOrderCode; + this.workpieceInformation.workOrderNo = rowsData.workOrderNo; this.workpieceInformation.productCode = rowsData.productCode; this.workpieceInformation.productModel = rowsData.productModel; this.workpieceInformation.productName = rowsData.productName; @@ -480,6 +498,24 @@ }, 1000); }); this.getListFormulaChild() + this.addOverStationCollection() + }, + + /** 鍏ョ珯澧炲姞杩囩珯閲囬泦璁板綍 **/ + addOverStationCollection(){ + this.passingStationForm = { + id: null, + workOrderNo: this.workpieceInformation.workOrderNo, + productCode: this.workpieceInformation.productCode, + locationCode: this.headContent.processesCode, + model: this.workpieceInformation.productModel, + productBarcode: this.headContent.sfcCode, + inboundTime: new Date() + } + addPassingStationCollection(this.passingStationForm).then(response => { + }); + addBasicParameters(this.passingStationForm).then(response => { + }); }, allowRelease(){ clearInterval(this.timer); -- Gitblit v1.9.3