Sfoglia il codice sorgente

Wesmiler 时光单身NN2019120501项目迁移

wesmiler 5 anni fa
parent
commit
1a05df1af4

+ 8 - 0
public/themes/default/weixin/public/assets/js/market-invite.js

@@ -52,6 +52,14 @@ var app = new Vue({
             $.post('/api/market/getInfo', {type: 2, id: sid}, function (res) {
             $.post('/api/market/getInfo', {type: 2, id: sid}, function (res) {
                 $.hideLoading();
                 $.hideLoading();
                 if (res.code == 'success') {
                 if (res.code == 'success') {
+                    if(res.data.id<=0){
+                        $.showLoading('参数错误,用户不存在', 'text');
+                        setTimeout(function () {
+                            location.href = '/weixin/market/index';
+                        }, 1000)
+                        return false;
+                    }
+
                     _this.memberInfo = res.data
                     _this.memberInfo = res.data
                     _this.memberInfo.qrcode = _this.memberInfo.qrcode? _this.memberInfo.qrcode : '/themes/default/weixin/public/assets/img/qrcode.jpg'
                     _this.memberInfo.qrcode = _this.memberInfo.qrcode? _this.memberInfo.qrcode : '/themes/default/weixin/public/assets/img/qrcode.jpg'
                     _this.initShare()
                     _this.initShare()