From cbcf2f774d7bd505502cf05a09eb38ee553f7c34 Mon Sep 17 00:00:00 2001
From: loulijun2021 <1694218219@qq.com>
Date: 星期六, 06 五月 2023 07:59:14 +0800
Subject: [PATCH] 1.看板调整2.上云路由整合
---
src/views/kb/zhkb.vue | 162 ++++++++++++++++++++++++++++++++++++++++++++++++++++-
1 files changed, 157 insertions(+), 5 deletions(-)
diff --git a/src/views/kb/zhkb.vue b/src/views/kb/zhkb.vue
index 2bdb36a..eda59bb 100644
--- a/src/views/kb/zhkb.vue
+++ b/src/views/kb/zhkb.vue
@@ -24,11 +24,30 @@
<!-- <svg-icon icon-class="sccx" />-->
浜х嚎鍔犲伐涓换鍔�
<div style="margin-left: 30px">{{ number1 }} 鍗�</div>
+ <div style="display: flex;margin-left: 25px;">
+
+ <div class="circle" style="background-color: rgb(255 255 255)" />
+ <div style="margin-left: 10px">鏈紑濮�</div>
+
+ <div class="circle" style="margin-left: 10px;background-color: blue;" />
+ <div style="margin-left: 10px">寮�宸�</div>
+
+ <div class="circleYellow" style="margin-left: 10px" />
+ <div style="margin-left: 10px">鎵ц涓�</div>
+
+ <div class="circle" style="margin-left: 10px" />
+ <div style="margin-left: 10px">瀹屽伐</div>
+
+ </div>
</div>
<div class="kb_left_top kb_pd10">
<div class="kb_left_top02">
- <div v-for="item in lineContent3" :key="item.workcode" class="kb_left_top_block">
+ <div
+ v-for="item in lineContent3"
+ :key="item.workcode+JSON.stringify(item.children[0])"
+ class="kb_left_top_block"
+ >
<div class="kb_block02 kb_pd10">
<div>
<div>閿�鍞崟鍙�:{{ item.saleordercode }}</div>
@@ -137,7 +156,8 @@
width="115"
>
<template slot-scope="{row}">
- <div>{{ row.lm_date.substring(0, 10) }}</div>
+ <div v-if="row.lm_date">{{ row.lm_date.substring(0, 10) }}</div>
+ <div v-else>/</div>
</template>
</el-table-column>
<el-table-column
@@ -215,7 +235,8 @@
width="115"
>
<template slot-scope="{row}">
- <div>{{ row.planstartdate.substring(0, 10) }}</div>
+ <div v-if="row.planstartdate">{{ row.planstartdate.substring(0, 10) }}</div>
+ <div v-else>/</div>
</template>
</el-table-column>
<el-table-column
@@ -224,7 +245,8 @@
width="125"
>
<template slot-scope="{row}">
- <div>{{ row.planenddate.substring(0, 10) }}</div>
+ <div v-if="row.planenddate">{{ row.planenddate.substring(0, 10) }}</div>
+ <div v-else>/</div>
</template>
</el-table-column>
</el-table>
@@ -458,6 +480,125 @@
getShopSearchLine() {
let length, count
LineSearchTopLeftData({ shopcode: this.ShopArr.join(',') }).then(res => {
+ this.lineContent = res.data // 璋冪敤鎺ュ彛杩斿洖鐨勬暟鎹�
+ this.number1 = this.lineContent.length // 浜х嚎鍔犲伐涓换鍔� 鍗曟暟
+
+ const newData = []
+ if (this.lineContent.length > 0) {
+ this.lineContent.forEach(item => {
+ if (item.children.length > 5) {
+ newData.push({
+ workcode: item.workcode,
+ partname: item.partname,
+ partnumber: item.partnumber,
+ partspec: item.partspec,
+ qty: item.qty,
+ saleordercode: item.saleordercode,
+ uom: item.uom,
+ children: item.children.slice(0, 5)
+ })
+
+ newData.push({
+ workcode: item.workcode,
+ partname: item.partname,
+ partnumber: item.partnumber,
+ partspec: item.partspec,
+ qty: item.qty,
+ saleordercode: item.saleordercode,
+ uom: item.uom,
+ children: item.children.slice(5, 8)
+ })
+ } else {
+ newData.push({
+ workcode: item.workcode,
+ partname: item.partname,
+ partnumber: item.partnumber,
+ partspec: item.partspec,
+ qty: item.qty,
+ saleordercode: item.saleordercode,
+ uom: item.uom,
+ children: item.children
+ })
+ }
+ })
+
+ console.log(newData.length, 9777)
+ }
+
+ this.lineContent = newData
+ length = this.lineContent.length
+ count = Math.ceil(length / 3) // 闇�瑕佽疆鎾殑缁勬暟 3涓负涓�缁�
+ this.lineContent3 = this.lineContent.slice(0, 3)
+ })
+
+ let start = 0
+ this.ShopSearchLineTask = setInterval(() => {
+ if (Math.floor(start / 3) === count && count !== 0) {
+ start = 0
+ LineSearchTopLeftData({ shopcode: this.ShopArr.join(',') }).then(res => {
+ this.lineContent = res.data // 璋冪敤鎺ュ彛杩斿洖鐨勬暟鎹�
+ this.number1 = this.lineContent.length // 浜х嚎鍔犲伐涓换鍔� 鍗曟暟
+
+ const newData = []
+ if (this.lineContent.length > 0) {
+ this.lineContent.forEach(item => {
+ if (item.children.length > 5) {
+ newData.push({
+ workcode: item.workcode,
+ partname: item.partname,
+ partnumber: item.partnumber,
+ partspec: item.partspec,
+ qty: item.qty,
+ saleordercode: item.saleordercode,
+ uom: item.uom,
+ children: item.children.slice(0, 5)
+ }
+ )
+
+ newData.push({
+ workcode: item.workcode,
+ partname: item.partname,
+ partnumber: item.partnumber,
+ partspec: item.partspec,
+ qty: item.qty,
+ saleordercode: item.saleordercode,
+ uom: item.uom,
+ children: item.children.slice(5, 8)
+ })
+ } else {
+ newData.push({
+ workcode: item.workcode,
+ partname: item.partname,
+ partnumber: item.partnumber,
+ partspec: item.partspec,
+ qty: item.qty,
+ saleordercode: item.saleordercode,
+ uom: item.uom,
+ children: item.children
+ })
+ }
+ })
+ }
+
+ this.lineContent = newData
+ length = this.lineContent.length
+ count = Math.ceil(length / 3) // 闇�瑕佽疆鎾殑缁勬暟 3涓负涓�缁�
+ this.lineContent3 = this.lineContent.slice(0, 3)
+ })
+ } else if (count === 0) {
+ clearInterval(this.ShopSearchLineTask)
+ this.getShopSearchLine()
+ }
+
+ this.lineContent3 = this.lineContent.slice(start, start + 3)
+ start = start + 3
+ }, 1000 * 3)
+ },
+
+ // 浜х嚎鍔犲伐涓换鍔� 澶囦唤鏂规硶
+ getShopSearchLine2() {
+ let length, count
+ LineSearchTopLeftData({ shopcode: this.ShopArr.join(',') }).then(res => {
this.lineContent = res.data
length = this.lineContent.length
count = Math.ceil(length / 3) // 闇�瑕佽疆鎾殑缁勬暟 3涓负涓�缁�
@@ -512,7 +653,7 @@
}
})
}
- }, this.tableData.length <= 10 ? 1000 * 3 : 100)
+ }, this.tableData.length <= 10 ? 1000 * 15 : 100)
})
},
// 褰撴棩瀹屽伐浜у搧鏁伴噺鎺掕
@@ -840,4 +981,15 @@
background-color: rgb(255 255 0);
border-radius: 50%;
}
+
+::v-deep .el-table__body-wrapper{
+ overflow: hidden !important;
+}
+
+.circle {
+ width: 26px;
+ height: 26px;
+ background-color: #00ff8b;
+ border-radius: 50%;
+}
</style>
--
Gitblit v1.9.3