第一次提交
This commit is contained in:
232
pages/order/order.js
Normal file
232
pages/order/order.js
Normal file
@@ -0,0 +1,232 @@
|
||||
//获取应用实例
|
||||
var app = getApp();
|
||||
Page({
|
||||
|
||||
/**
|
||||
* 页面的初始数据
|
||||
*/
|
||||
data: {
|
||||
order_list: [],
|
||||
nav_type: 1,
|
||||
all: true,
|
||||
height: '',
|
||||
url: app.globalData.url,
|
||||
|
||||
statusType: ["全部", "待付款", "未使用", "退款"],
|
||||
status: ["", "1", "2", "3"],
|
||||
currentType: 0,
|
||||
tabClass: ["", "", "", "", "", ""],
|
||||
pageNum: 1
|
||||
},
|
||||
statusTap: function (e) {
|
||||
var curType = e.currentTarget.dataset.index;
|
||||
this.setData({
|
||||
currentType: curType,
|
||||
pageNum: 1
|
||||
});
|
||||
|
||||
this.getOrderList();
|
||||
},
|
||||
onClickLeft() {
|
||||
wx.navigateBack()
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/
|
||||
onLoad: function (options) {
|
||||
var statusBarHeight = wx.getSystemInfoSync().statusBarHeight;
|
||||
app.console(statusBarHeight + "=================xxxxxxxxxxxxxxxxxxxxxxxx")
|
||||
this.setData({
|
||||
statusBarHeight: statusBarHeight,
|
||||
height: 46 + statusBarHeight,
|
||||
});
|
||||
app.console(this.data.height + "=================xxxxxxxxxxxxxxxxxxxxxxxx")
|
||||
},
|
||||
//条目点击
|
||||
itemclick(e) {
|
||||
// console.log(e.currentTarget.dataset.id)
|
||||
console.log(e.currentTarget.dataset.index)
|
||||
if (this.data.order_list[e.currentTarget.dataset.index].status == '已取消订单') {
|
||||
wx.navigateTo({
|
||||
url: '/pages/orderdetail/orderdetail?' + "type=" + '1' + '&id=' + this.data.order_list[e.currentTarget.dataset.index].order_id,
|
||||
})
|
||||
}
|
||||
|
||||
if (this.data.order_list[e.currentTarget.dataset.index].status == '待退款') {
|
||||
wx.navigateTo({
|
||||
url: '/pages/reforderdetail/reforderdetail?' + "type=" + '4' + '&id=' + e.currentTarget.dataset.id,
|
||||
})
|
||||
}
|
||||
|
||||
if (this.data.order_list[e.currentTarget.dataset.index].status == '退款驳回') {
|
||||
wx.navigateTo({
|
||||
url: '/pages/reforderdetail/reforderdetail?' + "type=" + '1' + '&id=' + e.currentTarget.dataset.id,
|
||||
})
|
||||
}
|
||||
|
||||
if (this.data.order_list[e.currentTarget.dataset.index].status == '已退款') {
|
||||
wx.navigateTo({
|
||||
url: '/pages/reforderdetail/reforderdetail?' + "type=" + '2' + '&id=' + e.currentTarget.dataset.id,
|
||||
})
|
||||
}
|
||||
|
||||
// wx.navigateTo({
|
||||
// url: '/pages/orderdetail/orderdetail?'+"type="+'1'+ '&id=' +e.currentTarget.dataset.id,
|
||||
// })
|
||||
|
||||
},
|
||||
//跳转订单详情(去付款)
|
||||
go_pay(e) {
|
||||
console.log(e.currentTarget.dataset.id)
|
||||
// wx.navigateTo({
|
||||
// url: '/pages/orderdetail/orderdetail?' + "type=" + '2' + '&id=' + e.currentTarget.dataset.id,
|
||||
// })
|
||||
|
||||
if (e.currentTarget.dataset.item != 0) {
|
||||
let item = JSON.stringify(e.currentTarget.dataset.item);
|
||||
console.log("传递的item" + item);
|
||||
wx.navigateTo({
|
||||
url: "/pages/orderdetail/orderdetail?item=" + item,
|
||||
});
|
||||
}
|
||||
},
|
||||
go_Qcode(e) {
|
||||
wx.navigateTo({
|
||||
url: '/pages/orderdetail/orderdetail?' + "type=" + '3' + '&id=' + e.currentTarget.dataset.id,
|
||||
})
|
||||
},
|
||||
// 导航栏
|
||||
all_order() {
|
||||
this.setData({
|
||||
nav_type: 1,
|
||||
all: true
|
||||
|
||||
})
|
||||
},
|
||||
payment_order() {
|
||||
this.setData({
|
||||
nav_type: 2,
|
||||
all: false
|
||||
})
|
||||
},
|
||||
use_order() {
|
||||
this.setData({
|
||||
nav_type: 3,
|
||||
all: false
|
||||
})
|
||||
},
|
||||
refund_order() {
|
||||
this.setData({
|
||||
nav_type: 4,
|
||||
all: false
|
||||
})
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {
|
||||
this.setData({
|
||||
order_list: [],
|
||||
pageNum: 1
|
||||
})
|
||||
this.getOrderList();
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
onHide: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面卸载
|
||||
*/
|
||||
onUnload: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面相关事件处理函数--监听用户下拉动作
|
||||
*/
|
||||
onPullDownRefresh: function () {
|
||||
//this.getOrderList();
|
||||
var that = this;
|
||||
wx.request({
|
||||
url: app.globalData.url + '/system/view/list',
|
||||
header: app.getRequestHeader(),
|
||||
method: 'GET',
|
||||
data: {
|
||||
pageNum: 1,
|
||||
pageSize: 30,
|
||||
status: that.data.status[that.data.currentType],
|
||||
usercId: 103
|
||||
},
|
||||
success: (res) => {
|
||||
var resp = res.data;
|
||||
if (res.data.code == 200) {
|
||||
that.setData({
|
||||
pageNum: 1,
|
||||
order_list: resp.data,
|
||||
});
|
||||
wx.stopPullDownRefresh({
|
||||
success: (res) => {},
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
/**
|
||||
* 页面上拉触底事件的处理函数
|
||||
*/
|
||||
onReachBottom: function () {
|
||||
console.log("=================dddddddddddddddddddddddddddddddddddddddddddd")
|
||||
this.getOrderList();
|
||||
},
|
||||
|
||||
/**
|
||||
* 用户点击右上角分享
|
||||
*/
|
||||
onShareAppMessage: function () {
|
||||
|
||||
},
|
||||
//订单状态:-2:已取消 -1:拒绝接单 0:待付款 1:已付款 2:已接单(待服务)3:服务中 4:已完成 5申请退款 6退款中 7已退款 8:已结算
|
||||
getOrderList: function () {
|
||||
var that = this;
|
||||
wx.request({
|
||||
url: app.globalData.url + '/system/view/list',
|
||||
header: app.getRequestHeader(),
|
||||
method: 'GET',
|
||||
data: {
|
||||
pageNum: 1,
|
||||
pageSize: 30,
|
||||
status: that.data.status[that.data.currentType],
|
||||
usercId: 103
|
||||
},
|
||||
success: (res) => {
|
||||
var resp = res.data;
|
||||
console.log(resp + "===========订单")
|
||||
if (res.data.code == 200) {
|
||||
if (this.data.pageNum == 1) {
|
||||
that.setData({
|
||||
order_list: resp.data,
|
||||
pageNum: this.data.pageNum + 1
|
||||
});
|
||||
|
||||
} else {
|
||||
that.setData({
|
||||
order_list: this.data.order_list.concat(resp.data),
|
||||
pageNum: this.data.pageNum + 1
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
})
|
||||
9
pages/order/order.json
Normal file
9
pages/order/order.json
Normal file
@@ -0,0 +1,9 @@
|
||||
{
|
||||
"usingComponents": {
|
||||
"van-nav-bar":"/miniprogram/miniprogram_npm/@vant/weapp/nav-bar/index"
|
||||
},
|
||||
"navigationBarTitleText": "我的订单",
|
||||
"enablePullDownRefresh": true,
|
||||
"backgroundTextStyle": "dark"
|
||||
|
||||
}
|
||||
59
pages/order/order.wxml
Normal file
59
pages/order/order.wxml
Normal file
@@ -0,0 +1,59 @@
|
||||
<van-nav-bar title="我的订单" left-text="" right-text="" bind:click-left="onClickLeft" bind:click-right="onClickRight" style=" position: fixed;left: 0;top: 0;width: 100%;z-index: 2;" />
|
||||
|
||||
<view class="status-box" style="margin-top: {{height}}px;">
|
||||
<view bindtap="statusTap" class="status-label {{index == currentType ? 'active' : ''}}" wx:for-items="{{statusType}}" wx:key="{{index}}" data-index="{{index}}">
|
||||
{{item}}
|
||||
<view class="{{tabClass[index]}}"></view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="no-order" style="margin-top: {{height}}px;" wx:if="{{!order_list.length}}">
|
||||
<image src="/images/no-order.png" class="no-order-img"></image>
|
||||
<view class="text">暂无订单</view>
|
||||
</view>
|
||||
<!-- 全部 -->
|
||||
<view wx:if="{{nav_type==1||all}}">
|
||||
|
||||
|
||||
|
||||
|
||||
<view class="order-list" wx:if="{{order_list.length}}">
|
||||
<view wx:for="{{order_list}}" data-index="{{index}}" data-id="{{item.id}}" wx:for-item="item" bindtap="itemclick" class="flex-item" style='display:flex;background-color: white;margin-bottom: 24rpx;'>
|
||||
|
||||
<view style=" padding: 0 24rpx;height:366rpx;position: relative;background: #ffffff;">
|
||||
<view style="height:66rpx;">
|
||||
<text class="time_msg">订单号:{{item.orderNumber}}</text>
|
||||
<!-- 订单状态:-2:已取消 -1:拒绝接单 0:待付款 1:已付款 2:已接单(待服务)
|
||||
3:服务中 4:已完成 5申请退款 6退款中 7已退款 8:已结算 -->
|
||||
<view wx:if="{{item.status==-2}}" class="status_msg">{{"已取消"}}</view>
|
||||
<view wx:if="{{item.status==-1}}" class="status_msg">{{"拒绝接单"}}</view>
|
||||
<view wx:if="{{item.status==0}}" class="status_msg">{{"待付款"}}</view>
|
||||
<view wx:if="{{item.status==1}}" class="status_msg">{{"已付款"}}</view>
|
||||
<view wx:if="{{item.status==2}}" class="status_msg">{{"待服务"}}</view>
|
||||
<view wx:if="{{item.status==3}}" class="status_msg">{{"服务中"}}</view>
|
||||
<view wx:if="{{item.status==4}}" class="status_msg">{{"已完成"}}</view>
|
||||
<view wx:if="{{item.status==5}}" class="status_msg">{{"申请退款"}}</view>
|
||||
<view wx:if="{{item.status==6}}" class="status_msg">{{"退款中"}}</view>
|
||||
<view wx:if="{{item.status==7}}" class="status_msg">{{"已退款"}}</view>
|
||||
<view wx:if="{{item.status==8}}" class="status_msg">{{"已结算"}}</view>
|
||||
</view>
|
||||
|
||||
<view style="height: 1rpx;background: #ECECEC;"></view>
|
||||
<view class="details_box">
|
||||
|
||||
<image src="{{url+item.userbAvatar}}" class="Group-image"></image>
|
||||
<view style="margin-left: 31rpx;margin-top: 40rpx;">
|
||||
<view class="title">{{item.userbName}}</view>
|
||||
<view class="detail_number">{{item.serviceTime}}天</view>
|
||||
<view class="money">实付款:<text style="font-size: 30rpx;color: #FF8F1F;font-family: PingFang SC;font-weight: bold;">¥{{item.yuguMoney}}元</text></view>
|
||||
</view>
|
||||
<view class="detail_btn" bindtap="go_pay" data-id="{{item.order_id}}" wx:if="{{item.status==0}}" data-item="{{item}}">去付款</view>
|
||||
|
||||
<view class="detail_btn" bindtap="go_Qcode" data-id="{{item.order_id}}" wx:if="{{item.status==1}}">查看二维码</view>
|
||||
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
194
pages/order/order.wxss
Normal file
194
pages/order/order.wxss
Normal file
@@ -0,0 +1,194 @@
|
||||
/* pages/order/order.wxss */
|
||||
page{
|
||||
background: #F5F5F5;
|
||||
}
|
||||
.nav_box {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
padding-left: 50rpx;
|
||||
padding-right: 50rpx;
|
||||
background: #ffffff;
|
||||
}
|
||||
|
||||
.nav_bar {
|
||||
width: 104rpx;
|
||||
height: 70rpx;
|
||||
line-height: 70rpx;
|
||||
text-align: center;
|
||||
font-size: 24rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 400;
|
||||
color: #5B5B5B;
|
||||
|
||||
}
|
||||
|
||||
.active {
|
||||
color: #5B5B5B;
|
||||
font-size: 28rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 800;
|
||||
border-bottom: 6rpx solid #FF6A6A;
|
||||
}
|
||||
.time_msg{
|
||||
font-size: 24rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 400;
|
||||
line-height: 66rpx;
|
||||
color: #5B5B5B;
|
||||
opacity: 1;
|
||||
float: left;
|
||||
}
|
||||
.status_msg{
|
||||
font-size: 24rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 400;
|
||||
line-height: 66rpx;
|
||||
color: #FF6A6A;
|
||||
opacity: 1;
|
||||
float: right;
|
||||
}
|
||||
.details_box{
|
||||
display: flex;
|
||||
}
|
||||
.title{
|
||||
width: 430rpx;
|
||||
font-size: 34rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: bold;
|
||||
line-height: 44rpx;
|
||||
color: #222222;
|
||||
opacity: 1;
|
||||
margin-top: 16rpx;
|
||||
overflow:hidden;
|
||||
text-overflow: ellipsis;
|
||||
display:-webkit-box;
|
||||
-webkit-line-clamp: 2;
|
||||
-webkit-box-orient: vertical;
|
||||
}
|
||||
.detail_number{
|
||||
font-size: 26rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 400;
|
||||
line-height: 37rpx;
|
||||
color: #666666;
|
||||
opacity: 1;
|
||||
margin-top: 16rpx;
|
||||
}
|
||||
.money{
|
||||
margin-top: 18rpx;
|
||||
font-size: 26rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 400;
|
||||
line-height: 37rpx;
|
||||
color: #B4B4B4;
|
||||
opacity: 1;
|
||||
|
||||
}
|
||||
.detail_btn{
|
||||
position: absolute;
|
||||
|
||||
bottom: 12rpx;
|
||||
right: 24rpx;
|
||||
/* min-width: 140rpx; */
|
||||
height: 57rpx;
|
||||
/* background: #000; */
|
||||
border: 1rpx solid #A5A5A5;
|
||||
border-radius: 34rpx;
|
||||
font-size: 26rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 400;
|
||||
line-height: 57rpx;
|
||||
color: #4A4A4A;
|
||||
opacity: 1;
|
||||
text-align: center;
|
||||
padding: 0 31rpx;
|
||||
}
|
||||
|
||||
.order-list{
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
|
||||
.status-box{
|
||||
height: 88rpx;
|
||||
line-height: 88rpx;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
background-color: #fff;
|
||||
padding-left: 50rpx;
|
||||
padding-right: 50rpx;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
}
|
||||
.status-box .status-label{
|
||||
width: 150rpx;
|
||||
height: 100%;
|
||||
text-align: center;
|
||||
font-size:24rpx;
|
||||
color:#353535;
|
||||
box-sizing: border-box;
|
||||
position: relative;
|
||||
}
|
||||
.status-box .status-label.active{
|
||||
|
||||
|
||||
color: #5B5B5B;
|
||||
font-size: 28rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 800;
|
||||
border-bottom: 6rpx solid #3D79FF;
|
||||
}
|
||||
.status-box .status-label .red-dot{
|
||||
width: 16rpx;
|
||||
height: 16rpx;
|
||||
position: absolute;
|
||||
left: 116rpx;
|
||||
top:23rpx;
|
||||
background-color: #f43530;
|
||||
border-radius: 50%;
|
||||
}
|
||||
|
||||
.no-order{
|
||||
width: 100%;
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
top: 88rpx;
|
||||
left: 0;
|
||||
right: 0;
|
||||
text-align: center;
|
||||
padding-top: 203rpx;
|
||||
background-color: #F2f2f2;
|
||||
}
|
||||
.no-order-img{
|
||||
width: 81rpx;
|
||||
height: 96rpx;
|
||||
margin-bottom: 31rpx;
|
||||
}
|
||||
.no-order .text{
|
||||
font-size:28rpx;
|
||||
color:#999999;
|
||||
text-align: center
|
||||
}
|
||||
|
||||
|
||||
.flex-item{
|
||||
display:flex;
|
||||
height: 364rpx;
|
||||
width: 670rpx;
|
||||
border-radius: 20rpx;
|
||||
margin-top: 26rpx;
|
||||
}
|
||||
|
||||
|
||||
.Group {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.Group-image {
|
||||
width: 128rpx;
|
||||
height: 128rpx;
|
||||
margin: 74rpx 40rpx 84rpx 40rpx;
|
||||
}
|
||||
|
||||
|
||||
190
pages/order/re_orderdetail.js
Normal file
190
pages/order/re_orderdetail.js
Normal file
@@ -0,0 +1,190 @@
|
||||
//获取应用实例
|
||||
var app = getApp();
|
||||
Page({
|
||||
|
||||
/**
|
||||
* 页面的初始数据
|
||||
*/
|
||||
data: {
|
||||
dingdan_msg:false,
|
||||
order_id:0,
|
||||
goods_id:'',
|
||||
type:'',
|
||||
fileListtwo: [],
|
||||
refund_remark:'',
|
||||
voucher_img:[]
|
||||
},
|
||||
|
||||
afterReadtwo(event) {
|
||||
var that = this;
|
||||
const { file } = event.detail;
|
||||
// 当设置 mutiple 为 true 时, file 为数组格式,否则为对象格式
|
||||
|
||||
wx.uploadFile({
|
||||
url: app.buildUrl("/app/Agentwechat/uploadImg"),
|
||||
filePath: file.url,
|
||||
name: 'file',
|
||||
formData: {
|
||||
uid:app.getCache('uid'),
|
||||
token:app.getCache('token'),
|
||||
file:file.url
|
||||
},
|
||||
|
||||
success: (res)=> {
|
||||
var resp = res.data;
|
||||
var rstObj = JSON.parse(resp); //字符串转为对象
|
||||
if(rstObj.erro==0){
|
||||
app.console(rstObj.file_path+'cccccccc')
|
||||
|
||||
// 上传完成需要更新 fileList
|
||||
const { fileListtwo = [] } = that.data;
|
||||
fileListtwo.push({ ...file, url: rstObj.file_path});
|
||||
that.setData({ fileListtwo });
|
||||
}else{
|
||||
wx.showToast({ title: rstObj.msg, icon: 'none' });
|
||||
return;
|
||||
}
|
||||
},
|
||||
});
|
||||
},
|
||||
deletetwo(event){
|
||||
app.console(event.detail.index+"================="+222),
|
||||
this.data.fileListtwo.splice([event.detail.index],1)
|
||||
this.setData({fileListtwo:this.data.fileListtwo});
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面加载
|
||||
*/
|
||||
onLoad: function (options) {
|
||||
console.log(options.type)
|
||||
console.log(options.id)
|
||||
if(options.type==2){
|
||||
this.setData({
|
||||
order_id:options.id,
|
||||
type:2
|
||||
})
|
||||
}
|
||||
if(options.type==3){
|
||||
this.setData({
|
||||
order_id:options.id,
|
||||
type:3
|
||||
})
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
|
||||
onClickLeft() {
|
||||
wx.navigateBack()
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面初次渲染完成
|
||||
*/
|
||||
onReady: function () {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {
|
||||
this.getRefundOrderDetail();
|
||||
},
|
||||
|
||||
//退款订单详情
|
||||
getRefundOrderDetail: function () {
|
||||
var that = this;
|
||||
wx.request({
|
||||
url: app.buildUrl("/app/Goddesswechat/getOrderDetail"),
|
||||
header: app.getRequestHeader(),
|
||||
method:'POST',
|
||||
data: {
|
||||
version_number: this.data.version_number,
|
||||
uid:wx.getStorageSync('uid'),
|
||||
token:wx.getStorageSync('token'),
|
||||
order_id:this.data.order_id
|
||||
},
|
||||
success: function (res) {
|
||||
var resp = res.data;
|
||||
if(resp.erro==0){
|
||||
that.setData({
|
||||
detail:resp.detail,
|
||||
order:resp.order,
|
||||
goods_id:resp.detail.goods_id,
|
||||
id:resp.detail.id,
|
||||
refund:resp.detail.refund,
|
||||
charge_phone:resp.detail.charge_phone
|
||||
|
||||
});
|
||||
|
||||
console.log("上传的图片路径================="+that.data.voucher_img)
|
||||
if(that.data.voucher_img.length>0){
|
||||
that.data.voucher_img.forEach(item => {
|
||||
app.console('长度=item================'+item)
|
||||
const { fileListtwo = [] } = that.data;
|
||||
fileListtwo.push({ url: item });
|
||||
that.setData({ fileListtwo });
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
tongyi(){
|
||||
this.handleRefundOrder()
|
||||
},
|
||||
jujue(){
|
||||
this.handleRefundOrderr()
|
||||
},
|
||||
//退款审核
|
||||
handleRefundOrder: function () {
|
||||
var that = this;
|
||||
wx.request({
|
||||
url: app.buildUrl("/app/Agentwechat/handleRefundOrder"),
|
||||
header: app.getRequestHeader(),
|
||||
method:'POST',
|
||||
data: {
|
||||
version_number: app.globalData.version_number,
|
||||
uid:wx.getStorageSync('uid'),
|
||||
token:wx.getStorageSync('token'),
|
||||
id:this.data.order_id,
|
||||
status:1,
|
||||
reject:''
|
||||
},
|
||||
success: function (res) {
|
||||
var resp = res.data;
|
||||
if(resp.erro==0){
|
||||
wx.showToast({ title: resp.msg, icon: 'none' });
|
||||
setTimeout(function () {
|
||||
//要延时执行的代码
|
||||
wx.navigateBack()
|
||||
}, 2000) //延迟时间 这里是2秒
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
//退款审核
|
||||
handleRefundOrderr: function () {
|
||||
var that = this;
|
||||
wx.request({
|
||||
url: app.buildUrl("/app/Agentwechat/handleRefundOrder"),
|
||||
header: app.getRequestHeader(),
|
||||
method:'POST',
|
||||
data: {
|
||||
version_number: this.data.version_number,
|
||||
uid:wx.getStorageSync('uid'),
|
||||
token:wx.getStorageSync('token'),
|
||||
id:this.data.order_id,
|
||||
status:2,
|
||||
reject:''
|
||||
},
|
||||
success: function (res) {
|
||||
var resp = res.data;
|
||||
if(resp.erro==0){
|
||||
wx.showToast({ title: resp.msg, icon: 'none' });
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
})
|
||||
7
pages/order/re_orderdetail.json
Normal file
7
pages/order/re_orderdetail.json
Normal file
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"usingComponents": {
|
||||
"van-nav-bar":"/miniprogram/miniprogram_npm/@vant/weapp/nav-bar/index",
|
||||
"van-uploader": "/miniprogram/miniprogram_npm/@vant/weapp/uploader/index"
|
||||
},
|
||||
"navigationBarTitleText": "订单详情"
|
||||
}
|
||||
96
pages/order/re_orderdetail.wxml
Normal file
96
pages/order/re_orderdetail.wxml
Normal file
@@ -0,0 +1,96 @@
|
||||
|
||||
<view style=" height:340rpx;position: relative;background: #ffffff;margin-top:8rpx;">
|
||||
<view style="height:66rpx;padding: 0 24rpx;">
|
||||
<text class="time_msg"></text>
|
||||
<text wx:if="{{refund_infro.status==0}}" class="status_msg">待退款</text>
|
||||
<text wx:if="{{refund_infro.status==1}}" class="status_msg">退款成功</text>
|
||||
<text wx:if="{{refund_infro.status==2}}" class="status_msg">申请驳回</text>
|
||||
</view>
|
||||
<view class="details_box">
|
||||
<image src="{{detail.index_img}}" style="width:230rpx;height:230rpx;"></image>
|
||||
<view style="margin-left: 31rpx;">
|
||||
<view class="title">{{detail.goods_name}}</view>
|
||||
<view class="detail_number">数量x{{detail.num}}</view>
|
||||
<view class="money">实付款:<text
|
||||
style="font-size: 30rpx;color: #FF4A4A;font-family: PingFang SC;font-weight: bold;">¥{{detail.total_money}}</text></view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
||||
<view class="information">
|
||||
<view class="contact_title" style="font-size: 30rpx;font-weight: bold;line-height: 36rpx;color: #333333;">
|
||||
订单信息
|
||||
</view>
|
||||
<view style="margin-bottom: 30rpx;">
|
||||
<text class="information_title">订单合计</text>
|
||||
<text class="information_title" style="color:#FF4A4A;">¥{{order.total_money}}</text>
|
||||
</view>
|
||||
<view style="margin-bottom: 30rpx;">
|
||||
<text class="information_title">商品数量</text>
|
||||
<text class="information_title">{{order.num}}</text>
|
||||
</view>
|
||||
<view style="margin-bottom: 30rpx;">
|
||||
<text class="information_title">订单时间</text>
|
||||
<text class="information_title">{{order.time}}</text>
|
||||
</view>
|
||||
<view style="margin-bottom: 30rpx;">
|
||||
<text class="information_title">订单编号</text>
|
||||
<text class="information_title" style="width: 100%; margin-right: 0rpx;">{{order.order_id}}</text>
|
||||
</view>
|
||||
<view style="margin-bottom: 30rpx;">
|
||||
<text class="information_title">手机号码</text>
|
||||
<text class="information_title">{{order.phone}}</text>
|
||||
</view>
|
||||
<view style="margin-bottom: 30rpx;">
|
||||
<text class="information_title">付款时间</text>
|
||||
<text class="information_title">{{order.time}}</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<view wx:if="{{type==3}}" class="informationtwo">
|
||||
<view class="contact_title" style="font-size: 30rpx;font-weight: bold;line-height: 36rpx;color: #333333;">
|
||||
退款信息
|
||||
</view>
|
||||
|
||||
<view style="margin-bottom: 30rpx; border-bottom: 1rpx solid #eee;">
|
||||
<text class="information_title">退款原因:</text>
|
||||
<text class="information_title">{{refund_infro.refund_reason}}</text>
|
||||
</view>
|
||||
|
||||
<view style="margin-bottom: 0rpx;">
|
||||
<text class="information_title">退款金额:</text>
|
||||
<text class="information_title" style="color:#FF4A4A;">¥{{refund_infro.refund_money}}</text>
|
||||
</view>
|
||||
<view style="margin-bottom: 30rpx; border-bottom: 1rpx solid #eee;">
|
||||
<text class="information_title" style="font-size: 20rpx;">不可修改,最多¥99</text>
|
||||
</view>
|
||||
|
||||
<view style="margin-bottom: 30rpx;">
|
||||
<text class="information_title">退款说明:</text>
|
||||
<text class="information_title">选填</text>
|
||||
</view>
|
||||
|
||||
<view class="peisong-way" style="margin-bottom: 30rpx;">
|
||||
<input style="font-size: 26rpx;padding-left: 19rpx;padding-top: 19rpxx;" model:value="{{refund_remark}}" bindinput="passwordInput" placeholder="填写补充说明,有利于您的售后哦~"/>
|
||||
</view>
|
||||
|
||||
|
||||
<view style="margin-bottom: 30rpx;">
|
||||
<text class="information_title">上传凭证</text>
|
||||
</view>
|
||||
<view class="row-box">
|
||||
<van-uploader file-list="{{fileListtwo}}"max-count="3" deletable="{{ true }}" bind:after-read="afterReadtwo" bind:delete="deletetwo"/>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<view wx:if="{{type==3&&refund_infro.status==0}}" class="addperson" bindtap="addperson" style="margin-top: 77rpx;">
|
||||
<view class="text" style="background-color:#ffffff;color: #FF4C00;border: 1px solid #FF4C00;"bindtap="jujue">拒绝退款</view>
|
||||
<view class="text" style="background-color: #FF4C00;"bindtap="tongyi">同意退款</view>
|
||||
</view>
|
||||
248
pages/order/re_orderdetail.wxss
Normal file
248
pages/order/re_orderdetail.wxss
Normal file
@@ -0,0 +1,248 @@
|
||||
/* pages/orderdetail/orderdetail.wxss */
|
||||
page {
|
||||
background: #e5e5e5;
|
||||
}
|
||||
|
||||
.time_msg {
|
||||
font-size: 24rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 400;
|
||||
line-height: 66rpx;
|
||||
color: #5B5B5B;
|
||||
opacity: 1;
|
||||
float: left;
|
||||
}
|
||||
|
||||
.status_msg {
|
||||
font-size: 24rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 400;
|
||||
line-height: 66rpx;
|
||||
color: #FF6A6A;
|
||||
opacity: 1;
|
||||
float: right;
|
||||
}
|
||||
|
||||
.details_box {
|
||||
display: flex;
|
||||
padding: 0 24rpx;
|
||||
padding-bottom: 32rpx;
|
||||
}
|
||||
|
||||
.title {
|
||||
width: 430rpx;
|
||||
height: 86rpx;
|
||||
font-size: 30rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: bold;
|
||||
line-height: 44rpx;
|
||||
color: #222222;
|
||||
opacity: 1;
|
||||
margin-top: 16rpx;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
display: -webkit-box;
|
||||
-webkit-line-clamp: 2;
|
||||
-webkit-box-orient: vertical;
|
||||
}
|
||||
|
||||
.detail_number {
|
||||
font-size: 26rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 400;
|
||||
line-height: 37rpx;
|
||||
color: #B4B4B4;
|
||||
opacity: 1;
|
||||
margin-top: 11rpx;
|
||||
}
|
||||
|
||||
.money {
|
||||
margin-top: 18rpx;
|
||||
font-size: 26rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 400;
|
||||
line-height: 37rpx;
|
||||
color: #B4B4B4;
|
||||
opacity: 1;
|
||||
|
||||
}
|
||||
|
||||
.detail_btn {
|
||||
margin-top: 20rpx;
|
||||
margin-right: 30rpx;
|
||||
float: right;
|
||||
/* position: absolute; */
|
||||
|
||||
/* bottom: 22rpx;
|
||||
right: 24rpx; */
|
||||
/* min-width: 140rpx; */
|
||||
height: 57rpx;
|
||||
/* background: #000; */
|
||||
border: 1rpx solid #FF4A4A;
|
||||
border-radius: 34rpx;
|
||||
font-size: 26rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 400;
|
||||
line-height: 57rpx;
|
||||
color: #FF4A4A;
|
||||
opacity: 1;
|
||||
text-align: center;
|
||||
/* padding: 0 31rpx; */
|
||||
}
|
||||
|
||||
.contact {
|
||||
height: 167rpx;
|
||||
background: #fff;
|
||||
margin-top: 8rpx;
|
||||
padding: 0 24rpx;
|
||||
}
|
||||
|
||||
.contact_title {
|
||||
font-size: 30rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 500;
|
||||
color: #333333;
|
||||
opacity: 1;
|
||||
position: relative;
|
||||
top: 13rpx;
|
||||
margin-bottom:36rpx;
|
||||
|
||||
}
|
||||
|
||||
.information {
|
||||
background: #fff;
|
||||
height: 539rpx;
|
||||
margin-top: 8rpx;
|
||||
padding: 0 24rpx;
|
||||
}
|
||||
|
||||
.informationtwo {
|
||||
background: #fff;
|
||||
height: 939rpx;
|
||||
margin-top: 8rpx;
|
||||
padding: 0 24rpx;
|
||||
}
|
||||
|
||||
.information_title {
|
||||
font-size: 26rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 400;
|
||||
color: #686868;
|
||||
opacity: 1;
|
||||
margin-right: 71rpx;
|
||||
|
||||
}
|
||||
|
||||
.mengceng {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
background: #000;
|
||||
opacity: 0.7;
|
||||
}
|
||||
|
||||
.qxdd {
|
||||
position: fixed;
|
||||
left: 95rpx;
|
||||
bottom: 50%;
|
||||
width: 560rpx;
|
||||
height: 247rpx;
|
||||
background: #fff;
|
||||
border-radius: 20rpx;
|
||||
|
||||
}
|
||||
|
||||
.msg_btn {
|
||||
width: 50%;
|
||||
line-height: 85rpx;
|
||||
text-align: center;
|
||||
font-size: 26rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 500;
|
||||
color: #4A4A4A;
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.msg_title {
|
||||
height: 161rpx;
|
||||
line-height: 161rpx;
|
||||
text-align: center;
|
||||
font-size: 28rpx;
|
||||
color: #4A4A4A;
|
||||
font-family: PingFang SC;
|
||||
font-weight: 500;
|
||||
border-bottom: 1px solid #EBEBEB;
|
||||
}
|
||||
|
||||
.erweima_tanchang {
|
||||
position: fixed;
|
||||
left: 95rpx;
|
||||
bottom: 40%;
|
||||
width: 560rpx;
|
||||
height: 446rpx;
|
||||
background: #fff;
|
||||
border-radius: 20rpx;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.refund_box {
|
||||
position: fixed;
|
||||
background: #fff;
|
||||
bottom: 0;
|
||||
width: 100%;
|
||||
border-radius: 40rpx 40rpx 0px 0px;
|
||||
/* text-align: center; */
|
||||
}
|
||||
|
||||
.gang {
|
||||
width: 102rpx;
|
||||
height: 8rpx;
|
||||
background: #CCCCCC;
|
||||
border-radius: 103rpx;
|
||||
margin: 0 auto;
|
||||
margin-top: 23rpx;
|
||||
margin-bottom: 15rpx;
|
||||
}
|
||||
|
||||
.refund_title {
|
||||
font-size: 34rpx;
|
||||
font-family: PingFang SC;
|
||||
font-weight: bold;
|
||||
line-height: 48rpx;
|
||||
color: #2D2D2F;
|
||||
opacity: 1;
|
||||
margin-bottom: 5rpx;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.list_box {
|
||||
margin: 0 41rpx 0 25rpx;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
height: 102rpx;
|
||||
line-height: 102rpx;
|
||||
border-bottom: 1rpx solid #E8E8E8;
|
||||
}
|
||||
|
||||
|
||||
.peisong-way{
|
||||
width: 695rpx;
|
||||
height: 228rpx;
|
||||
background: #F6F6F6;
|
||||
margin-right: 31rpx;
|
||||
opacity: 1;
|
||||
border-radius: 0px
|
||||
}
|
||||
|
||||
|
||||
.addperson{
|
||||
width: 100%;height: 100rpx;opacity: 1;display: flex; align-items: center; justify-content: center;
|
||||
}
|
||||
|
||||
.text{
|
||||
font-size: 28rpx;font-family: PingFang SC;color: #FFFFFF;
|
||||
opacity: 1;width: 50%;display:flex;justify-content: center; align-items: center;
|
||||
height: 100rpx;
|
||||
}
|
||||
Reference in New Issue
Block a user