From 9d901b4215323c97a00a068cd962f5c9c04dadfa Mon Sep 17 00:00:00 2001
From: doum <doum>
Date: 星期四, 04 九月 2025 10:15:09 +0800
Subject: [PATCH] 前端
---
small-program/pages/order-details/order-details.vue | 575 +++++++++++++++++++++++++++++++++++++++++++++++++++++----
1 files changed, 531 insertions(+), 44 deletions(-)
diff --git a/small-program/pages/order-details/order-details.vue b/small-program/pages/order-details/order-details.vue
index ee98882..eadd734 100644
--- a/small-program/pages/order-details/order-details.vue
+++ b/small-program/pages/order-details/order-details.vue
@@ -4,15 +4,20 @@
宸插彇娑�
</view> -->
<view class="order-head" :style="{ backgroundImage: 'url(' + bgImg + ')' }">
- <view class="order-head-status">{{info.statusName || ''}}</view>
- <view class="order-head-info">{{getStatusInfo()}}</view>
+ <view class="order-head-status">{{info.statusName || ''}}</view>
+ <view class="order-head-info" v-if="isAcceptor && info.isUpdate ==1" style="color: red;">
+ 璁㈠崟淇℃伅宸蹭慨鏀癸紝璇峰強鏃剁‘璁わ紝{{timeInfo}}鍚庡皢鑷姩鍚屾剰
+ </view>
+ <view class="order-head-info" v-if="isPushlishor && info.type ==2 && info.status ==0" style="color: red;">
+ 鍓╀綑鏀粯鏃堕棿锛寋{timeInfo1}}鍚庡皢鑷姩鍙栨秷
+ </view>
+ <view class="order-head-info" v-else >{{getStatusInfo()}}</view>
</view>
<view class="order-quxiao">
- <view class="order-quxiao-btn" @click="show = true" v-if="userInfo.id === info.acceptMemberId && info.status ===2">鍙栨秷璁㈠崟</view>
- <view class="order-quxiao-btn" @click="show = true" v-if="userInfo.id === info.releaseMemberId && (info.status ===0 || info.status ===1|| info.status ===2)">鍙栨秷璁㈠崟</view>
- <view class="order-quxiao-btn1" v-if="userInfo.id === info.releaseMemberId && (info.status ===0 || info.status ===1|| info.status ===2)" @click="jumpEdit()">淇敼璁㈠崟</view>
+ <view class="order-quxiao-btn" @click="show = true" v-if="(isAcceptor && info.status ===2) || (isPushlishor && info.isUpdate!=1 && info.status ===2)">鍙栨秷璁㈠崟</view>
+ <view class="order-quxiao-btn1" v-if="isPushlishor && info.type!=2 && info.isUpdate!=1 && info.status ===2 " @click="jumpEdit()">淇敼璁㈠崟</view>
</view>
- <view class="order-user" v-if="userInfo.id === info.releaseMemberId">
+ <view class="order-user" v-if="isPushlishor && info.acceptMemberId">
<view class="order-user-info">
<view class="user-info-l">
<view class="user-info-l-image">
@@ -21,7 +26,7 @@
</view>
<view class="user-info-l-i">
<view class="user-info-l-i-top">
- <text>{{info.acceptName || '鍖垮悕'}}</text>
+ <text>{{info.acceptName || ''}}</text>
<view class="user-info-l-i-top-jdf">鎺ュ崟鏂�</view>
</view>
<view class="user-info-l-i-bottom">
@@ -31,12 +36,12 @@
</view>
<view class="user-info-l-i-bottom-item">
<text>鍗曟暟锛�</text>
- <text>{{info.publishNum || 0}}</text>
+ <text>{{info.receiveNum ? info.receiveNum : 0}}</text>
</view>
</view>
</view>
</view>
- <view class="user-info-r" @click="contactPhone(info.acceptPhone)">
+ <view class="user-info-r" @click="contactPhone(info.acceptPhone)" v-if="info.status ==2||info.status==3||info.status==5">
<image src="/static/icon/ic_call@2x.png" mode="widthFix"></image>
<text>鑱旂郴甯堝倕</text>
</view>
@@ -46,12 +51,12 @@
<view class="order-info-title">
<view class="x"></view>
<text v-if="info.type===0">鐢ㄥ伐鍗�-{{(info.workType===0?'閲囨憳宸�':(info.workType===1?'鍒嗘嫞宸�':'鍖呰宸�')) }}</text>
- <text v-if="info.type===1">杩愯揣鍗�-{{info.categoryName || ''}}-{{info.carUnit || ''}}</text>
+ <text v-if="info.type===1">杩愯揣鍗�-{{info.categoryName || ''}}</text>
<text v-if="info.type===2">璁㈤鍗�</text>
</view>
- <view v-if="info.type===0" class="order-info-wz">{{info.categoryName || ''}}锝渰{info.priceNum1 || '' }}鏂�</view>
- <view v-if="info.type===1" class="order-info-wz">{{info.transportTypeName || ''}}{{' | '}}{{info.transportNum || '' }}{{info.transportUnit||''}}{{' | '}}闇�{{info.priceNum2 || '' }}杈�</view>
+ <view v-if="info.type===0" class="order-info-wz">{{info.categoryName || ''}}锝渰{info.priceNum1 || '' }}{{info.workType === 0?'鏂�':'浜�'}}</view>
+ <view v-if="info.type===1" class="order-info-wz">{{info.carUnit || ''}}{{' | '}}{{info.transportTypeName || ''}}{{' | '}}{{info.transportNum || '' }}{{info.transportUnit||''}}{{' | '}}闇�{{info.priceNum2 || '' }}杈�</view>
<view class="order-info-address">
<image src="/static/icon/order_ic_location@2x.png" mode="widthFix"></image>
<view class="order-info-address-info">
@@ -87,6 +92,14 @@
</view>
</view>
<view class="order-info-price">
+ <view class="price-row" v-if="feeFrom.priceParam1.name">
+ <view class="price-row-label">{{feeFrom.priceParam1.name}}</view>
+ <view class="price-row-val" > {{(info.originPriceNum1||0) }}{{feeFrom.priceParam1.unit}} </view>
+ </view>
+ <view class="price-row" v-if="feeFrom.priceParam2.name">
+ <view class="price-row-label">{{feeFrom.priceParam2.name}}</view>
+ <view class="price-row-val" > {{(info.originPriceNum2||0) }}{{feeFrom.priceParam2.unit}} </view>
+ </view>
<view class="price-row">
<view class="price-row-label">璐圭敤鏍囧噯</view>
<view class="price-row-val" v-if="info.type !==2">{{((info.price||0)/100).toFixed(2) }}{{info.priceUnit || '' }}</view>
@@ -98,32 +111,87 @@
</view>
<view class="price-row">
<view class="price-row-label">棰勪及鎬昏垂鐢�(鍏�)</view>
+ <view class="price-row-val" :style="{color: userInfo.id !== info.acceptMemberId ? '#FF0000' : ''}">
+ 楼{{((info.originEstimatedAccount||0)/100).toFixed(2) }}
+ </view>
+ </view>
+ <view class="price-row" v-if="isAcceptor&&(info.type==2 || (info.status!=5&& info.status!=4))">
+ <view class="price-row-label">瀹為檯鍒拌处(鍏�)</view>
<view class="price-row-val" style="color: #FF0000;">
- 楼{{((info.estimatedAccount||0)/100).toFixed(2) }}
+ 楼{{((info.receiveAccount || 0) / 100).toFixed(2) }}
</view>
</view>
</view>
+ <template v-if="info.type!=2&&(info.status==5|| info.status==4)">
+ <view class="order-info-x"></view>
+ <view class="order-info-supplement" >
+ <view class="order-info-supplement-title">宸茬‘璁よ垂鐢�</view>
+ </view>
+ <view class="order-info-price">
+ <view class="price-row" v-if="feeFrom.priceParam1.name">
+ <view class="price-row-label">瀹為檯{{feeFrom.priceParam1.name}}</view>
+ <view class="price-row-val" > {{(info.priceNum1||0) }}{{feeFrom.priceParam1.unit}} </view>
+ </view>
+ <view class="price-row" v-if="feeFrom.priceParam2.name">
+ <view class="price-row-label">瀹為檯{{feeFrom.priceParam2.name}}</view>
+ <view class="price-row-val" > {{(info.priceNum2||0) }}{{feeFrom.priceParam2.unit}} </view>
+ </view>
+ <view class="price-row" >
+ <view class="price-row-label">鍏朵粬璐圭敤</view>
+ <view class="price-row-val" >楼{{((info.confirmOtherFee||0)/100).toFixed(2) }} </view>
+ </view>
+ <view class="price-row">
+ <view class="price-row-label">瀹為檯鎬昏垂鐢�(鍏�)</view>
+ <view class="price-row-val" style="color: #FF0000">
+ 楼{{((info.estimatedAccount||0)/100).toFixed(2) }}
+ </view>
+ </view>
+ <view class="price-row" >
+ <view class="price-row-label">澶囨敞</view>
+ <view class="price-row-val" >
+ {{ info.confirmFeeRemark ||'' }}
+ </view>
+ </view>
+ </view>
+ </template>
+ <template v-if="info.type==2 || info.status==4">
+ <view class="order-info-x"></view>
+ <view class="order-info-supplement" >
+ <view class="order-info-supplement-title">瀹為檯璐圭敤</view>
+ </view>
+ <view class="order-info-price">
+ <view class="price-row">
+ <view class="price-row-label" v-if="isPushlishor">瀹為檯鏀粯</view>
+ <view class="price-row-val" style="color: #FF0000;">楼{{((info.payAccount||0)/100).toFixed(2) }} </view>
+ </view>
+ <view class="price-row" v-if="isAcceptor && info.status==4" >
+ <view class="price-row-label">瀹為檯鍒拌处</view>
+ <view class="price-row-val" style="color: #FF0000;">楼{{((info.receiveAccount||0)/100).toFixed(2) }} </view>
+ </view>
+
+ </view>
+ </template>
</view>
<view class="order-info" v-if="info.commentStatus ===1">
<view class="order-info-title">
<text>璇勪环</text>
</view>
- <u-rate :count="count" activeColor="#FFC331" size="26" v-model="info.commentLevel"></u-rate>
+ <u-rate :count="count" readonly activeColor="#FFC331" size="26" v-model="info.commentLevel"></u-rate>
<view class="order-info-remark">
{{ info.commentInfo || '-'}}
</view>
</view>
- <view class="order-ren" v-if="userInfo.id === info.acceptMemberId">
+ <view class="order-ren" v-if="isAcceptor">
<view class="order-ren-left">
<view class="order-ren-left-img">
<image v-if="info.releaseCoverImage" :src="info.releaseCoverImage" mode="widthFix"></image>
<image v-else src="/static/icon/img@2x.png" mode="widthFix"></image>
</view>
- <text>{{info.releaseName || '鍖垮悕'}}</text>
+ <text>{{info.releaseName || ''}}</text>
<view class="order-ren-left-tip">涓氫富</view>
</view>
<view class="order-ren-x"></view>
- <view class="order-ren-lx" @click="contactPhone(info.releasePhone)">
+ <view class="order-ren-lx" v-if="info.status ==2||info.status==3||info.status==5" @click="contactPhone(info.releasePhone)">
<image src="/static/icon/ic_call@2x.png" mode="widthFix"></image>
<text>鍙戝崟鏂�</text>
</view>
@@ -149,6 +217,10 @@
<text>寮�濮嬫椂闂达細</text>
<text>{{info.workStartTime||'-'}}</text>
</view>
+ <view class="order-info-list-item" v-if="info.confirmFeeTime">
+ <text>璐圭敤纭鏃堕棿锛�</text>
+ <text>{{info.confirmFeeTime||'-'}}</text>
+ </view>
<view class="order-info-list-item" v-if="info.finishTime">
<text>瀹屾垚鏃堕棿锛�</text>
<text>{{info.finishTime||'-'}}</text>
@@ -169,22 +241,23 @@
</view>
<view style="width: 100%; height: calc(108rpx + env(safe-area-inset-bottom));" v-if="![99].includes(info.status)"></view>
<view class="order-footer" v-if="![99].includes(info.status)">
- <template v-if="(userInfo.id === info.releaseMemberId) && info.status ===2">
+ <template v-if="isPushlishor && info.isUpdate!=1 &&info.status ===2">
<sunui-mverify hint="寮�濮嬩綔涓�" @change="getaccept($event)"></sunui-mverify>
</template>
<view class="order-footer-btn" v-else>
- <view class="order-footer-btn-a" @click="show = true" v-if="userInfo.id === info.acceptMemberId && info.status ===2">鍙栨秷璁㈠崟</view>
- <view class="order-footer-btn-a" @click="show = true" v-if="userInfo.id === info.releaseMemberId && (info.status ===0 || info.status ===1|| info.status ===2)">鍙栨秷璁㈠崟</view>
- <view class="order-footer-btn-b" @click="show2=true" v-if="userInfo.id === info.releaseMemberId && (info.status ===4 && info.commentStatus!=1)">鍘昏瘎浠�</view>
- <view class="order-footer-btn-b" v-if="userInfo.id === info.releaseMemberId &&((info.status ===3 && info.type !==2)|| (info.status ===0 && info.type===2))" @click="show1 = true">瀹屾垚骞舵敮浠�</view>
- <view class="order-footer-btn-b" v-if="userInfo.id === info.releaseMemberId && (info.status ===0 || info.status ===1|| info.status ===2)" @click="jumpEdit()">淇敼璁㈠崟</view>
- <view class="order-footer-btn-b" @click="show5 =true" v-if="userInfo.id === info.acceptMemberId && (info.isUpdate==1 && info.status ===2)">淇敼纭</view>
- <view class="order-footer-btn-b" @click="startJobs()" v-if="userInfo.id === info.releaseMemberId && (info.status ===2)">寮�濮嬩綔涓�</view>
- <view class="order-footer-btn-b" @click="show6 =true" v-if="userInfo.id !== info.releaseMemberId && (info.status ===1)">鎶㈠崟</view>
+ <view class="order-footer-btn-a" @click="show = true" v-if="1==2&& isAcceptor && info.status ===2">鍙栨秷璁㈠崟</view>
+ <view class="order-footer-btn-a" @click="show = true" v-if="isPushlishor && (info.status ===0 || info.status ===1|| info.status ===2)">鍙栨秷璁㈠崟</view>
+ <view class="order-footer-btn-b" @click="show2=true" v-if="isPushlishor && (info.status ===4 && info.commentStatus!=1)">鍘昏瘎浠�</view>
+ <view class="order-footer-btn-b" v-if="isPushlishor&&((info.status ===5 && info.type !==2)|| (info.status ===0 && info.type===2))" @click="show1 = true">{{info.type === 2 ? '缁х画鏀粯' : '绔嬪嵆鏀粯'}}</view>
+ <view class="order-footer-btn-b" @click="show7 = true" v-if=" info.type!==2 &&isAcceptor && info.status ===3">纭璐圭敤</view>
+ <view class="order-footer-btn-b" v-if="isPushlishor && ((info.status ===3 && info.type===2))" @click="payment1">瀹屾垚浣滀笟</view>
+ <view class="order-footer-btn-b" v-if="info.type !=2 && info.isUpdate!=1&& isPushlishor && (info.status ===0 || info.status ===1|| info.status ===2)" @click="jumpEdit()">淇敼璁㈠崟</view>
+ <view class="order-footer-btn-b" @click="show5 =true" v-if="isAcceptor&& (info.isUpdate==1 && info.status ===2)">淇敼纭</view>
+ <!-- <view class="order-footer-btn-b" @click="startJobs()" v-if="userInfo.id === info.releaseMemberId && (info.status ===2)">寮�濮嬩綔涓�</view> -->
+ <view class="order-footer-btn-b" @click="show6 =true" v-if="!isPushlishor && (info.status ===1)">鎶㈠崟</view>
</view>
<view style="width: 100%; height: env(safe-area-inset-bottom);"></view>
</view>
-
<u-modal
title="娓╅Θ鎻愮ず"
:show="show"
@@ -258,14 +331,68 @@
</view>
<view class="zhifu-c-info1">鏀粯閲戦锛�</view>
<view class="zhifu-c-input">
- <image src="/static/icon/楼@2x.png" mode="widthFix"></image>
+ <image src="/static/icon/ic_money@2x.png" mode="widthFix"></image>
<input type="number" v-model="amount" :disabled="info.type === 2" placeholder="璇疯緭鍏�" />
</view>
</view>
<view class="zhifu-botton" @click="payment">纭鏀粯</view>
</view>
</u-popup>
-
+ <!-- 鏀粯寮圭獥 -->
+ <u-popup :show="show7" round="15" mode="bottom">
+ <view class="querenfee">
+ <view class="querenfee-head">
+ <view></view>
+ <text>璐圭敤纭</text>
+ <image @click="show7 = false" src="/static/icon/ic_close@2x.png" mode="widthFix"></image>
+ </view>
+ <view class="querenfee-c">
+ <view class="querenfee-c-info1">璐圭敤鏍囧噯锛�</view>
+ <viem class="money">{{((info.price||0)/100).toFixed(2) }}{{info.priceUnit || '' }}</viem>
+ </view>
+ <view class="querenfee-c" >
+ <view class="querenfee-c-info1"><text style="color: red;">*</text>瀹為檯{{feeFrom.priceParam1.name}}</view>
+ <view class="querenfee-c-input">
+ <input type="number" placeholder-style="color: #999999; font-size: 56rpx; font-weight: 500;" @input="getTotal" v-model="feeFrom.priceNum1" placeholder="璇疯緭鍏�" />
+ </view>
+ <text class="querenfee-c-danw">{{feeFrom.priceParam1.unit}}</text>
+ </view>
+ <view class="querenfee-c" v-if="feeFrom.priceParam2.name !=null">
+ <view class="querenfee-c-info1"><text style="color: red;">*</text>瀹為檯{{feeFrom.priceParam2.name}}锛�</view>
+ <view class="querenfee-c-input">
+ <input type="number" v-model="feeFrom.priceNum2" placeholder-style="color: #999999; font-size: 56rpx; font-weight: 500;" @input="getTotal" placeholder="璇疯緭鍏�" />
+ </view>
+ <text class="querenfee-c-info1" >{{feeFrom.priceParam2.unit}}</text>
+ </view>
+ <view class="querenfee-c">
+ <view class="querenfee-c-info1">鍏朵粬璐圭敤锛�</view>
+ <view class="querenfee-c-input">
+ <input type="digit" v-model="feeFrom.confirmOtherFee" placeholder-style="color: #999999; font-size: 56rpx; font-weight: 500;" placeholder="璇疯緭鍏�" />
+ </view>
+ <text class="querenfee-c-danw">鍏�</text>
+ </view>
+ <view class="querenfee-c" style="flex-direction: column;">
+ <view class="querenfee-c-info1" style="margin-bottom: 30rpx;">澶囨敞淇℃伅锛�</view>
+ <view class="querenfee-c-input" style="width: 100%; height: 200rpx; padding: 30rpx; box-sizing: border-box;">
+ <u--textarea placeholder="濡傞渶澶囨敞锛岃杈撳叆" border="none" v-model="feeFrom.confirmFeeRemark" ></u--textarea>
+ </view>
+ </view>
+ <view class="querenfee-c">
+ <view class="querenfee-c-info1">瀹為檯鎬昏垂鐢細</view>
+ <view class="querenfee-c-price">
+ 锟{confirmPayFee}}
+ </view>
+ <!-- <view class="querenfee-c-input">
+ <image src="/static/icon/ic_money@2x.png" mode="widthFix"></image>
+ <text class="querenfee-c-input money">{{confirmPayFee}}</text>
+ </view> -->
+ </view>
+ <view class="querenfee-c" style="margin-top: 12rpx;">
+ <view class="querenfee-tips">鏈�缁堣垂鐢ㄧ敱鍙戝崟鏂规敮浠橈紝鎺ュ崟鏂规敹鍒扮殑閲戦灏嗘墸闄ゅ钩鍙版墜缁垂鐢�</view>
+ </view>
+ <view class="querenfee-botton" @click="confirmFee">纭璐圭敤</view>
+ </view>
+ </u-popup>
<!-- 璇勪环 -->
<u-popup :show="show2" round="15" mode="bottom">
<view class="zhifu">
@@ -299,14 +426,24 @@
},
data() {
return {
+ isPushlishor:false,//鏄惁鍙戝崟鏂�
+ isAcceptor:false,//鏄惁鎺ュ崟鏂�
show: false,
show1: false,
show2: false,
count: 5,
show3:false,
+ timer:null,
+ timer1:null,
show4:false,
show5:false,
show6:false,
+ show7:false,
+ actionFlag:null,
+ timeInfo:'00:00:00',
+ timeInfo1:'00:00:00',
+ lessTime:null,
+ lessTime1:null,
value:0,
wayList:[],
bgImg: require('@/static/image/bg_green@2x.png'),
@@ -314,13 +451,31 @@
loading:false,
commentInfo:'',
info: {},
- amount: ''
+ amount: '',
+ confirmPayFee:0.00,
+ feeFrom:{
+ priceParam1:{
+ name:null,
+ unit:null
+ },
+ priceParam2:{
+ name:null,
+ unit:null
+ },
+ priceNum1:null,
+ priceNum2:null,
+ confirmFeeRemark:null,
+ confirmOtherFee:null,
+ }
};
},
onLoad(options) {
console.log(options)
var id = options.id
- this.id = id
+ this.id = id
+ this.actionFla=options.flag
+ },
+ onShow(options) {
this.getOrderData()
},
methods:{
@@ -361,6 +516,68 @@
url: `/pages/freight/freight?id=${this.info.id}`
})
}
+ },
+ payment1() {
+ var that = this
+ this.$u.api.doneOrder({
+ orderId: this.info.id
+ }).then(res => {
+ if (res.code === 200) {
+ that.getOrderData()
+ }
+ })
+ },
+ getTotal() {
+ this.$u.api.getTotal({
+ price: this.info.price,
+ priceUnit: this.feeFrom.priceParam1.unit,
+ priceNum1: this.feeFrom.priceNum1 || 0,
+ priceNum2: this.feeFrom.priceNum2 || 0,
+ type: this.info.type
+ }).then(res => {
+ if (res.code === 200) {
+ this.confirmPayFee = (res.data / 100) || '0'
+ }
+ })
+ },
+ confirmFee(){
+ if (!this.feeFrom.priceNum1) {
+ return uni.showToast({
+ title: '瀹為檯' + this.feeFrom.priceParam1.name + '涓嶈兘涓虹┖',
+ icon: 'none'
+ })
+ }
+ if (this.feeFrom.priceParam2.name && !this.feeFrom.priceNum2) {
+ return uni.showToast({
+ title: '瀹為檯' + this.feeFrom.priceParam2.name + '涓嶈兘涓虹┖',
+ icon: 'none'
+ })
+ }
+ uni.requestSubscribeMessage({
+ tmplIds: ['3rOz7DAnawrkKDM8b5_XW4FLivISWYov6d7QSC4ORsg'],
+ success(res) {
+ that.doConfirmFeeBiz()
+ },
+ fail(err) {
+ that.doConfirmFeeBiz()
+ }
+ })
+ },
+ doConfirmFeeBiz(){
+ var that = this
+ this.$u.api.confirmFee({
+ confirmFeeRemark: this.feeFrom.confirmFeeRemark,
+ confirmOtherFee: (this.feeFrom.confirmOtherFee||0)*100,
+ orderId: this.info.id,
+ priceNum1: this.feeFrom.priceNum1,
+ priceNum2: this.feeFrom.priceNum2
+ }).then(res => {
+ if (res.code === 200) {
+ that.show7 = false
+ uni.showToast({ title: '鎿嶄綔鎴愬姛', icon: 'success', duration: 2000 });
+ that.getOrderData()
+ }
+ })
},
payment() {
var that = this
@@ -466,18 +683,27 @@
},
cancelDo(){
var that = this
- var param ={ orderId:that.id}
- this.$u.api.cancelOrder(param).then(res =>{
- if(res.code ===200){
- that.show=false
- uni.showToast({ title: '璁㈠崟鍙栨秷鎴愬姛', icon: 'error', duration: 2000 });
- if(that.userInfo.id !== that.info.releaseMemberId){
- uni.navigateBack({ delta: 1 })
- }else{
- that.getOrderData()
- }
+ uni.requestSubscribeMessage({
+ tmplIds: ['AA97cHjvlPiNO4viMkVe4JifCf9TD5b5Eb7s6El3VS8'],
+ success(res) {
+ var param ={ orderId:that.id}
+ that.$u.api.cancelOrder(param).then(res =>{
+ if(res.code ===200){
+ that.show=false
+ uni.showToast({ title: '璁㈠崟鍙栨秷鎴愬姛', icon: 'error', duration: 2000 });
+ if(that.userInfo.id !== that.info.releaseMemberId){
+ uni.navigateBack({ delta: 1 })
+ }else{
+ that.getOrderData()
+ }
+ }
+ })
+ },
+ fail(err) {
+ console.log(err)
}
- })
+ })
+
},
previemImg(src){
uni.previewImage({
@@ -501,7 +727,12 @@
}else if(this.info.status === 1){
return ''
}else if(this.info.status === 2){
+ if(this.info.isUpdate==1){
+ return ''
+ }
return '鎮ㄥ凡鎺ュ崟锛岃鎸夋椂瀹屾垚璁㈠崟浠诲姟'
+ }else if(this.info.status === 5){
+ return '鎮ㄥ凡纭璐圭敤锛岀瓑寰呭彂鍗曟柟鏀粯'
}else if(this.info.status === 3){
return '璁㈠崟杩涜涓紝璇锋寜鏃跺畬鎴愯鍗曚换鍔�'
}else if(this.info.status === 4){
@@ -515,8 +746,13 @@
return '璇峰敖蹇畬鎴愭敮浠橈紝鍙戝竷璁㈠崟'
}else if(this.info.status === 1){
return '鎮ㄨ鍗曞凡缁忔垚鍔熷彂璧凤紝璇疯�愬績绛夊緟鎺ュ崟'
+ }else if(this.info.status === 5){
+ return '鎺ュ崟鏂瑰凡纭璐圭敤锛岃鏀粯'
}else if(this.info.status === 2){
- return '璁㈠崟寮�濮嬩綔涓氬悗锛岃鎷栧姩涓嬫柟鈥滃紑濮嬩綔涓氣�濇寜'
+ if(this.info.isUpdate==1){
+ return '璁㈠崟宸蹭慨鏀癸紝璇风瓑寰呮帴鍗曟柟纭'
+ }
+ return '璁㈠崟宸叉帴鍗曪紝璇锋嫋鍔ㄤ笅鏂光�滃紑濮嬩綔涓氣�濇寜閽�'
}else if(this.info.status === 3){
return this.info.type!=2?'璁㈠崟瀹屾垚鍚庤鐐瑰嚮涓嬫柟鈥滃畬鎴愬苟鏀粯鈥濇寜閽�':'璁㈠崟姝e湪杩涜涓�'
}else if(this.info.status === 4){
@@ -526,22 +762,137 @@
}
}
},
+ updateTimeInfo1(){
+ if(this.timer1){
+ clearInterval(this.timer1)
+ }
+ var that =this
+ this.lessTime1 = Math.floor( Number(that.info.cancelCountdown || 0)/1000) ;
+ if(this.lessTime1>0){
+ this.timer1 = setInterval(function(){
+ let h = Math.floor(that.lessTime1/60/60) ;
+ let m = Math.floor((that.lessTime1 - h*60*60)/60);
+ let s= Math.floor(that.lessTime1- h*60*60 -m*60);
+ that.timeInfo1 =(h<10?'0':'')+ h+":"+(m<10?'0':'')+m+":"+(s<10?'0':'')+s;
+ that.lessTime1 =that.lessTime1-1;
+ if(that.lessTime1 <=0){
+ that.timeInfo1 ="00:00:00"
+ clearInterval(that.timer1)
+ }
+ // console.log( that.timeInfo)
+ },1000)
+ }
+
+ },
+ updateTimeInfo(){
+ if(this.timer){
+ clearInterval(this.timer)
+ }
+ var that =this
+ this.lessTime = Math.floor( Number(that.info.confirmCountdown || 0)/1000) ;
+ if(this.lessTime>0){
+ this.timer = setInterval(function(){
+ let h = Math.floor(that.lessTime/60/60) ;
+ let m = Math.floor((that.lessTime - h*60*60)/60);
+ let s= Math.floor(that.lessTime- h*60*60 -m*60);
+ that.timeInfo =(h<10?'0':'')+ h+":"+(m<10?'0':'')+m+":"+(s<10?'0':'')+s;
+ that.lessTime =that.lessTime-1;
+ // console.log( that.timeInfo)
+ if(that.lessTime<=0){
+ that.timeInfo ="00:00:00"
+ clearInterval(that.timer)
+ }
+ },1000)
+ }
+
+ },
getOrderData(){
var that = this
var param ={ orderId:that.id}
+ this.isPushlishor =false
+ this.isAcceptor =false
this.$u.api.getDetail(param).then(res =>{
if(res.code ===200){
- if(that.userInfo.id === res.data.releaseMemberId || that.userInfo.id === res.data.acceptMemberId ){
+ if(that.userInfo.id === res.data.releaseMemberId ){
+ //濡傛灉鏄彂鍗曟柟
+ that.isPushlishor =true
+ }else if(that.userInfo.id ===res.data.acceptMemberId ){
+ //濡傛灉鏄帴鍗曟柟
+ that.isAcceptor =true
+ }
+ if(that.isAcceptor ||that.isPushlishor ){
that.info = res.data
+ if(that.userInfo.id === that.info.releaseMemberId ){
+ //濡傛灉鏄彂鍗曟柟
+ that.isPushlishor =true
+ }else if(that.userInfo.id === that.info.acceptMemberId ){
+ //濡傛灉鏄帴鍗曟柟
+ that.isAcceptor =true
+ }
that.amount = ((that.info.estimatedAccount || 0) / 100).toFixed(2)
if(that.info.wayInfo){
that.wayList = JSON.parse(that.info.wayInfo)
}
+ if(res.data.isUpdate == 1){
+ that.updateTimeInfo()
+ }
+ if(res.data.status == 0){
+ that.updateTimeInfo1()
+ }
+ that.initPriceNumParam()
}else{
uni.showToast({ title: '璁㈠崟淇℃伅涓嶅瓨鍦�', icon: 'error', duration: 2000 });
}
}
})
+ },
+ initPriceNumParam(){
+ this.feeFrom.priceParam1.name =null
+ this.feeFrom.priceParam1.unit =null
+ this.feeFrom.priceParam2.name =null
+ this.feeFrom.priceParam2.unit =null
+ if(this.info.type==0 && this.info.workType==1){
+ //鍒嗘嫞宸�
+ this.feeFrom.priceParam1.name ='鐢ㄥ伐澶╂暟锛�'
+ this.feeFrom.priceParam1.unit ='澶�'
+ this.feeFrom.priceParam2.name ='鐢ㄥ伐浜烘暟锛�'
+ this.feeFrom.priceParam2.unit ='浜�'
+ }else if(this.info.type==0 && this.info.workType==0){
+ //閲囨憳宸�
+ this.feeFrom.priceParam1.name ='閲囨憳閲嶉噺锛�'
+ this.feeFrom.priceParam1.unit ='鏂�'
+ this.feeFrom.priceParam2.name =null
+ this.feeFrom.priceParam2.unit =null
+ }else if(this.info.type==0 && this.info.workType==2){
+ //鍖呰宸�
+ if(this.info.carType==0){
+ //鎸夊ぉ
+ this.feeFrom.priceParam1.name ='鐢ㄥ伐澶╂暟'
+ this.feeFrom.priceParam1.unit ='澶�'
+ this.feeFrom.priceParam2.name ='鐢ㄥ伐浜烘暟'
+ this.feeFrom.priceParam2.unit ='浜�'
+ }else if(this.info.carType==1){
+ //鎸夊皬鏃�
+ this.feeFrom.priceParam1.name ='宸ヤ綔鏃堕暱'
+ this.feeFrom.priceParam1.unit ='鏃�'
+ this.feeFrom.priceParam2.name ='鐢ㄥ伐浜烘暟'
+ this.feeFrom.priceParam2.unit ='浜�'
+ }else if(this.info.carType==1){
+ //鎸夊皬鏃�
+ this.feeFrom.priceParam1.name ='鍖呰閲嶉噺'
+ this.feeFrom.priceParam1.unit ='鏂�'
+ this.feeFrom.priceParam2.name =null
+ this.feeFrom.priceParam2.unit =null
+ }
+ }else if(this.info.type==1 && this.info.carType==0){
+ //杩愯揣鍗� 鎸夊ぉ鏁�
+ this.feeFrom.priceParam1.name ='鐢ㄨ溅澶╂暟'
+ this.feeFrom.priceParam1.unit ='澶�'
+ }else if(this.info.type==1 && this.info.carType==1){
+ //杩愯揣鍗� 鎸夋鏁�
+ this.feeFrom.priceParam1.name ='鐢ㄨ溅娆℃暟'
+ this.feeFrom.priceParam1.unit ='娆�'
+ }
}
}
}
@@ -569,6 +920,139 @@
<style lang="scss" scoped>
.order {
width: 100%;
+ .querenfee {
+ width: 100%;
+ padding: 40rpx 30rpx;
+ box-sizing: border-box;
+
+ .querenfee-textarea {
+ width: 100%;
+ height: 364rpx;
+ padding: 30rpx;
+ box-sizing: border-box;
+ background: #F7F7F7;
+ border-radius: 16rpx;
+ border: 1rpx solid #EEEEEE;
+ margin-top: 48rpx;
+ display: flex;
+ align-items: start;
+ image {
+ flex-shrink: 0;
+ width: 29rpx;
+ height: 29rpx;
+ margin-right: 10rpx;
+ }
+ }
+
+ .querenfee-head {
+ width: 100%;
+ display: flex;
+ align-items: center;
+ justify-content: space-between;
+ image {
+ width: 28rpx;
+ height: 28rpx;
+ }
+ text {
+ font-weight: 500;
+ font-size: 32rpx;
+ color: #222222;
+ }
+ }
+ .querenfee-c {
+ width: 100%;
+ margin-top: 46rpx;
+ display: flex;
+ justify-content: space-between;
+ .querenfee-c-info {
+ align-items: center;
+ font-weight: 500;
+ font-size: 30rpx;
+ color: #222222;
+ margin-bottom: 30rpx;
+ text {
+ color: #00BC12;
+ margin-left: 10rpx;
+ }
+ }
+ .querenfee-c-danw {
+ display: flex;
+ align-items: center;
+ flex-shrink: 0;
+ font-weight: 400;
+ font-size: 30rpx;
+ color: #333333;
+ margin-left: 10rpx;
+ }
+ .querenfee-c-price {
+ font-weight: 600;
+ font-size: 44rpx;
+ color: #FF0000;
+ }
+ .querenfee-c-info1 {
+ width: 50%;
+ display: flex;
+ align-items: center;
+ font-weight: 600;
+ font-size: 32rpx;
+ color: #222222;
+ }
+ .querenfee-tips{
+ width: 100%;
+ font-weight: 400;
+ font-size: 26rpx;
+ color: #999999;
+ line-height: 36rpx;
+ }
+ .money{
+ width: 50%;
+ text-align: right;
+ font-weight: 600;
+ font-size: 34rpx;
+ color: #FF0000 !important;
+ }
+ .querenfee-c-input {
+ width: 260rpx;
+ height: 100rpx;
+ padding: 10rpx 30rpx;
+ box-sizing: border-box;
+ background: #F7F7F7;
+ border-radius: 10rpx;
+ border: 1rpx solid #EEEEEE;
+ display: flex;
+ align-items: center;
+ image {
+ flex-shrink: 0;
+ width: 28rpx;
+ height: 60rpx;
+ margin-right: 24rpx;
+ }
+ input {
+ flex: 1;
+ height: 100%;
+ font-weight: 500;
+ font-size: 56rpx;
+ color: #222222;
+ text-align: right;
+ .querenfee-c-input-placeholder {
+ font-size: 32rpx !important;
+ }
+ }
+ }
+ }
+ .querenfee-botton {
+ width: 100%;
+ height: 88rpx;
+ line-height: 88rpx;
+ text-align: center;
+ font-weight: 500;
+ font-size: 32rpx;
+ color: #FFFFFF;
+ background: #00BC12;
+ border-radius: 44rpx;
+ margin-top: 40rpx;
+ }
+ }
.zhifu {
width: 100%;
padding: 40rpx 30rpx;
@@ -641,6 +1125,9 @@
color: #666666;
margin-bottom: 20rpx;
}
+ .money{
+ color: red !important;
+ }
.zhifu-c-input {
width: 100%;
padding: 0 30rpx;
--
Gitblit v1.9.3