|
|
@ -223,27 +223,30 @@ import UniIcons from "../../uni_modules/uni-icons/components/uni-icons/uni-icons |
|
|
placeholderText:'请输入兑换cdk', |
|
|
placeholderText:'请输入兑换cdk', |
|
|
success(response) { |
|
|
success(response) { |
|
|
console.log('response',response); |
|
|
console.log('response',response); |
|
|
//调用使用cdk方法 |
|
|
if(response.confirm){ |
|
|
const data = { |
|
|
//点击确定 |
|
|
cdk: response.content, |
|
|
//调用使用cdk方法 |
|
|
userId: that.userInfo.id, |
|
|
const data = { |
|
|
source: '1', |
|
|
cdk: response.content, |
|
|
appType: '0' |
|
|
userId: that.userInfo.id, |
|
|
} |
|
|
source: '1', |
|
|
useCdk(data).then(res =>{ |
|
|
appType: '0' |
|
|
console.log('res',res); |
|
|
|
|
|
if(res.data.code != 200){ |
|
|
|
|
|
uni.showToast({ |
|
|
|
|
|
title: res.data.msg, |
|
|
|
|
|
icon: 'none' |
|
|
|
|
|
}) |
|
|
|
|
|
}else{ |
|
|
|
|
|
uni.showToast({ |
|
|
|
|
|
title: '兑换成功!', |
|
|
|
|
|
icon: 'none' |
|
|
|
|
|
}) |
|
|
|
|
|
} |
|
|
} |
|
|
}) |
|
|
useCdk(data).then(res =>{ |
|
|
|
|
|
console.log('res',res); |
|
|
|
|
|
if(res.data.code != 200){ |
|
|
|
|
|
uni.showToast({ |
|
|
|
|
|
title: res.data.msg, |
|
|
|
|
|
icon: 'none' |
|
|
|
|
|
}) |
|
|
|
|
|
}else{ |
|
|
|
|
|
uni.showToast({ |
|
|
|
|
|
title: '兑换成功!', |
|
|
|
|
|
icon: 'none' |
|
|
|
|
|
}) |
|
|
|
|
|
} |
|
|
|
|
|
}); |
|
|
|
|
|
} |
|
|
}, |
|
|
}, |
|
|
fail(res) { |
|
|
fail(res) { |
|
|
uni.showToast({ |
|
|
uni.showToast({ |
|
|
|