Commit ca529559 by 高淑倩

订单列表支付

parent 8c2da126
...@@ -145,13 +145,15 @@ wxService.page({ ...@@ -145,13 +145,15 @@ wxService.page({
}, },
// 立即支付 // 立即支付
handelToPay(e) { handelToPay(e) {
const { id } = e.currentTarget.dataset const { id, merged } = e.currentTarget.dataset
console.log('0000', id) console.log('0000', id, merged)
let url = merged ? `/sale/payment/merged/buyer/wxprepay/${id}` : `/sale/trade/buyer/wxprepay/${id}`
wx.showLoading({ wx.showLoading({
title: '加载中', title: '加载中',
mask: true mask: true
}) })
wxService.post(`/sale/trade/buyer/wxprepay/${id}`).then(res => { wxService.post(`${url}`).then(res => {
// wxService.post(`/sale/trade/buyer/wxprepay/${id}`).then(res => {
if (res) { if (res) {
const { result, data } = res.data const { result, data } = res.data
if (result == 0) { if (result == 0) {
......
...@@ -142,7 +142,7 @@ ...@@ -142,7 +142,7 @@
<button class="btn btn-sm btn-default" data-id="{{item.id}}" bindtap="handelDelOrder">删除订单</button> <button class="btn btn-sm btn-default" data-id="{{item.id}}" bindtap="handelDelOrder">删除订单</button>
</view> </view>
<view class="order-status" wx-if="{{item.status == 'N'}}"> <view class="order-status" wx-if="{{item.status == 'N'}}">
<button class="btn btn-sm btn-primary btn-outline" data-id="{{item.id}}" bindtap="handelToPay">立即支付</button> <button class="btn btn-sm btn-primary btn-outline" data-merged="{{item.mergedAmount}}" data-id="{{item.id}}" bindtap="handelToPay">立即支付</button>
</view> </view>
<view class="order-status" wx-if="{{item.status == 'P'}}"> <view class="order-status" wx-if="{{item.status == 'P'}}">
<button <button
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment