Commit b6035a44 by zhangzhen

细节优化

parent 292a4643
......@@ -11,9 +11,9 @@ export const getUseCoupon=(data)=>{
return http.post(url,data)
}
export const couponChecked=(code)=>{
let url=`/chessCards/consumeByUser?code=`+code
return http.get(url)
export const couponChecked=(data)=>{
let url=`/chessCards/consumeByUser`
return http.get(url,data)
}
......
......@@ -14,7 +14,7 @@
</view>
<view class="input-box">
<view class="cu-form-group">
<input type="number" class="input" placeholder="点击输入卡券兑换码" v-model="code"></input>
<input placeholder="点击输入卡券兑换码" name="input" v-model="code"></input>
<text class="cuIcon-qr_code text-gray text-xxl" @tap="onScanCode"></text>
</view>
</view>
......@@ -70,6 +70,7 @@
return {
assetsPath:config.assetsPath,
code:"",
openShopUuid:'',
list:[
{
iconUrl:config.assetsPath+'/mt_icon.png',
......@@ -85,7 +86,10 @@
return moment(val).format("YYYY-MM-DD HH:mm:ss")
}
},
onLoad() {
onLoad(option) {
if(option.openShopUuid){
this.openShopUuid = option.openShopUuid
}
this.eventChannel = this.getOpenerEventChannel();
},
......@@ -101,7 +105,10 @@
uni.showLoading({
title:"券码核验中"
})
couponChecked(this.code).then(res=>{
couponChecked({
code:this.code,
openShopUuid:this.openShopUuid
}).then(res=>{
console.log(res,909090)
if(res.data.code === 200){
this.couponInfo = res.data.data
......
......@@ -750,7 +750,7 @@
},
onNavToCheckedCoupon(){
uni.navigateTo({
url:"/pages/couponCheck/couponCheck",
url:"/pages/couponCheck/couponCheck?openShopUuid="+this.roomInfo.openShopUuid,
events: {
// 为指定事件添加一个监听器,获取被打开页面传送到当前页面的数据
acceptData(data){
......
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