From 865d48080cd33ee051ee6296b5fc9a0ece98b60b Mon Sep 17 00:00:00 2001
From: pjb <123456>
Date: 星期日, 01 六月 2025 13:45:55 +0800
Subject: [PATCH] 电子标签显示捡货数量
---
construction-data/src/components/datav/index.vue | 182 +++++++++++++++++++++++++++++++--------------
1 files changed, 126 insertions(+), 56 deletions(-)
diff --git a/construction-data/src/components/datav/index.vue b/construction-data/src/components/datav/index.vue
index 58a98d2..21760c7 100644
--- a/construction-data/src/components/datav/index.vue
+++ b/construction-data/src/components/datav/index.vue
@@ -4,14 +4,14 @@
<top-header/>
<template>
<el-row>
- <el-col :span="15">
+ <el-col :span="13">
<el-row class="header-left-task" type="flex" align="center" >
<el-col v-for="(task, index) in tasks" :key="index" >
<el-row type="flex" align="center" justify="center" @click.native="borderClick(task)">
<dv-border-box-2>
<el-card class="header-card" >
<el-row>
- <el-col :span="4" v-for="(item, index) in Object.keys(waveLabels)" :key="index">
+ <el-col class="heaer-label-column" v-for="(item, index) in Object.keys(waveLabels)" :key="index">
<div class="header-card-label" >{{ waveLabels[item] }}</div>
<div class="header-card-val" >{{ task[item] }}</div>
</el-col>
@@ -22,13 +22,11 @@
</el-col>
</el-row>
<el-row class="detl-info-row">
- <dv-border-box-2>
- <el-card>
- <el-table :data="mergeTaskDetl" class="talbe-matnr" @row-click="selectRow">
- <el-table-column v-for="(item,index) in Object.keys(detlLabels)" :prop="item" :label="detlLabels[item]" :key="index"/>
- </el-table>
- </el-card>
- </dv-border-box-2>
+ <el-card class="detl-info-card">
+ <el-table :data="mergeTaskDetl" class="table-matnr" @row-click="selectRow">
+ <el-table-column v-for="(item,index) in Object.keys(detlLabels)" :prop="item" :label="detlLabels[item]" :key="index"/>
+ </el-table>
+ </el-card>
</el-row>
<el-row class="pick-order-detl">
<dv-border-box11 title="鎷h揣璁㈠崟鏄庣粏" class="detl-box-border">
@@ -41,16 +39,16 @@
</dv-border-box11>
</el-row>
</el-col>
- <el-col :span="9">
+ <el-col :span="11">
<el-row class="order-box-row">
<dv-border-box-11 title="璁㈠崟瀹屾垚鎯呭喌" class="order-box">
<el-table :data="orders" v-if="orders.length > 0" class="order-table">
- <el-table-column v-for="(item, dex) in Object.keys(orderStatus)" :prop="item" :label="orderStatus[item]" :key="dex">
+ <el-table-column v-for="(item, dex) in Object.keys(orderStatus)" :prop="item" :label="orderStatus[item]" :key="dex" >
<template slot-scope="scope">
<el-popover
placement="right"
- width="300"
trigger="manual"
+ class="popover-order"
v-model="visible"
v-if="item === 'action'" >
<template>
@@ -58,13 +56,13 @@
<span>閫夋嫨鐩爣鍙戣揣鍖�</span>
<el-divider/>
<el-row :gutter="15">
- <el-col v-for="(palt, index) in platforms" :key="index" class="platform" :span="7" @click.native="bindShipping(palt, scope)">
- <div>{{palt.platformNo}}</div>
+ <el-col v-for="(palt, index) in platforms" :key="index" :span="7" @click.native="bindShipping(palt, scope)">
+ <div class="platform" >{{palt.platformNo}}</div>
</el-col>
</el-row>
</div>
</template>
- <el-button slot="reference" type="text" @click.native.prevent="print(scope.$index, orders)">鎵撳嵃鏄庣粏</el-button>
+ <el-button slot="reference" type="text" @click.native.prevent="print(scope.$index, orders)" class="btnPrint">鎵撳嵃鏄庣粏</el-button>
</el-popover>
<div v-else class="ship-order-list">
{{scope.row[item]}}
@@ -191,13 +189,9 @@
}
},
created () {
- //鑾峰彇褰撳墠鎵ц浠诲姟
- this.getWaves()
- //鑾峰彇褰撳墠鎾澧欏簱浣嶄俊鎭�
- this.getSeedLoc()
- //鑾峰彇鎵�鏈夊彂璐ф殏瀛樺尯
- this.getAllPlatforms()
+ this.fetch()
},
+
computed: {
getLightStatus() {
return (item)=> {
@@ -210,6 +204,14 @@
}
},
methods: {
+ fetch() {
+ //鑾峰彇褰撳墠鎵ц浠诲姟
+ this.getWaves()
+ //鑾峰彇褰撳墠鎾澧欏簱浣嶄俊鎭�
+ this.getSeedLoc()
+ //鑾峰彇鎵�鏈夊彂璐ф殏瀛樺尯
+ this.getAllPlatforms()
+ },
printPage() {
// let element = document.querySelector('#datav');
// let el = this.$refs.datav
@@ -230,6 +232,10 @@
},
//鎷嶇伅瀹瑰櫒娴佸姩
lightClick(item) {
+ if (item.platformId == null || item.platformId == undefined || item.platformId == '') {
+ this.$message.error('璇锋墦鍗拌鍗曟槑缁嗭紝骞堕�夋嫨鐩爣闆嗚揣鍖猴紒锛�')
+ return
+ }
this.slapLight(item)
},
//璁㈠崟鍏ュ簱闆嗚揣鍖�,骞舵墦鍗板崟鎹�
@@ -244,6 +250,7 @@
// eslint-disable-next-line no-undef
$ajax.post('/api/bind/shipping/platform', {orderId: order.id, waveId: order.waveId, platformId: plat.id}).then(response => {
if (response.code === 200) {
+ that.fetch()
//闅愯棌鍙戣揣鍖�,鎵ц鎵撳嵃
} else {
this.$message.error(response.msg)
@@ -431,15 +438,7 @@
margin: 5px 0;
}
- .platform {
- display: flex;
- align-items: center;
- justify-content: center;
- height: 80px;
- background-color: #03d3ec;
- margin: 5px;
- text-align: center;
- }
+
.pick-order-detl {
padding: 0 15px;
@@ -524,22 +523,31 @@
text-align: center;
padding: 15px;
- .header-card-label {
- font-size: 25px;
- font-style: oblique;
- padding: 5px;
- color: white;
- }
- .header-card-val {
- font-size: 20px;
- padding: 10px;
- color: orange;
+ .heaer-label-column {
+ min-width: 170px;
+ width: auto;
+ .header-card-label {
+ font-size: 25px;
+ font-style: oblique;
+ padding: 5px;
+ color: white;
+ }
+ .header-card-val {
+ font-size: 20px;
+ padding: 10px;
+ color: orange;
+ }
}
}
}
.detl-info-row {
padding: 0 15px;
+
+ .detl-info-card {
+
+ }
+
}
.order-box-row {
@@ -553,6 +561,23 @@
width: 74vh;
padding-top: 65px;
height: 275px;
+
+ .popover-order {
+ width: 300px;
+
+ .platform {
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ height: 80px;
+ background-color: #03d3ec;
+ margin: 5px;
+ text-align: center;
+ }
+ }
+
+
+
.ship-order-list {
font-size: 18px; color: white;
@@ -620,7 +645,7 @@
top: 0px !important;
}
- .talbe-matnr {
+ .table-matnr {
height: 26vh;
}
@@ -667,23 +692,58 @@
@media screen and (max-width: 1281px) {
#data-view {
.header-left-task {
- .header-card {
- margin: 5px;height: 90px;
- padding: 5px;
+ padding: 5px 15px 5px 15px;
- .header-card-label {
- font-size: 18px;
- padding: 5px;
+ .header-card {
+ margin: 2px;
+ height: 70px;
+ padding: 2px;
+
+ .el-card__body {
+ padding: 5px 20px;
}
- .header-card-val {
- font-size: 14px;
+ .heaer-label-column{
+ max-width: 130px;
+ min-width: 75px;
+ width: auto;
+ .header-card-label {
+ font-size: 13px;
+ padding: 5px;
+ }
+
+ .header-card-val {
+ font-size: 11px;
+ }
+ }
+ }
+ }
+
+ .detl-info-row {
+ padding: 0 15px;
+
+ .detl-info-card {
+ padding: 0;
+ .el-card__body {
+ padding: 8px;
+ }
+ }
+
+ .el-table {
+ th.el-table__cell>.cell {
+ text-align: center;
+ }
+
+ .el-table__cell {
+ padding: 5px 0;
+ text-align: center;
+ width: auto;
}
}
}
.order-box-row {
- width: 58vh;
+ width: 68vh;
height: 28vh;
.order-box {
@@ -694,37 +754,47 @@
padding-top: 65px;
height: 275px;
+ .btnPrint {
+ font-size: 9px;
+ }
+
.ship-order-list {
- font-size: 14px;
+ font-size: 10px;
+ }
+
+ .el-table__cell {
+ padding: 0;
}
}
}
.empty-padding {
padding-top: 65px;
+ width: 30px;
+ height: 30px;
}
}
- .talbe-matnr {
- height: 20vh;
+ .table-matnr {
+ height: 15vh;
}
.el-table .cell {
- font-size: 16px !important;
+ font-size: 10px !important;
}
.pick-order-detl {
padding: 0 10px;
.detl-box-border {
- height: 39vh;
+ height: 49vh;
.detl-box-padding {
height: 65px
}
.order-detl-list {
- height: 23vh;
+ height: 38vh;
}
}
}
--
Gitblit v1.9.1