From f46eb243908e145da448f65bffb8ba17197d9164 Mon Sep 17 00:00:00 2001
From: qingyiay <2386314947@qq.com>
Date: 星期一, 25 九月 2023 16:10:12 +0800
Subject: [PATCH] 增加详情原发信息 增加装卸员下拉刷新 修改诸多问题 优化websocket
---
pages/loadUnload-page/loadUnload-detail/loadUnload-detail.vue | 102 ++++++++++++++++++++++++++++++++++++---------------
1 files changed, 72 insertions(+), 30 deletions(-)
diff --git a/pages/loadUnload-page/loadUnload-detail/loadUnload-detail.vue b/pages/loadUnload-page/loadUnload-detail/loadUnload-detail.vue
index 94ff0cf..7ccbef4 100644
--- a/pages/loadUnload-page/loadUnload-detail/loadUnload-detail.vue
+++ b/pages/loadUnload-page/loadUnload-detail/loadUnload-detail.vue
@@ -27,34 +27,33 @@
</view>
<view class="num">{{ item.hair }}</view>
</view>
- <view class="item">
- <view class="concrete"
- :style="{ backgroundImage: `url(${onlineurl}/appimg/image/banner/clean.png)`, backgroundSize: 'cover', backgroundRepeat: 'no-repeat' }">
- 鍑�
+ </view>
+ <view class="info-container">
+ <view class="info-block">
+ <view class="car-num info">
+ <text class="label-text">杞︾墝鍙�:</text>{{item.carNo}}
</view>
- <view class="num">{{ item.clean }}</view>
+ <view class="order-margin info">
+ <text class="label-text">鐓ょ鍚嶇О:</text>
+ {{item.coalName}}
+ </view>
+ <view class="order-type info">
+ 璁㈠崟绫诲瀷:{{item.orderType}}
+ </view>
+ <view class="file-name info">
+ 鐘舵��:{{coalStatus[item.status]}}
+ </view>
</view>
</view>
- <view class="order-type info">
- 璁㈠崟绫诲瀷:{{item.orderType}}
- </view>
- <view class="car-num info">
- 杞︾墝鍙�:{{item.carNo}}
- </view>
- <view class="file-name info">
- 鐓ゅ満鍚嶇О:{{item.filedName}}
- </view>
- <view class="order-margin info">
- 鐓ょ鍚嶇О:{{item.coalName}}
- </view>
- <view class="confirm-button info">
+ <view class="confirm-button">
<u-button plain
type="primary"
text="纭畾瑁呭嵏"
shape="circle"
@click.stop="loadOrder(item.id)"
:loading="loading"
- loadingText="纭"></u-button>
+ loadingText="纭"
+ v-if='!item.ableDischar'></u-button>
</view>
</view>
</view>
@@ -76,7 +75,10 @@
onlineurl,
loadShow: false, // 纭寮圭獥鎺у埗
loading: false,
- id: ""
+ id: "",
+ coalStatus: ['棰嗗彇', '棰勭害', '绛惧埌', '鍏ュ満', '绉扮毊', '绉版瘺', '绂诲満', '鍏ョ鎴�', '鍑虹鎴�', '鍏ョ叅浠�', '鍑虹叅浠�', '鏀剧┖', '浣滃簾', '鍏ュ満鐢宠',
+ '杩涘叆鍦洪櫌', '寮傚父瀹℃牳涓�',
+ ], // 鐘舵��
}
},
onLoad(params) {
@@ -84,6 +86,10 @@
this.init()
},
methods: {
+ onPullDownRefresh() {
+ this.init()
+ uni.stopPullDownRefresh();
+ },
init() {
uni.showLoading({
title: "鍔犺浇涓�"
@@ -91,7 +97,14 @@
this.$reqGet('getAccordingCoalNameAll', { coalName: this.name }).then(res => {
uni.hideLoading()
if (res.code === 0) {
- this.detailData = res.data
+ const errorStatusArr = [0, 1, 2, 3, 6, 11, 12, 13];
+ this.detailData = res.data.map(v => {
+ return {
+ ...v,
+ ableDischar: v.skin === v.hair || v.hair === 0 && v.skin === 0 || v
+ .isPretendDischar !== 0 || errorStatusArr.indexOf(v.status) !== -1
+ }
+ })
} else {
this.$u.toast('鍔犺浇澶辫触')
}
@@ -130,7 +143,7 @@
.collection-form-item {
width: 690rpx;
- height: 400rpx;
+ height: 380rpx;
background: #ffffff;
box-shadow: 4rpx 6rpx 25rpx 0rpx rgba(73, 120, 240, 0.15);
border-radius: 20rpx;
@@ -142,11 +155,13 @@
margin-top: vww(10);
.weigh-item {
- width: 100%;
+ width: 94%;
height: vww(36);
- margin: vww(10);
+ margin: 0 vww(10);
@include flex;
justify-content: space-around;
+ position: relative;
+ top: vww(-14);
.item {
min-width: vww(50);
@@ -171,17 +186,44 @@
}
}
- .info {
- height: vww(20);
- color: #515151;
- margin: vww(5);
- margin-left: vww(20);
+ .info-container {
+ width: 100%;
+ height: vww(100);
+ display: flex;
+ justify-content: center;
+
+ .info-block {
+ width: 600rpx;
+ height: vww(80);
+ display: flex;
+ justify-content: center;
+ flex-wrap: wrap;
+
+ .car-num,
+ .order-margin {
+ color: #FF0000;
+ font-weight: 600;
+
+ .label-text {
+ color: #409eff;
+ }
+ }
+
+ }
+
+ .info {
+ width: 45%;
+ height: vww(20);
+ color: #515151;
+ margin: vww(5);
+ }
}
+
.confirm-button {
width: vww(80);
position: absolute;
- bottom: vww(20);
+ bottom: vww(6);
right: vww(10);
}
}
--
Gitblit v1.9.1