1.修改领券 不需登录

yj-dev
杨杰 3 years ago
parent b332a97a1a
commit da4aa71c23
  1. 16
      App.vue
  2. 27
      pages/goods/externalCoupon/externalCoupon.vue

@ -5,15 +5,15 @@
// brestUrl: 'http://192.168.3.4:9302/brest', // brestUrl: 'http://192.168.3.4:9302/brest',
// imgUrl: 'https://192.168.3.4:9301/filesystem/', // imgUrl: 'https://192.168.3.4:9301/filesystem/',
// //
// url: 'https://hsg.dctpay.com/crest', url: 'https://hsg.dctpay.com/crest',
// imgUrl: 'https://hsg.dctpay.com/filesystem/', imgUrl: 'https://hsg.dctpay.com/filesystem/',
// brestUrl : 'https://hsg.dctpay.com/brest', brestUrl : 'https://hsg.dctpay.com/brest',
// imageWxImg:'https://hsg.dctpay.com/filesystem/wxApplets/', imageWxImg:'https://hsg.dctpay.com/filesystem/wxApplets/',
// //
url: 'https://hsgcs.dctpay.com/crest', // url: 'https://hsgcs.dctpay.com/crest',
brestUrl : 'https://hsgcs.dctpay.com/brest', // brestUrl : 'https://hsgcs.dctpay.com/brest',
imgUrl: 'https://hsgcs.dctpay.com/filesystem/', // imgUrl: 'https://hsgcs.dctpay.com/filesystem/',
imageWxImg:'https://hsgcs.dctpay.com/filesystem/wxApplets/', // imageWxImg:'https://hsgcs.dctpay.com/filesystem/wxApplets/',
userInfo: "", userInfo: "",
brestUserInfo : '', brestUserInfo : '',
openId: '', openId: '',

@ -64,12 +64,8 @@
getH5AccessToken, getH5AccessToken,
loginByPhone loginByPhone
} from '../../../Utils/Api.js'; } from '../../../Utils/Api.js';
// import authorize from '../../../components/Authorize';
let app = getApp(); let app = getApp();
export default { export default {
// components: {
// authorize
// },
data() { data() {
return { return {
minecoupones: [], minecoupones: [],
@ -104,11 +100,22 @@
} }
}, },
onShow() { onShow() {
if (app.globalData.userInfo.phone) { uni.getStorage({
this.userInfo = 2; key: 'user',
} else { success: (res) => {
this.userInfo = 1; app.globalData.userInfo = res.data;
} if (app.globalData.userInfo.phone) {
this.userInfo = 2;
} else {
this.userInfo = 1;
}
},
fail() {
this.userInfo = 1;
}
});
}, },
onLoad() { onLoad() {
var arr1 = window.location.href; var arr1 = window.location.href;
@ -128,7 +135,7 @@
code: res.data code: res.data
} }
getDiscountByQrCode(params).then(res => { getDiscountByQrCode(params).then(res => {
if (res.return_code == '000000') { if (res.return_code == '000000') {
that.couponsDetails = res.return_data; that.couponsDetails = res.return_data;
that.salesEndTime = res.return_data.highDiscount.salesEndTime; that.salesEndTime = res.return_data.highDiscount.salesEndTime;
that.getCouponByDiscount(res.return_data.highDiscount.id); that.getCouponByDiscount(res.return_data.highDiscount.id);

Loading…
Cancel
Save