From 0e555ff7887e46c5bdd9d8ca237f7ed1e1634c0f Mon Sep 17 00:00:00 2001
From: MrShi <1878285526@qq.com>
Date: 星期三, 24 九月 2025 13:53:55 +0800
Subject: [PATCH] 优化
---
h5/pages/waybill/list.vue | 76 +++++++++++++++++++++++++++++---------
1 files changed, 58 insertions(+), 18 deletions(-)
diff --git a/h5/pages/waybill/list.vue b/h5/pages/waybill/list.vue
index 70dd191..26406b0 100644
--- a/h5/pages/waybill/list.vue
+++ b/h5/pages/waybill/list.vue
@@ -1,5 +1,9 @@
<template>
- <view class="main_app">
+ <view class="main_app">
+ <view class="title_wrap">
+ <view class="name">{{ waybillInfo.realname || waybillInfo.username || waybillInfo.mobile }}锛屾杩庣櫥褰曪綖</view>
+ <view class="btn" @click="loginOut">璐﹀彿瑙g粦</view>
+ </view>
<view class="head_wrap" @click="openModal">
<view class="search_box">
<image src="@/static/ic_search@2x.png" class="search" mode=""></image>
@@ -15,9 +19,10 @@
<scroll-view scroll-y="true" class="scroll_Y" @scrolltolower="scrolltolower">
<view class="main_list">
<view class="item" v-for="item,index in list" :key="index">
- <view class="head">
+ <view class="head"
+ :style="{ backgroundColor: item.orderStatus === 9 ? 'linear-gradient(270deg, #FEFEFF 0%, #FEE1E1 100%)' : 'linear-gradient(270deg, #FEFEFF 0%, #E1F7FE 100%)' }">
<view class="code">{{item.contractNumber}}</view>
- <view class="status">{{item.orderStatusDesc }}</view>
+ <view :class="item.orderStatus === 9 ? 'error' : 'status'">{{item.orderStatusDesc }}</view>
</view>
<view class="content">
<view class="line">
@@ -109,7 +114,8 @@
<script>
import {
- orderListTms
+ orderListTms,
+ logoutPost
} from '@/api'
import dayjs from 'dayjs';
export default {
@@ -119,7 +125,8 @@
list: [],
page: 1,
total: 0,
-
+
+ waybillInfo: uni.getStorageSync('waybillInfo'),
showModal: false,
showStarttime: false,
showEndtime: false,
@@ -137,14 +144,11 @@
};
},
onLoad(options) {
- this.$set(this.param, 'phoneNumber', options.phone)
this.getList()
},
methods: {
clear() {
- this.param = {
- phoneNumber: this.param.phoneNumber
- }
+ this.param = {}
this.form = {}
this.page = 1
this.list = []
@@ -154,6 +158,17 @@
diaodu() {
uni.navigateTo({
url: '/pages/staff/signin'
+ })
+ },
+ loginOut() {
+ let app_url = 'https://atwl.ahzyssl.com/zhyq_h5/#/pages/waybill/home'
+ logoutPost({
+ isH5: 1
+ }).then(res => {
+ this.$store.commit('empty')
+ setTimeout(() => {
+ window.location.href = app_url
+ }, 300)
})
},
modalSub() {
@@ -212,18 +227,13 @@
form,
page
} = this
- // if (form.contract) {
- // form.contractNumber = form.contract
- // } else {
- // form.contractNumber = null
- // }
orderListTms({
parameters: {
...param,
...form
},
pager: {
- rows: 10,
+ rows: 16,
page
}
}).then(res => {
@@ -240,6 +250,33 @@
<style lang="scss">
page {
background: #F7F7F7;
+ }
+ .title_wrap {
+ display: flex;
+ justify-content: space-between;
+ // align-items: center;
+ background-color: #fff;
+ width: 750rpx;
+ height: 90rpx;
+ margin: -10rpx -30rpx 0;
+ padding: 24rpx 30rpx 0;
+ .name {
+ font-weight: 600;
+ font-size: 34rpx;
+ color: #222222;
+ }
+
+ .btn {
+ width: 144rpx;
+ height: 56rpx;
+ border-radius: 36rpx;
+ border: 1rpx solid #B2B2B2;
+ font-size: 26rpx;
+ color: #666666;
+ display: flex;
+ justify-content: center;
+ align-items: center;
+ }
}
.head_title{
color: $uni-color-primary;
@@ -290,9 +327,8 @@
.scroll_Y {
background-color: #f7f7f7;
- height: calc(100vh - 180rpx);
+ height: calc(100vh - 250rpx);
margin-top: 10rpx;
-
.main_list {
width: 750rpx;
margin: 0 -30rpx;
@@ -312,7 +348,7 @@
width: 690rpx;
height: 84rpx;
margin: 0 -30rpx;
- background: linear-gradient(270deg, #FEFEFF 0%, #E1F7FE 100%);
+ // background: linear-gradient(270deg, #FEFEFF 0%, #E1F7FE 100%);
.code {
font-weight: 500;
@@ -323,6 +359,10 @@
.status {
color: $uni-color-primary;
}
+
+ .error {
+ color: #EE3821;
+ }
}
.content {
--
Gitblit v1.9.3