|
@@ -32,7 +32,6 @@ import { applyWxPay,getDetail } from "@/api/ljh";
|
|
|
import { mapGetters } from "vuex";
|
|
import { mapGetters } from "vuex";
|
|
|
import wexinPay from "@/utils/pay/wxPay";
|
|
import wexinPay from "@/utils/pay/wxPay";
|
|
|
import { postWxCode } from '@/api/mini'
|
|
import { postWxCode } from '@/api/mini'
|
|
|
-import { updateMiniOpenId } from '@/api/admin'
|
|
|
|
|
export default {
|
|
export default {
|
|
|
name: "confirmPay",
|
|
name: "confirmPay",
|
|
|
components: {
|
|
components: {
|
|
@@ -82,14 +81,24 @@ export default {
|
|
|
uni.setStorageSync('code', res.code)
|
|
uni.setStorageSync('code', res.code)
|
|
|
postWxCode({ code: res.code }).then(subRes => {
|
|
postWxCode({ code: res.code }).then(subRes => {
|
|
|
if(subRes.data.currentMiniOpenId){
|
|
if(subRes.data.currentMiniOpenId){
|
|
|
- let currentMiniOpenId = subRes.data.currentMiniOpenId
|
|
|
|
|
- updateMiniOpenId({miniOpenId:currentMiniOpenId}).then(subRes=>{
|
|
|
|
|
|
|
+ let currentMiniOpenId = subRes.data.currentMiniOpenId
|
|
|
|
|
+ uni.setStorageSync('currentMiniOpenId', currentMiniOpenId)
|
|
|
if(subRes.code == 1){
|
|
if(subRes.code == 1){
|
|
|
that.$util.confirmModal({content:'网络开小差了,请继续',okText:'确认',singer:true},() => {
|
|
that.$util.confirmModal({content:'网络开小差了,请继续',okText:'确认',singer:true},() => {
|
|
|
that.wxPayFn()
|
|
that.wxPayFn()
|
|
|
})
|
|
})
|
|
|
}
|
|
}
|
|
|
|
|
+ }else{
|
|
|
|
|
+
|
|
|
|
|
+ that.$util.confirmModal({content:'出错了,请添加客服微信反馈',okText:'复制微信'},() => {
|
|
|
|
|
+ uni.setClipboardData({
|
|
|
|
|
+ data: '15280215347',
|
|
|
|
|
+ success: function() {
|
|
|
|
|
+ that.$msg("复制成功")
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
})
|
|
})
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
}
|
|
}
|