From cfa9e919f0b4fbcc2e036c67799b2ffc102376d8 Mon Sep 17 00:00:00 2001 From: ZengTao <2773468879@qq.com> Date: 星期五, 10 五月 2024 15:58:26 +0800 Subject: [PATCH] 根据客户需求修改主界面权限设置,取消部分按钮,调整部分英文名称,添加铝框显示 --- CanadaMes-ui/src/views/home/index.vue | 119 ++++++++++++++++++++++++++++++++++++++++++++--------------- 1 files changed, 88 insertions(+), 31 deletions(-) diff --git a/CanadaMes-ui/src/views/home/index.vue b/CanadaMes-ui/src/views/home/index.vue index a3b57e4..ee8fe16 100644 --- a/CanadaMes-ui/src/views/home/index.vue +++ b/CanadaMes-ui/src/views/home/index.vue @@ -259,13 +259,13 @@ <el-button type="primary" @click="showform2()" :disabled="OrderInfo" :class="OrderInfo == true ? 'hide' : ''">{{ $t('Order Info') }}</el-button> - <el-button type="primary" @click="showcageinfo(1)" :disabled="OrderInfo" + <el-button type="primary" @click="showcageinfo(1)" :disabled="CageDetails" :class="CageDetails == true ? 'hide' : ''">{{ $t('Cage Details') }}</el-button> <el-button type="primary" @click="showform6()" :disabled="OutingQueue" :class="OutingQueue == true ? 'hide' : ''"> {{ $t('Outfeed Queue') }}</el-button> - <el-button type="primary" @click="TaskStop(0)" :disabled="OutingQueue" + <!-- <el-button type="primary" @click="TaskStop(0)" :disabled="OutingQueue" :class="StopTask == true ? 'hide' : ''"> {{ $t('Terminate Feeding') }}</el-button> <el-button type="primary" @click="TaskStop(1)" :disabled="StopTask" @@ -273,7 +273,7 @@ {{ $t('Terminate Outing') }}</el-button> <el-button type="primary" @click="SoftEmergencyStop()" :disabled="SoftEmergencyStopState" :class="SoftEmergencyStopState == true ? 'hide' : ''"> - {{ $t('SoftEmergencyStop') }}</el-button> + {{ $t('SoftEmergencyStop') }}</el-button> --> <!-- <el-input style="width:15%;" :placeholder="$t('Enter the Order No')" v-model="order"></el-input> <el-button type="warning" @click="showform1();">{{ $t('Exit the glass by order number') }}</el-button> --> </div> @@ -295,7 +295,7 @@ {{ scope.row.glasswidthmm }}*{{ scope.row.glassheightmm }} </template> </el-table-column> - <el-table-column :label="$t('Task Complete')"> + <el-table-column :label="$t('Abort')"> <template slot-scope='scope'> <el-button type="primary" style="padding: 4px 10px;font-size: 12px;" @click="endtask(1, scope.row.glassId, scope.row.cell)">{{ $t('Task Complete') @@ -321,7 +321,7 @@ </template> </el-table-column> - <el-table-column :label="$t('Task Complete')"> + <el-table-column :label="$t('Abort')"> <template slot-scope='scope'> <el-button type="primary" style="padding: 4px 10px;font-size: 12px;" @click="endtask(0, scope.row.glassId, scope.row.cell)">{{ $t('Task Complete') @@ -416,66 +416,66 @@ <div class="glass D01" style="top: 39px;left: 1055px;position: absolute;">{{ ShowGlassIdList(0) }} <br /> <el-button type="primary" size="mini" @click="ClearGlassId('DB101.9.2', 0)"> - {{ $t('Confirmation needed') }}</el-button> + {{ $t('Clear') }}</el-button> </div> <div class="glass D02" style="top: 117px;left: 1055px;position: absolute;">{{ ShowGlassIdList(1) }} <br /> <el-button type="primary" size="mini" @click="ClearGlassId('DB101.9.3', 1)"> - {{ $t('Confirmation needed') }}</el-button> + {{ $t('Clear') }}</el-button> </div> <div class="glass B01" style="top: 270px;left: 640px;position: absolute;"> B01:{{ ShowGlassIdList(2) }} <br /> <el-button type="primary" size="mini" @click="ClearGlassId('DB101.10.2', 2)"> - {{ $t('Confirmation needed') }}</el-button> + {{ $t('Clear') }}</el-button> </div> <div class="glass B02" style="top: 315px;left: 640px;position: absolute;">B02:{{ ShowGlassIdList(3) }} <br /> <el-button type="primary" size="mini" @click="ClearGlassId('DB101.10.3', 3)"> - {{ $t('Confirmation needed') }}</el-button> + {{ $t('Clear') }}</el-button> </div> <div class="glass A01" style="top: 270px;left: 289px;position: absolute;"> A01.1:{{ ShowGlassIdList(4) }} <br /> <el-button type="primary" size="mini" @click="ClearGlassId('DB101.10.0', 4)"> - {{ $t('Confirmation needed') }}</el-button> + {{ $t('Clear') }}</el-button> </div> <div class="glass A01" style="top: 315px;left: 289px;position: absolute;">A01.2:{{ ShowGlassIdList(5) }} <br /> <el-button type="primary" size="mini" @click="ClearGlassId('DB101.10.0', 5)"> - {{ $t('Confirmation needed') }}</el-button> + {{ $t('Clear') }}</el-button> </div> <div class="glass A02" style="top: 360px;left: 289px;position: absolute;">A02:{{ ShowGlassIdList(6) }} <br /> <el-button type="primary" size="mini" @click="ClearGlassId('DB101.10.1', 6)"> - {{ $t('Confirmation needed') }}</el-button> + {{ $t('Clear') }}</el-button> </div> <div class="glass D03" style="top: 122px;left: 42px;position: absolute;"> {{ ShowGlassIdList(7) }} <br /> <el-button type="primary" size="mini" @click="ClearGlassId('DB101.9.4', 7)"> - {{ $t('Confirmation needed') }}</el-button> + {{ $t('Clear') }}</el-button> </div> <div class="glass D04" style="top: 198px;left: 42px;position: absolute;"> {{ ShowGlassIdList(8) }} <br /> <el-button type="primary" size="mini" @click="ClearGlassId('DB101.9.5', 8)"> - {{ $t('Confirmation needed') }}</el-button> + {{ $t('Clear') }}</el-button> </div> <div class="glass D05" style="top: 275px;left: 42px;position: absolute;"> {{ ShowGlassIdList(9) }} <br /> <el-button type="primary" size="mini" @click="ClearGlassId('DB101.9.6', 9)"> - {{ $t('Confirmation needed') }}</el-button> + {{ $t('Clear') }}</el-button> </div> <div class="glass D06" style="top: 352px;left: 42px;position: absolute;"> {{ ShowGlassIdList(10) }} <br /> <el-button type="primary" size="mini" @click="ClearGlassId('DB101.9.5', 10)"> - {{ $t('Confirmation needed') }}</el-button> + {{ $t('Clear') }}</el-button> </div> @@ -598,16 +598,20 @@ <el-table-column :min-width="250" :label="$t('Operate')"> <template slot-scope='scope'> <el-button type="primary" style="padding: 4px 10px;font-size: 12px;" - :disabled="scope.row.state == 1 ? false : true" + :disabled="(scope.row.state == 1&&loadname=='admin') ? false : true" @click="deleteglass(scope.row.glassId, scope.row.state)">{{ $t('Delete') }}</el-button> + <el-button type="primary" style="padding: 4px 10px;font-size: 12px;" - :disabled="scope.row.state == 1 ? false : true" + :disabled="(scope.row.state == 1&&(loadname=='admin'||loadname=='Transfer')) ? false : true" @click="outglass(scope.row.glassId, scope.row.state)">{{ $t('Outfeed') }}</el-button> + <el-button type="primary" style="padding: 4px 10px;font-size: 12px;" + :disabled="(loadname=='admin') ? false : true" @click="UpdateDisabled(scope.row.cage, scope.row.cell, scope.row.disabled == 0 ? 1 : 0)"> {{ scope.row.disabled == 0 ? $t('Disable') : $t('Enable') }}</el-button> + <el-button type="primary" style="padding: 4px 10px;font-size: 12px;" - :disabled="scope.row.glassId != null ? true : false" + :disabled="(scope.row.glassId == null&&loadname=='admin') ? false : true" @click="insertglass(scope.row.cage, scope.row.cell, scope.row.tier)">{{ $t('Add') }}</el-button> </template> @@ -832,9 +836,12 @@ <div style="width:30%;" v-for="(item) in CurrentFrame" :key="item['barcode']"> <el-button style="margin-left: 42%;" type="primary" @click="FrameStateUpdate(item['barcode'])">{{ $t('Next') }}</el-button> - <h1 style="font-size: 40px;text-align: center;">{{ $t('Current Frame') }}:{{ item['barcode'] }}</h1> + <h1 style="font-size: 40px;text-align: center;">{{ $t('Current Frame') }}:</h1> + <h1 style="font-size: 40px;text-align: center;">{{ $t('Barcode') }}:{{ item['barcode'] }}</h1> + <h1 style="font-size: 40px;text-align: center;">{{ $t('List No') }}:{{ item['listId'] }}</h1> + <h1 style="font-size: 40px;text-align: center;">{{ $t('Box No') }}:{{ item['boxId'] }}</h1> <h1 style="font-size: 30px;text-align: center;"> - {{ item['flip'] == true ? $t('EXTERIQR OUT AND BYPASS TO THE LEFT') + {{ item['flip'] == 1 ? $t('EXTERIQR OUT AND BYPASS TO THE LEFT') : $t('EXTERIQR OUT AND BYPASS TO THE RIGHT') }} </h1> <h1 style="font-size: 30px;text-align: center;">{{ item['framewidthmm'] }}*{{ item['frameheightmm'] @@ -853,11 +860,12 @@ <el-dialog :visible.sync="dialogFormVisible7" :title="$t('Glass information corresponding to aluminum frame')" top="5vh"> + <el-input style="width:15%;" :placeholder="$t('Enter the Frame No')" v-model="framebarcode"></el-input> <el-button type="primary" @click="showform7()">{{ $t('Query') }}</el-button> - <el-button type="primary" @click="AddOutSliceS()">{{ $t('Outfeed') }}</el-button> + <el-button type="primary" @click="AddOutSliceS()" :disabled="framestate">{{ $t('Outfeed') }}</el-button> <el-button type="primary" @click="CloseForm7()">{{ $t('Cancel') }}</el-button> - <el-table :data="this.AluminumFrame" :height="700" border style="width: 100%;overflow: auto;"> + <el-table :data="this.AluminumFrame" :height="200" border style="width: 100%;overflow: auto;"> <el-table-column prop="frameBarcode" :label="$t('Frame No')"></el-table-column> <el-table-column prop="barcode" :label="$t('Barcode')"></el-table-column> <el-table-column prop="ordernumber" :label="$t('Order No')"></el-table-column> @@ -868,7 +876,9 @@ <el-table-column prop="storageCage.cage" :label="$t('Cage No')"></el-table-column> <el-table-column prop="storageCage.cell" :label="$t('Slot No')"> <template slot-scope='scope'> - {{ (scope.row.cage - 1) * 21 + scope.row.cell }} + {{ + scope.row.storageCage == null ? "" : (scope.row.storageCage.cage-1)*21+scope.row.storageCage.cell + }} </template> </el-table-column> <el-table-column prop="storageCage.tier" :label="$t('The Side')"> @@ -892,6 +902,27 @@ </template> </el-table-column> </el-table> + <div style="width:30%;" v-for="(item) in AluminumFrameInfo" :key="item['barcode']"> + <!-- <el-button style="margin-left: 42%;" type="primary" @click="FrameStateUpdate(item['barcode'])">{{ + $t('Next') }}</el-button> --> + <h1 style="font-size: 40px;text-align: center;">{{ $t('Current Frame') }}:</h1> + <h1 style="font-size: 40px;text-align: center;">{{ $t('Barcode') }}:{{ item['barcode'] }}</h1> + <h1 style="font-size: 40px;text-align: center;">{{ $t('List No') }}:{{ item['listnumber'] }}</h1> + <h1 style="font-size: 40px;text-align: center;">{{ $t('Box No') }}:{{ item['boxnumber'] }}</h1> + <h1 style="font-size: 30px;text-align: center;"> + {{ item['flip'] == 1 ? $t('EXTERIQR OUT AND BYPASS TO THE LEFT') + : $t('EXTERIQR OUT AND BYPASS TO THE RIGHT') }} + </h1> + <h1 style="font-size: 30px;text-align: center;">{{ item['framelength'] }}*{{ item['frameheight'] + }} + </h1> + + <div class="frame" :style="'background-color: '+ framecolor +';margin-top:30px;margin:0 auto;width: ' + + FrameWidthHeight('before', item['framelengthmm'], item['frameheightmm'], item['flip']) + 'px;height:' + + FrameWidthHeight('after', item['framelengthmm'], item['frameheightmm'], item['flip']) + 'px;' + "> + </div> + </div> </el-dialog> <el-dialog :visible.sync="dialogFormCountDown" :title="$t('Approximately resettable time')" top="5vh"> <div :style="'font-size: ' + PromptSize + 'px;text-align: center;'"> @@ -1016,7 +1047,10 @@ form6state:0, StateColor:"green", plc1:"", - plc2:"" + plc2:"", + AluminumFrameInfo:{}, + framestate:false, + framecolor:"green" }; }, created() { @@ -1026,7 +1060,6 @@ this.count1=this.count2; }else{ const now = new Date(); - console.log(this.count1,this.count2); console.log(this.$t('Mes Connection failed')+now); } }, 60000); @@ -1118,6 +1151,28 @@ if (this.dialogFormVisible6 == true) { this.dialogFormVisible7 = true; } + } + if (obj.AluminumFrameInfo != null) { + this.AluminumFrameInfo = obj.AluminumFrameInfo; + if(this.AluminumFrameInfo[0].frameheightmm>this.AluminumFrameInfo[0].framelengthmm){ + if(this.AluminumFrameInfo[0].frameheightmm<600||this.AluminumFrameInfo[0].framelengthmm<400){ + this.framestate=true; + this.framecolor="red"; + }else{ + this.framestate=false; + this.framecolor="green"; + } + }else{ + if(this.AluminumFrameInfo[0].frameheightmm<400||this.AluminumFrameInfo[0].framelengthmm<600){ + this.framestate=true; + this.framecolor="red"; + }else{ + this.framestate=false; + this.framecolor="green"; + } + } + }else{ + this.AluminumFrameInfo={}; } //鏍规嵁杩涚墖鐘舵�佸嚭鍙戣繘鐗囦换鍔� @@ -1377,7 +1432,7 @@ height = this.form.glasswidth; width = this.form.glassheight; } - if (height < 380 || width < 380 || height > 1810 || width > 2760) { + if (height < 225 || width < 380 || height > 1810 || width > 2760) { this.$message.error(this.$t('The glass size is not within the range')); } else { if (this.zhuangtai == true) { @@ -1440,8 +1495,9 @@ WriteGlassID() { if (this.glassid1.length == 14) { WriteGlassID(this.glassid1).then(res => { - console.log(res.data); - this.$message.success(this.$t('Successful operation')); + if (res.data.message == 200) { + this.$message.success(this.$t('Successful operation')); + } }); } else { this.$message.error(this.$t('Please enter the correct glassID')); @@ -1812,7 +1868,9 @@ CloseForm7().then(res => { if (res.data.message == 200) { this.AluminumFrame = null; + this.AluminumFrameInfo = null; this.dialogFormVisible7 = false; + this.framebarcode=""; this.$message.success(this.$t('Operation successful')); } }); @@ -2011,7 +2069,6 @@ }, //鍒ゆ柇鐜荤拑鏄惁瓒呭嚭鑼冨洿 Sizerange(Glass, position) { - console.log(position); if (this.ManuallyInfeedGlass == false) { let width = 0; let height = 0; @@ -2022,7 +2079,7 @@ height = Glass.glasswidth; width = Glass.glassheight; } - if (height < 380 || width < 380 || height > 1810 || width > 2760) { + if (height < 225 || width < 380 || height > 1810 || width > 2760) { this.$alert(this.$t('The glass size is not within the range'), this.$t('confirm'), { confirmButtonText: this.$t('Yes'), type: 'info', -- Gitblit v1.8.0