feat(weapp): 增加小程序发货页面
This commit is contained in:
@@ -841,6 +841,15 @@
|
|||||||
"navigationStyle": "custom"
|
"navigationStyle": "custom"
|
||||||
// #endif
|
// #endif
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"path": "weapp/order_shipping",
|
||||||
|
"style": {
|
||||||
|
// #ifdef APP-PLUS
|
||||||
|
"navigationStyle": "custom",
|
||||||
|
// #endif
|
||||||
|
"navigationBarTitleText": "小程序发货"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
48
pages_tool/weapp/order_shipping.vue
Normal file
48
pages_tool/weapp/order_shipping.vue
Normal file
@@ -0,0 +1,48 @@
|
|||||||
|
<template>
|
||||||
|
<view>
|
||||||
|
<view class="error-msg">{{errorMsg}}</view>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
outTradeNo:'',
|
||||||
|
errorMsg:'',
|
||||||
|
}
|
||||||
|
},
|
||||||
|
onLoad(option) {
|
||||||
|
if (option.merchant_trade_no){
|
||||||
|
this.outTradeNo = option.merchant_trade_no;
|
||||||
|
this.getOrderDetailPath();
|
||||||
|
}else{
|
||||||
|
this.errorMsg = '缺少merchant_trade_no参数';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
getOrderDetailPath(){
|
||||||
|
this.$api.sendRequest({
|
||||||
|
url: '/api/pay/outTradeNoToOrderDetailPath',
|
||||||
|
data:{
|
||||||
|
out_trade_no : this.outTradeNo,
|
||||||
|
},
|
||||||
|
success: res => {
|
||||||
|
if (res.code < 0) {
|
||||||
|
this.errorMsg = res.message || '未知错误';
|
||||||
|
}else{
|
||||||
|
this.$util.redirectTo(res.data);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style>
|
||||||
|
.error-msg{
|
||||||
|
text-align: center;
|
||||||
|
padding-top: 10vh;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
Reference in New Issue
Block a user