修复bug

This commit is contained in:
weipengfei 2024-03-09 17:11:28 +08:00
parent 89d15488cc
commit a6f33524dc
7 changed files with 97 additions and 101 deletions

View File

@ -162,7 +162,7 @@
uni.navigateBack({
delta:1
});
},500)
},1500)
})
},
//

View File

@ -12,12 +12,17 @@
<view class="content-top_img" v-else @click="login">
<image src="@/static/images/f.png" mode="aspectFit"></image>
</view>
<view class="content-top-title" @click="shopp" v-if="Object.keys(userInfoData).length>0">
<view class="top-titlea">
{{userInfoData.mer_info.mer_name?userInfoData.mer_info.mer_name:'暂无信息'}}
<view v-if="Object.keys(userInfoData).length>0">
<view class="content-top-title" @click="shopp" v-if="Object.keys(userInfoData).length>0">
<view class="top-titlea">
{{userInfoData.mer_info.mer_name?userInfoData.mer_info.mer_name:'暂无信息'}}
</view>
<view class="top-titleb">
<image src="@/static/images/you.png" mode=""></image>
</view>
</view>
<view class="top-titleb">
<image src="@/static/images/you.png" mode=""></image>
<view class="content-mer-type" v-if="userInfoData.mer_info">
<text>{{userInfoData.mer_info.type_name}}</text>
</view>
</view>
<view class="content-top-title" @click="login" v-else>
@ -2185,6 +2190,16 @@
}
}
.content-mer-type{
font-size: 22rpx;
padding: 0 10rpx;
text{
background-color: $theme-color;
padding: 2rpx 8rpx 0 8rpx;
color: #fff;
border-radius: 8rpx;
}
}
}
.content-middle {

View File

@ -23,7 +23,7 @@
<view class="tab">
<view class="item active" style="margin: 0;">{{merchant_Data.margin}}</view>
</view>
<button class="btn" @click="paydecimal">缴纳</button>
<button class="btn" :class="{'btn-d': merchant_Data.is_margin != 1}" @click="paydecimal">{{merchant_Data.is_margin != 1?"无需缴纳":"缴纳"}}</button>
</view>
<!-- <view class="tip">
<view class="title">注意事项</view>
@ -170,28 +170,30 @@
content: '商户' + this.merchant_Data.mer_name + '是否同意缴纳押金',
success: (res) => {
if (res.confirm) {
// console.log('');
paymerchant().then((res) => {
console.log(res);
uni.requestPayment({
provider: 'wxpay',
orderInfo: res.data
.config, //
success: (res) => {
this.$util.Tips({
title: '支付成功'
});
this.decimal()
this.list(true)
},
fail: (err) => {
this.$util.Tips({
title: '支付失败'
});
console.log('fail:' + JSON.stringify(err));
}
});
try{
uni.requestPayment({
provider: 'wxpay',
orderInfo: res.data
.config, //
success: (res) => {
this.$util.Tips({
title: '支付成功'
});
this.decimal()
this.list(true)
},
fail: (err) => {
this.$util.Tips({
title: '支付失败'
});
console.log('fail:' + JSON.stringify(err));
}
});
}catch(err){
Toast('请前往小程序中支付')
}
}).catch((err) => {
this.$util.Tips({
title: err
@ -225,7 +227,7 @@
if (isPage === true) that.$set(that, 'deductList', []);
that.loading2 = true;
that.loadTitle2 = '';
autoMarginlist(36, that.where2).then(res=>{
autoMarginlist(this.mer_id, that.where2).then(res=>{
let list = res.data;
let deductList = that.$util.SplitArray(list, that.deductList);
let loadend = list.length < that.where2.limit;
@ -405,6 +407,9 @@
font-weight: 400;
color: #FFFFFF;
}
.btn-d{
background-color: #999;
}
}
.tip {

View File

@ -1,39 +1,8 @@
<template>
<view class="content">
<view class="content-top">
<view class="content-tops">
<view class="content-top_img" v-if="Object.keys(userInfoData).length>0">
<image :src="userInfoData.mer_info.mer_avatar"
v-if="userInfoData.mer_info&&userInfoData.mer_info.mer_avatar" mode="aspectFill"
@click="logout">
</image>
<image src="@/static/images/f.png" v-else mode="aspectFit" @click="logout"></image>
</view>
<view class="content-top_img" v-else @click="login">
<image src="@/static/images/f.png" mode="aspectFit"></image>
</view>
<view class="content-top-title" @click="shopp" v-if="Object.keys(userInfoData).length>0">
<view class="top-titlea">
{{userInfoData.mer_info.mer_name?userInfoData.mer_info.mer_name:'暂无信息'}}
</view>
<view class="top-titleb">
<image src="@/static/images/you.png" mode=""></image>
</view>
</view>
<view class="content-top-title" @click="login" v-else>
<view class="top-titlea">
请登录
</view>
<view class="top-titleb">
<image src="@/static/images/you.png" mode=""></image>
</view>
</view>
</view>
<retuntop style="margin-top: 20rpx; margin-right: 50rpx;" />
</view>
<view class="content-middle">
<view class="content-middlea" v-for="(item,index) in list" :key='index' @click="handleToWithDraw">
<view class="content-middlea" v-for="(item,index) in list" :key='index' @click="handleToWithDraw(item, index)">
<view class="content-middlea-one">
{{item.name}}
</view>
@ -537,12 +506,14 @@
},
methods: {
//
handleToWithDraw() {
uni.navigateTo({
url: "/pages/users/embody/embody?mer_id=" + this.userInfoData.service.mer_id
})
handleToWithDraw(item, index) {
let url;
if(index<2) url = "/pages/users/embody/embody?mer_id=" + this.userInfoData.service.mer_id;
else url = `/pages/admin/orderList/index?merId=${this.userInfoData.service.mer_id}&types=2`
uni.navigateTo({
url: url
})
},
//
initTypeLiseMenu() {
@ -1758,7 +1729,7 @@
}
.content {
padding-top: 80rpx;
// padding-top: 80rpx;
.content-top {
display: flex;
@ -1820,7 +1791,7 @@
// padding: 0 30rpx;
display: flex;
justify-content: space-around;
margin-top: 61rpx;
margin-top: 21rpx;
.content-middlea {
// width: 161rpx;

View File

@ -287,12 +287,12 @@
</view>
<view class='item acea-row row-between' v-if="orderInfo.activity_type == 2">
<view>实付款</view>
<view class='conter'>{{orderInfo.presell_price}}</view>
<view class='conter' style="color: #f45846;">{{orderInfo.presell_price}}</view>
</view>
<view class="settel" v-else>
<view class='settel-t'>
<view>实付款</view>
<view class='conter'>{{orderInfo.pay_price}}</view>
<view class='conter' style="color: #f45846;">{{orderInfo.pay_price}}</view>
</view>
<view class="settel-m" v-if="orderInfo.pay_type == 8 && orderInfo.status == 12">
结算周期到期后付款 100.00

View File

@ -235,7 +235,7 @@
} else if (this.product_type == 99) {
if(val==1){
uni.navigateTo({
url: `/pages/users/order_list/relase?status=1&product_type=${this.product_type}`
url: `/pages/users/order_list/relase?status=2&product_type=${this.product_type}`
})
}else{
uni.navigateTo({
@ -245,9 +245,9 @@
} else {
if(val==1){
uni.navigateTo({
url: '/pages/users/order_list/index?status=1&product_type=0'
})
uni.navigateTo({
url: '/pages/users/order_list/index?status=2&product_type=0'
})
}else{
uni.navigateTo({
url: '/pages/users/order_list/index?status=0&product_type=0'

View File

@ -63,7 +63,7 @@
<view v-if="orderList.length > 0">
<block v-if="orderStatus == 0">
<view class='item' v-for="(item,index) in orderList" :key="index">
<view @click='goOrderDetails(item.group_order_id)'>
<view @click='goOrderDetails(item.group_order_id, item)'>
<view class='title acea-row row-between-wrapper'>
<view class="acea-row row-middle left-wrapper">
{{item.group_order_sn}}
@ -84,8 +84,9 @@
</view>
<view class='text acea-row row-between'>
<view class='name line1'>
<text
class="event_name event_bg">预售</text><text>{{goods.cart_info.product.store_name}}</text>
<!-- <text
class="event_name event_bg">预售</text> -->
<text>{{goods.cart_info.product.store_name}}</text>
<view class="event_ship event_color">发货时间
<!--全款预售-->
<text
@ -153,7 +154,7 @@
<!-- 待发货 待收货 待评价 已完成 -->
<block v-else>
<view class='item' v-for="(item,index) in orderList" :key="index">
<view @click='goOrderDetails(item.order_id)'>
<view @click='goOrderDetails(item.order_id, item)'>
<view class='title acea-row row-between-wrapper'>
<view class="acea-row row-middle left-wrapper" @click.stop="goMall(item)">
<text class="iconfont icon-shangjiadingdan"></text>
@ -186,8 +187,9 @@
<view class='text acea-row row-between'>
<view class='name '>
<view class='name' :class="item.status === 0 ? 'line1' : 'line2'">
<text
class="event_name event_bg">预售</text><text>{{goods.cart_info.product.store_name}}</text>
<!-- <text
class="event_name event_bg">预售</text> -->
<text>{{goods.cart_info.product.store_name}}</text>
<view v-if="item.status == 0" class="event_ship event_color">发货时间
<!--全款预售-->
<text
@ -250,10 +252,10 @@
</view>
</view>
<view class='bottom acea-row row-right row-middle'>
<!-- <view v-if="!item.receipt && item.status != -1" class='bnt cancelBnt'
@click.stop='applyInvoice(item.order_id)'>申请开票</view> -->
<view v-if="!item.receipt && item.status != -1 && (item.status != 0)" class='bnt cancelBnt'
@click.stop='applyInvoice(item.order_id)'>申请开票</view>
<block v-if="item.status == 0 || item.status == 9 || item.status == -1">
<view class='bnt b-color' @click='goOrderDetails(item.order_id)'>查看详情</view>
<view class='bnt b-color' @click='goOrderDetails(item.order_id, item)'>查看详情</view>
</block>
<block v-if="item.status == 1">
<view class='bnt cancelBnt'
@ -269,7 +271,7 @@
<text class="iconfont icon-fabu"></text>
发布种草
</navigator> -->
<view class='bnt b-color' @click='goOrderDetails_Evaluation(item.order_id)'>去评价
<view class='bnt b-color' @click='goOrderDetails_Evaluation(item)'>去评价
</view>
</block>
<block v-if="item.status == 3">
@ -343,6 +345,7 @@
import {
HTTP_REQUEST_URL
} from '@/config/app';
import { Toast } from '../../../libs/uniApi';
export default {
components: {
payment,
@ -500,7 +503,8 @@
getOrderData: function() {
let that = this;
orderData({
product_type: 0
product_type: 0,
source: 103
}).then(res => {
that.$set(that, 'orderData', res.data);
})
@ -564,10 +568,10 @@
/**
* 去订单详情
*/
goOrderDetails: function(order_id) {
goOrderDetails: function(order_id, item) {
let self = this
if (!order_id) return that.$util.Tips({
title: '缺少订单号无法查看订单详情'
});
@ -575,16 +579,13 @@
uni.showLoading({
title: '正在加载',
})
openOrderSubscribe().then(() => {
uni.hideLoading();
if (self.orderStatus == 0) {
if (self.orderStatus == 0 || (item&&item.order_status==1)) {
uni.navigateTo({
url: '/pages/order_details/stay?order_id=' + order_id
})
} else if (self.orderStatus == 1) {
uni.navigateTo({
url: `/pages/order_details/stay?order_id=${order_id}&orderStatus=${self.orderStatus}`
})
@ -598,9 +599,9 @@
})
// #endif
// #ifndef MP
if (self.orderStatus == 0) {
if (self.orderStatus == 0||(item&&item.order_status==1)) {
uni.navigateTo({
url: '/pages/order_details/stay?order_id=' + order_id
url: '/pages/order_details/stay?order_id=' + item.group_order_id
})
} else if (self.orderStatus == 1) {
// uni.navigateTo({
@ -619,30 +620,32 @@
/**
* 点击去评价
*/
goOrderDetails_Evaluation: function(order_id) {
goOrderDetails_Evaluation: function(item) {
let self = this
if (!order_id) return that.$util.Tips({
if (!item.order_id) return that.$util.Tips({
title: '缺少订单号无法查看订单详情和评价'
});
// #ifdef MP
if (self.orderStatus == 0) {
uni.navigateTo({
url: '/pages/order_details/stay?order_id=' + order_id
url: '/pages/order_details/stay?order_id=' + item.order_id
})
} else {
if(!item.orderProduct[0]?.order_product_id) return Toast('无法评价该商品')
uni.navigateTo({
url: '/pages/order_details/index?order_id=' + order_id
url: `/pages/users/goods_comment_con/index?uni=${item.orderProduct[0].order_product_id}&order_id=${item.order_id}`
})
}
// #endif
// #ifndef MP
if (self.orderStatus == 0) {
uni.navigateTo({
url: '/pages/order_details/stay?order_id=' + order_id
url: '/pages/order_details/stay?order_id=' + item.order_id
})
} else {
if(!item.orderProduct[0]?.order_product_id) return Toast('无法评价该商品')
uni.navigateTo({
url: '/pages/order_details/index?order_id=' + order_id
url: `/pages/users/goods_comment_con/index?uni=${item.orderProduct[0].order_product_id}&order_id=${item.order_id}`
})
}
// #endif
@ -652,7 +655,6 @@
*/
statusClick: function(status) {
if (status == this.orderStatus) return;
this.orderStatus = status;
this.loadend = false;
this.loading = false;
@ -675,7 +677,8 @@
groupOrderList({
page: that.page,
limit: that.limit,
product_type: 0
product_type: 0,
source: 103
}).then(res => {
that.isReady = true;
let list = res.data.list || [];
@ -702,7 +705,8 @@
status: arr,
page: that.page,
limit: that.limit,
product_type: 0
product_type: 0,
source: 103
}).then(res => {
let list = res.data.list || [];
let loadend = list.length < that.limit;
@ -731,6 +735,7 @@
status: 10,
page: 1,
limit: 1,
source: 103
}).then(res => {
let list = res.data.list || [];
that.presellOrderCount = res.data.count;