From 69d5249f897fee99f8e52813c9e18b655b14fd2a Mon Sep 17 00:00:00 2001
From: jiangping <jp@doumee.com>
Date: 星期六, 19 七月 2025 11:13:07 +0800
Subject: [PATCH] 前端
---
small-program/pages/order-details/order-details.vue | 86 +++++++++++++++++++++++++++++++++++++++---
1 files changed, 79 insertions(+), 7 deletions(-)
diff --git a/small-program/pages/order-details/order-details.vue b/small-program/pages/order-details/order-details.vue
index 9896ee8..2149440 100644
--- a/small-program/pages/order-details/order-details.vue
+++ b/small-program/pages/order-details/order-details.vue
@@ -168,10 +168,11 @@
<view class="order-footer-btn">
<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" v-if="userInfo.id === info.releaseMemberId && (info.status ===4 && info.commentStatus!=1)">鍘昏瘎浠�</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))">鍘绘敮浠�</view>
<view class="order-footer-btn-b" v-if="userInfo.id === info.releaseMemberId && (info.status ===0 || info.status ===1|| info.status ===2)">淇敼璁㈠崟</view>
<view class="order-footer-btn-b" v-if="userInfo.id === info.releaseMemberId && (info.isUpdate==1 && info.status ===2)">淇敼纭</view>
+ <view class="order-footer-btn-b" @click="show3 =true" v-if="userInfo.id === info.releaseMemberId && (info.status ===2)">寮�濮嬩綔涓�</view>
<view class="order-footer-btn-b" v-if="userInfo.id !== info.releaseMemberId && (info.status ===1)">鎶㈠崟</view>
</view>
<view style="width: 100%; height: env(safe-area-inset-bottom);"></view>
@@ -188,10 +189,23 @@
</view>
<view slot="confirmButton" style="display: flex; justify-content: space-between; align-items: center; width: 100%;">
<view class="btn1" @click="show = false">鎴戝啀鎯虫兂</view>
- <view class="btn2" @click="show = false">纭鍙栨秷</view>
+ <view class="btn2" @click="cancelDo">纭鍙栨秷</view>
</view>
</u-modal>
-
+ <u-modal
+ title="娓╅Θ鎻愮ず"
+ :show="show3"
+ closeOnClickOverlay
+ showCancelButton
+ >
+ <view class="slot-content">
+ 纭寮�濮嬩綔涓氬悧锛�
+ </view>
+ <view slot="confirmButton" style="display: flex; justify-content: space-between; align-items: center; width: 100%;">
+ <view class="btn1" @click="show3 = false">鎴戝啀鎯虫兂</view>
+ <view class="btn2" @click="beginDo">纭寮�濮�</view>
+ </view>
+ </u-modal>
<!-- 鏀粯寮圭獥 -->
<u-popup :show="show1" round="15" mode="bottom">
<view class="zhifu">
@@ -225,14 +239,14 @@
<view class="zhifu-pj">
<view class="zhifu-pj-label">鏈嶅姟璇勪环</view>
<view class="zhifu-pj-val">
- <u-rate :count="count" activeColor="#FFC331" size="26" v-model="value"></u-rate>
+ <u-rate :count="count" activeColor="#FFC331" size="26" v-model="value" @click=""></u-rate>
</view>
</view>
<view class="zhifu-textarea">
<image src="/static/icon/ic_pingjia@2x.png" mode="widthFix"></image>
- <u--textarea placeholder="璇疯璇存偍瀵规湰娆′氦鏄撶殑鎰熷彈" border="none" count></u--textarea>
+ <u--textarea placeholder="璇疯璇存偍瀵规湰娆′氦鏄撶殑鎰熷彈" border="none" v-model="commentInfo" count></u--textarea>
</view>
- <view class="zhifu-botton" style="margin-top: 60rpx;">绔嬪嵆璇勪环</view>
+ <view class="zhifu-botton" style="margin-top: 60rpx;" @click="commentDo">绔嬪嵆璇勪环</view>
</view>
</u-popup>
</view>
@@ -250,10 +264,13 @@
show1: false,
show2: false,
count: 5,
+ show3:false,
+ value:0,
wayList:[],
bgImg: require('@/static/image/bg_green@2x.png'),
id: null,
loading:false,
+ commentInfo:'',
info: {},
};
},
@@ -264,6 +281,61 @@
this.getOrderData()
},
methods:{
+ commentDo(){
+ var that = this
+ var param = { info: that.commentInfo,level:that.value||0,orderId: this.id}
+ this.$u.api.comment(param).then(res =>{
+ if(res.code ===200){
+ that.show2=false
+ uni.showToast({ title: '璇勪环鎴愬姛', icon: 'error', duration: 2000 });
+ that.getOrderData()
+ }
+ })
+ },
+ beginDo(){
+ var that = this
+ var param = {orderId: this.id}
+ this.$u.api.begin(param).then(res =>{
+ if(res.code ===200){
+ that.show3=false
+ uni.showToast({ title: '鎿嶄綔鎴愬姛', icon: 'error', duration: 2000 });
+ that.getOrderData()
+ }
+ })
+ },
+ confirmUpdDo(){
+ var that = this
+ var param = {orderId: this.id}
+ this.$u.api.confirmUpdDo(param).then(res =>{
+ if(res.code ===200){
+ that.show=false
+ uni.showToast({ title: '鎿嶄綔鎴愬姛', icon: 'error', duration: 2000 });
+ that.getOrderData()
+ }
+ })
+ },
+ acceptDo(){
+ var that = this
+ var param = {orderId: this.id}
+ this.$u.api.accept(param).then(res =>{
+ if(res.code ===200){
+ that.show=false
+ uni.showToast({ title: '鎶㈠崟鎴愬姛', icon: 'error', duration: 2000 });
+ that.getOrderData()
+ }
+ })
+ },
+ 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 });
+ that.getOrderData()
+ }
+ })
+ },
previemImg(src){
uni.previewImage({
current: src, // 褰撳墠鏄剧ず鍥剧墖鐨刪ttp閾炬帴
@@ -508,7 +580,7 @@
box-sizing: border-box;
display: flex;
align-items: center;
- justify-content: space-between;
+ justify-content: space-between;
.order-footer-btn-a {
width: 334rpx;
height: 88rpx;
--
Gitblit v1.9.3