水滴兑换模块开发完成
This commit is contained in:
@@ -13,7 +13,8 @@ Page({
|
||||
address : '', // 地址
|
||||
addressId : '', // 地址id
|
||||
dataShow : '', // 数据
|
||||
exchangesHide: false
|
||||
exchangesHide: false,
|
||||
disabled : false
|
||||
},
|
||||
|
||||
/**
|
||||
@@ -56,6 +57,9 @@ Page({
|
||||
* 水滴兑换提交
|
||||
*/
|
||||
createGo (){
|
||||
this.setData({
|
||||
disabled: true
|
||||
})
|
||||
wx.showModal({
|
||||
title : '兑换提示',
|
||||
content : '尊敬的用户,是否确认兑换此商品',
|
||||
@@ -65,9 +69,18 @@ Page({
|
||||
if (res.confirm) {
|
||||
wx.$api.recruit.exchangesPost({address_id: this.data.addressId}).then(res => {
|
||||
this.setData({
|
||||
disabled: false,
|
||||
exchangesHide: true
|
||||
})
|
||||
}).catch(err => { })
|
||||
}).catch(err => {
|
||||
this.setData({
|
||||
disabled: false
|
||||
})
|
||||
})
|
||||
} else {
|
||||
this.setData({
|
||||
disabled: false
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user