From afbddf62e45bce6fd9428cddec36382c75cee53a Mon Sep 17 00:00:00 2001 From: wu <731351411@qq.com> Date: 星期四, 07 十二月 2023 08:38:09 +0800 Subject: [PATCH] Merge branch 'master' of http://10.153.19.25:10101/r/CanadaMes --- CanadaMes-ui/src/views/home/index.vue | 205 +++++++++++++++++++++++--------------------------- 1 files changed, 94 insertions(+), 111 deletions(-) diff --git a/CanadaMes-ui/src/views/home/index.vue b/CanadaMes-ui/src/views/home/index.vue index 4005110..88190e1 100644 --- a/CanadaMes-ui/src/views/home/index.vue +++ b/CanadaMes-ui/src/views/home/index.vue @@ -199,6 +199,10 @@ font-size: 25px; } +@media screen and (min-width: 1900px) { + .blocks{transform: scale(1.5,1.05);width: 1210px;} +} + .el-message-box__btns { padding: 0px 15px 0; text-align: right; @@ -315,7 +319,7 @@ <div class="blocks-img2"></div> <div class="blocks-img3"></div> <el-button class="orderbutton1" type="primary" @click="showform2()">{{ $t('OrderInfo') }}</el-button> - <el-button class="orderbutton2" type="primary" @click="showform6()">{{ $t('Production queue') }}</el-button> + <el-button class="orderbutton2" type="primary" @click="showform6()">{{ $t('Outing Queue') }}</el-button> <!-- <div style="display:flex;position: absolute;float:left;z-index: 999;top:112px;left:328px;"> <div :class="getStatusClass(item.state)" v-for="(item,index) in cagelist1" :key="item['date']" @@ -419,14 +423,14 @@ <el-button type="primary" @click="showcageinfo(1)">{{ $t('Query') }}</el-button> <el-table :data="cageinfo.slice((currentPages - 1) * pagesizes, currentPages * pagesizes)" :height="700" border style="width: 100%;overflow: auto;"> - <el-table-column :width="90" prop="cage" :label="$t('Cage No')"></el-table-column> - <el-table-column :width="90" prop="cell" :label="$t('Slot No')"></el-table-column> - <el-table-column :width="55" prop="tier" :label="$t('The Side')"></el-table-column> - <el-table-column :width="145" prop="glassId" :label="$t('Barcode')"></el-table-column> - <el-table-column :width="100" prop="orderId" :label="$t('Order No')"></el-table-column> - <el-table-column :width="80" prop="listId" :label="$t('List No')"></el-table-column> - <el-table-column :width="100" prop="boxId" :label="$t('Box No')"></el-table-column> - <el-table-column :width="100" prop="state" :label="$t('State')"> + <el-table-column :min-width="50" prop="cage" :label="$t('Cage No')"></el-table-column> + <el-table-column :min-width="50" prop="cell" :label="$t('Slot No')"></el-table-column> + <el-table-column :min-width="55" prop="tier" :label="$t('The Side')"></el-table-column> + <el-table-column :min-width="145" prop="glassId" :label="$t('Barcode')"></el-table-column> + <el-table-column :min-width="100" prop="orderId" :label="$t('Order No')"></el-table-column> + <el-table-column :min-width="80" prop="listId" :label="$t('List No')"></el-table-column> + <el-table-column :min-width="100" prop="boxId" :label="$t('Box No')"></el-table-column> + <el-table-column :min-width="90" prop="state" :label="$t('State')"> <template slot-scope='scope'> {{ scope.row.state == 1 ? $t('Normal') : scope.row.state == 2 ? $t('Entering') : scope.row.state == 3 ? @@ -434,12 +438,12 @@ }} </template> </el-table-column> - <el-table-column :width="150" prop="lengthWidth" :label="$t('Dim')"> + <el-table-column :min-width="150" prop="lengthWidth" :label="$t('Dim')"> <template slot-scope='scope'> {{ scope.row.glassWidthMm }}{{ scope.row.glassWidthMm > 0 ? "*" : "" }}{{ scope.row.glassHeightMm }} </template> </el-table-column> - <el-table-column :width="280" :label="$t('Operate')"> + <el-table-column :min-width="250" :label="$t('Operate')"> <template slot-scope='scope'> <el-button type="primary" style="padding: 4px 10px;font-size: 12px;" @click="deleteglass(scope.row.glassId, scope.row.state)">{{ $t('Delete') }}</el-button> @@ -614,11 +618,9 @@ </template> </el-dialog> - <el-dialog :visible.sync="dialogFormVisible6" :title="$t('Production queue')" top="5vh"> - <!-- <el-button type="primary" @click="showform7()">{{ $t('Increase') }}</el-button> --> + <el-dialog :visible.sync="dialogFormVisible6" :title="$t('Outing Queue')" top="5vh"> <el-button type="primary" @click="isAllowQueueState()">{{ this.isAllowQueue == true ? $t('Start') : $t('Stop') }}</el-button> - <el-table :data="this.OutSlice" :height="700" :span-method="objectSpanMethod" border style="width: 100%;overflow: auto;"> <el-table-column prop="glassId" :label="$t('Barcode')"></el-table-column> @@ -637,16 +639,17 @@ <el-table-column prop="barcode" :label="$t('Frame No')"></el-table-column> <el-table-column :width="280" :label="$t('Operate')"> <template slot-scope='scope'> - <el-button type="text" size="small" @click="getTopMove(scope.row, scope.$index)" + <el-button type="text" size="small" @click="getTopMove(scope.row, scope.$index)" style="font-size: 15px;" :disabled="(scope.$index == 0 || isAllowQueue == true || scope.row.state == 1)"> - 缃《 + {{$t('Top')}} </el-button> - <el-button type="text" size="small" @click="getUpMove(scope.row, scope.$index)" + <el-button type="text" size="small" @click="getUpMove(scope.row, scope.$index)" style="font-size: 15px;" :disabled="(scope.$index == 0 || isAllowQueue == true || scope.row.state == 1)"> - 涓婄Щ + {{$t('Up')}} </el-button> - <el-button type="text" size="small" @click="getDownMove(scope.row, scope.$index)" - :disabled="(OutSlice.length - 1 == scope.$index || isAllowQueue == true || scope.row.state == 1)">涓嬬Щ + <el-button type="text" size="small" @click="getDownMove(scope.row, scope.$index)" style="font-size: 15px;" + :disabled="(OutSlice.length - 1 == scope.$index || isAllowQueue == true || scope.row.state == 1)"> + {{$t('Down')}} </el-button> <el-button type="primary" style="padding: 4px 10px;font-size: 12px;" :disabled="isAllowQueue" @click="deleteproductionqueueglass(scope.row.barcode)">{{ $t('Delete') }}</el-button> @@ -671,9 +674,7 @@ <el-table-column prop="storageCage.cage" :label="$t('Cage No')"></el-table-column> <el-table-column prop="storageCage.cell" :label="$t('Slot No')"></el-table-column> <el-table-column prop="storageCage.tier" :label="$t('The Side')"></el-table-column> - <el-table-column prop="FrameNo" :label="$t('Frame No')"></el-table-column> - <el-table-column prop="Flip" :label="$t('Flip')"></el-table-column> <el-table-column prop="out_slice.state" :label="$t('In the queue')"> <template slot-scope='scope'> @@ -795,7 +796,7 @@ console.log("鎮ㄧ殑娴忚鍣ㄤ笉鏀寔WebSocket"); } else { //console.log("鎮ㄧ殑娴忚鍣ㄦ敮鎸乄ebSocket"); - let socketUrl = "ws://" + this.$t('ip')+":8888" + "/springboot-vue3/api/talk/" + viewname; + let socketUrl = "ws://" + this.$t('ip') + ":8888" + "/springboot-vue3/api/talk/" + viewname; if (socket != null) { socket.close(); socket = null; @@ -833,41 +834,39 @@ if (this.isAllowQueue == true) { this.OutSlice = obj.listoutslice[0]; } + //鑾峰彇涓婄墖浣嶇幓鐠冧俊鎭� this.loadglassheight = obj.loadglassheight; if (obj.zhuangtai != null) { this.zhuangtai = obj.zhuangtai[0]; } - // if (this.dialogFormVisible7 == true) { - // this.showform7(); - // } else { - // if (obj.FrameNo != null && obj.FrameNo != "") { - // this.framebarcode = obj.FrameNo[0]; - // this.showform7(); - // this.addoutslice(); - // } - // } + //涓婄墖浣嶇幓鐠冧俊鎭� if (obj.form2 != null && obj.form2 != "") { this.form2 = obj.form2[0]; } else { this.form2 = {}; } + + //鏄惁闇�瑕佹墜鍔ㄧ‘璁や笂鐗� + this.isConfirm = obj.isConfirm[0]; + //鎵爜浣嶇幓鐠冧俊鎭� if (obj.form3 != null && obj.form3 != "" && obj.state[0] == 1) { this.form3 = obj.form3[0]; } else { this.form3 = {}; } - this.isConfirm = obj.isConfirm[0]; if (obj.form3 != null && obj.form3 != "" && obj.state[0] == 0) { this.form5 = obj.form3[0]; this.showform3(); - this.Sizerange(this.form5); + this.Sizerange(this.form5, 3); } else { - this.Sizerange(this.form5); + this.Sizerange(this.form5, 3); } + //鏁版嵁搴撹繛鎺ユ槸鍚︽甯� if (obj.dbconnected == "false") { this.text = this.$t('DataBase Connection failed'); } + //鐞嗙墖绗肩幓鐠冧俊鎭� if (this.dialogFormVisible3 == true) { SelectCageInfo(this.cageglassid).then(res => { this.cageinfo = res.data.cageinfo; @@ -893,7 +892,8 @@ home().then(res => { this.tableData = res.data.list; }); - SelectCageInfo(1).then(res => { + //鍔犺浇鐞嗙墖绗肩幓鐠冧俊鎭� + SelectCageInfo("").then(res => { this.cageinfo = res.data.cageinfo; this.currentPages = 1; }); @@ -1019,62 +1019,58 @@ }, //鑾峰彇鎵爜浣嶅拰涓婄墖浣嶆暟鎹� SelectGlassByGlassIDs(parameter) { - this.showform3(); if (parameter == 1) { SelectGlassByGlassID(this.glassid2).then(res => { if (res.data.form != null) { - this.form4 = res.data.form; - this.$message.success(this.$t('query was successful')); - this.Sizerange(this.form4); + if (res.data.form.glassId != null) { + this.form4 = res.data.form; + this.$message.success(this.$t('query was successful')); + this.Sizerange(this.form4, 2); + } else { + this.$message.error(this.$t('There is no such glass')); + } + } else { this.$message.error(this.$t('There is no such glass')); } - if (this.form4.length > 0) { - if (this.form4.glassId == "") { - this.disabled = false; - } else { - this.disabled = true; - } - } - }); } else { SelectGlassByGlassID(this.glassid1).then(res => { if (res.data.form != null) { - this.form5 = res.data.form; - this.$message.success(this.$t('query was successful')); - this.Sizerange(this.form5); + if (res.data.form.glassId != null) { + this.form5 = res.data.form; + this.$message.success(this.$t('query was successful')); + this.Sizerange(this.form5, 1); + } else { + this.$message.error(this.$t('There is no such glass')); + } } else { this.$message.error(this.$t('There is no such glass')); } - if (this.form5.length > 0) { - if (this.form5.glassId == "") { - this.disabled = false; - } else { - this.disabled = true; - } - } - }); } }, + //鏌ヨ瀹㈡埛鐜荤拑淇℃伅 selectglassinfo() { SelectGlass(this.orderid).then(res => { this.currentPage = 1; this.GlassInfo = res.data.glass; }); }, + //鏄剧ず瀹㈡埛鐜荤拑淇℃伅 showform2() { SelectGlass(this.orderid).then(res => { this.GlassInfo = res.data.glass; }); this.dialogFormVisible4 = true; }, + //鏄剧ず鍑虹墖闃熷垪 showform6() { this.dialogFormVisible6 = true; }, + //鏄剧ず閾濇瀵瑰簲鐜荤拑淇℃伅 showform7() { //鏌ヨ閾濇id瀵瑰簲鐜荤拑淇℃伅 SelectAluminumFrameInfoById(this.framebarcode).then(res => { @@ -1111,6 +1107,7 @@ this.dialogFormVisible1 = false; this.form1 = {}; }, + //鍙栨秷鎿嶄綔鏃跺叧闂〉闈� cancel3() { this.dialogFormVisible5 = false; this.form1 = {}; @@ -1144,7 +1141,6 @@ showcageinfo(cage) { cage = this.cageglassid; SelectCageInfo(cage).then(res => { - this.cageinfo = res.data.cageinfo; this.currentPages = 1; this.dialogFormVisible3 = true; @@ -1282,8 +1278,6 @@ message: this.$t('Operation canceled') }); }); - }, handleEdit(index, row) { - console.log(index, row); }, //琛ㄦ牸鍒犻櫎 handleDelete(index, row) { @@ -1363,9 +1357,11 @@ } }); }, + //閾濇瀵瑰簲鐜荤拑淇℃伅娣诲姞閾濇id鍜屾槸鍚︽坊鍔犲埌闃熷垪 CheckBoxchange(glassid, isChecked) { this.AluminumFrame.forEach(item => { item.barcode = glassid; item.isCheck = isChecked }) }, + //娣诲姞鍒板嚭鐗囬槦鍒� addoutslice() { var dats_ = new Array(); this.AluminumFrame.forEach(item => { @@ -1383,7 +1379,9 @@ this.$message.success(this.$t('Operation successful')); } }); - }, getTopMove(row, index) { + }, + //缃《 + getTopMove(row, index) { let Sequence = []; this.OutSlice.forEach(item => { Sequence.push(item.sequence); @@ -1485,6 +1483,7 @@ } this.UpdateSequence(Sequence); }, + //淇敼椤哄簭 UpdateSequence(Sequence) { let i = 0; this.OutSlice.forEach(item => { @@ -1509,16 +1508,6 @@ }); } , - arraySpanMethod({ row, column, rowIndex, columnIndex }) { - console.log(row, column); - if (rowIndex % 2 === 0) { - if (columnIndex === 0) { - return [1, 2]; - } else if (columnIndex === 1) { - return [0, 0]; - } - } - }, //鍚堝苟琛� objectSpanMethod({ row, column, rowIndex, columnIndex }) { // console.log(row, column, "ss"); @@ -1533,7 +1522,7 @@ if (rowIndex != 0) { barcode2 = arrOutSlice[rowIndex - 1].barcode; } - if (columnIndex === 9) { + if (columnIndex === 10) { if (barcode != barcode2) { // this.FrameNoFlag = barcode; for (let i = rowIndex; i < this.OutSlice.length; i++) { @@ -1558,46 +1547,40 @@ } }, //鍒ゆ柇鐜荤拑鏄惁瓒呭嚭鑼冨洿 - Sizerange(Glass) { + Sizerange(Glass, position) { if ((Glass.glassheight < 380 || Glass.glasswidth < 390 || Glass.glassheight > 1810 || Glass.glasswidth > 2760) || (Glass.glassheight < 390 || Glass.glasswidth < 380 || Glass.glassheight > 2760 || Glass.glasswidth > 1810)) { - // if (this.disabled == false) { + this.$alert(this.$t('The glass size is not within the range'), this.$t('confirm'), { + confirmButtonText: this.$t('Yes'), + type: 'info', + callback: (action) => { + this.$message({ + type: 'info', + message: `action: ${ action }` + }).then( + this.DeleteBarcodeGlass() + ); + } + }); + if (position == 1 || position == 3) { + this.disabled1 = true; + } else { this.disabled = true; - // this.$message.error(this.$t('The glass size is not within the range')); - this.$alert(this.$t('The glass size is not within the range'), this.$t('confirm'), { - confirmButtonText: this.$t('Yes'), - type:'info', - callback: action => { - this.$message({ - type: 'info', - action: action - }).then( - this.DeleteBarcodeGlass() - ); - } - }); - // } - // this.$message(this.$t('The glass size is not within the range'), this.$t('confirm'), { - // // confirmwidth: 7000, - // // height: 8000, - // confirmButtonText: this.$t('Yes'), - // type: 'info' - // }).then(() => { - // this.$message.success(this.$t('Operation successful')); - // }).catch(() => { - // this.$message({ - // type: 'warning', - // message: this.$t('Operation canceled') - // }); - // }); - // } - this.disabled1 = true; - } else { - this.disabled1 = false; + } + } else { + if (position == 1 || position == 3) { + this.disabled1 = false; + } else { + this.disabled = false; + } + if (position == 3&&this.isConfirmState==true) { + this.InsertQueueGlass(1); + } + } + }, + //娓呯┖寰呯‘璁ょ幓鐠冧俊鎭� + DeleteBarcodeGlass() { + this.form5 = {}; } - }, - DeleteBarcodeGlass(){ - this.form5={}; } -} } </script> \ No newline at end of file -- Gitblit v1.8.0