zhaojs
2023-06-09 573ba973d908841a65c21cd2c96049d5c0472be6
no message
已修改1个文件
46 ■■■■■ 文件已修改
public/html/freebuy.html 46 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
public/html/freebuy.html
@@ -358,10 +358,9 @@
                    data:{
                    }
                }).done(function(res){
                    alert(res);
                })
                $.ajax({
                    if(res.data=='首单客户')
                    {
                        $.ajax({
                    headers:{
                        "token":this.getUrlPar("token")
                    },
@@ -375,18 +374,35 @@
                        page: 1,
                        pageSize:20,
                    }
                }).done(function(res){
                    var newlist=[];
                    res.data.list.map(function(r,k){
                        var buprice=r.actualPrice-r.topFanli;
                        if(buprice<=3)
                        {
                            newlist.push(r);
                        }
                    })
                    _this.lists=[].concat(_this.lists,newlist);
                    _this.loading = false;
                      }).done(function(res){
                            var newlist=[];
                            res.data.list.map(function(r,k){
                                var buprice=r.actualPrice-r.topFanli;
                                if(buprice<=3)
                                {
                                    newlist.push(r);
                                }
                            })
                            _this.lists=[].concat(_this.lists,newlist);
                            _this.loading = false;
                     })
                    }
                    else{
                        alert("您已下过首单,不可再次购买,请浏览其他商品吧~");
                        setTimeout(function(){
                            if(this.isUniReady)
                            {
                                uni.postMessage({
                                data: {
                                    action: 'back'
                                }
                                });
                           }
                        }, 3000 )
                    }
                })
            },
        },
        mounted: function () {