zhaojs
2023-07-18 218ebcd2b3a4a4eb15250b5a15bed9bfbcfca3ca
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
<!DOCTYPE html>
<html>
 
<head>
    <meta charset="UTF-8"><meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="App-Config" content="fullscreen=yes,useHistoryState=yes,transition=yes">
    <meta content="yes" name="apple-mobile-web-app-capable"><meta content="yes" name="apple-touch-fullscreen">
    <meta content="telephone=no,email=no" name="format-detection">
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no,viewport-fit=cover">
    <script type="text/javascript" src="https://public.ffquan.cn/lib/jquery-1.12.4.min.js"></script>
    <script type="text/javascript" src="https://public.ffquan.cn/lib/vue-lazyload.js"></script>
    <script type="text/javascript" src="https://public.ffquan.cn/lib/swiper/js/swiper.min.js"></script>
    <script type="text/javascript" src="https://public.ffquan.cn/lib/taobaoCode/taobaoCode.js?v=1.2.1"></script>
    <script type="text/javascript" src="https://public.ffquan.cn/lib/clipboard.min.js"></script>
    <script type="text/javascript" src="https://p1static.dataoke.com/web/js/layer/layer.js?t=202104191256"></script>
    <script type="text/javascript" src="https://img.ushopvip.com/js/uni-webview-js.js"></script>
    <title>邀粉领现金</title>
    
    <style>
   .com_img{
        width:100%;
     }
     .act_po
     {
        position: relative;
     }
     .top_time
     {
        position: absolute;
        color: #91261E;
        width: 100%;
        height: 20px;
        font-size: 0.1rem;
        text-align: center;
        bottom: 0.1rem;
     }
     .mid_count
     {
        position: absolute;
        color: #91261E;
        width: 100%;
        height: 20px;
        font-size: 0.3rem;
        text-align: center;
        bottom: 0.8rem;
        font-weight: 600;
     }
     .top_txt{
        position: absolute;
        color: #91261E;
        width: 100%;
        height: 20px;
        font-size: 0.3rem;
        text-align: center;
        font-weight: 600;
     }
     .ph_cont
     {
        position: absolute;
        display: flex;
        flex-direction: column;
        width: 100%;
        top: 1.4rem;
        justify-content: center;
        font-size: 12px;
        align-items: center;
     }
 
 
     .tbl {
        height: 0.7rem;
        display: flex;
        }
        .cell {
            color: #4D2F08;
    font-weight: 700;
            width: 1%;
            height: 100%;
            flex-grow: 1;
            display: flex;
            /*水平居中、垂直居中*/
            justify-content: center;
            align-items: center;
            /*换行*/
            word-break: break-all;
            word-wrap: break-word;
            white-space: normal;
        }
        .tbl div:last-child {
            border-right: 0;
        }
        .gz_txt
        {
            position: absolute;
            font-size: 12px;
            top: 4.3rem;
            width: 73%;
            font-size: 0.2rem;
            font-weight: 500;
        }
        .shadow {
                position: fixed;
                top: 0;
                height: 100vh;
                width: 100%;
                display: flex;
                justify-content: center;
                align-items: center;
                background-color: rgba(0, 0, 255, 0.3)
            }
            .popup {
                margin: 0 auto;
                height: 6rem;
                width: 6rem;
                background: #FFFF;
                border-radius: .3rem;
                overflow: overlay;
            }
           
            .popupCongratulate {
                text-align: center;
                font-size: .30rem;
                font-weight: bold;
            }
            .popupSon {
                margin: 0 auto;
                font-size: .2rem;
                text-align: center;
                padding: 0.1rem;
                text-align: left;
            }
            .popclose
            {
                width: 5.7rem;
                text-align: right;
                font-size: 12px;
                padding-top: 0.1rem;
                font-size: 0.3rem;
                font-weight: 800;
                position: fixed;
            }
            .gzbtn
            {
                position: absolute;
                font-size: 0.25rem;
                border-radius: 0.2rem;
                top: 0.65rem;
                right: 0.4rem;
                width: 1.3rem;
                text-align: center;
                font-weight: 600;
                background: #664b4ba6;
                color: #fff;
                padding: 0.04rem;
            }
    .btngo
    {
        position: fixed;
        width: 100%;
        bottom: 1px;
        text-align: center;
    }
    .loading{
        display: flex;
        position: fixed;
        width: 100vw;
        height: 100vh;
        background: rgb(0 0 0 / 67%);
        top: 0;
        left: 0;
        z-index: 10;
        justify-content: center;
        align-items: center;
        font-size: .35rem;
        color: #fff;
        }
        .appback-img
{
    position: absolute;
    top: 0.6rem;
    z-index: 999;
    width: 0.6rem;
    left: 0.3rem;
}
 
.box
        {
            position:absolute;
            width: 100%;
            height: 100%;
            background: url(https://yanfeiobpub.obs.cn-east-3.myhuaweicloud.com/dfg/h5loading.gif) no-repeat fixed top;
            background-size: 70px 70px;
        }
        .list{
            position: relative;
            top: 0;
            width: 100%;
        }
    </style>
</head>
 
<body style="background: #f5f5f9; margin: 0px;font-size: 0;">
    <div class="box">
        <div class="list">
    <div id="inviteact">
        <div v-if="loading" class="loading">{{loadingTxt}}</div>
        <image v-on:click="topBack()" class="appback-img" src="https://yanfeiobpub.obs.cn-east-3.myhuaweicloud.com/dfg/h5return_backIcon.png"></image>
        <div class="act_po">
            <div class="gzbtn" v-on:click="showgz()">活动规则</div>
            <image class="com_img" src="https://yanfeiobpub.obs.cn-east-3.myhuaweicloud.com/dfg/act_invite_230717_01.png"></image>
            <div class="top_time">
                2023年8月1日9:00-2023年8月31日23:59:59
            </div>
        </div>
        <div class="act_po">
            <div class="top_txt">已邀请的人数{{joinInfo.membercount}}</div>
            <image class="com_img" src="https://yanfeiobpub.obs.cn-east-3.myhuaweicloud.com/dfg/act_invite_230717_02.png"></image>
            <div class="mid_count">
                当前已解锁的红包金额:{{joinInfo.award}}
            </div>
        </div>
        <div class="act_po">
            <image class="com_img" src="https://yanfeiobpub.obs.cn-east-3.myhuaweicloud.com/dfg/act_invite_230717_03.png"></image>
            <!---排名-->
            <div class="ph_cont">
                <div style="width: 70%;width: 65%;background: #FDECE2;padding: 0.2rem;border-radius: 0.3rem;">
                    <div class="tbl" style="border-bottom: 1px dashed #4D2F08;">
                        <div class="cell" style="justify-content:left;">排名</div>
                        <div class="cell" style="justify-content:left;">用户id</div>
                        <div class="cell">邀请人数</div>
                    </div>
                    <div class="tbl" v-for="(item,index) in ranklist">
                        <div class="cell" style="justify-content:left;">
                            <image v-if="index==0" style="width: 38%;" src="https://yanfeiobpub.obs.cn-east-3.myhuaweicloud.com/dfg/actno1.png"></image>
                            <image v-else-if="index==1" style="width: 38%;" src="https://yanfeiobpub.obs.cn-east-3.myhuaweicloud.com/dfg/actno2.png"></image>
                            <image v-else-if="index==2" style="width: 38%;" src="https://yanfeiobpub.obs.cn-east-3.myhuaweicloud.com/dfg/actno3.png"></image>
                            <span v-else>{{index+1}}</span>
                        </div>
                        <div class="cell" style="justify-content:left;">
                            <image style="width: 24%; margin-right:0.1rem" :src="item.avatar"></image>
                            {{"**"+item.nickname.substr(item.nickname.length-1)}}
                        </div>
                        <div class="cell">{{item.recruit_count}}</div>
                    </div>
                   
                </div>
                
            </div>
        </div>
        <div class="act_po" style="    display: flex;justify-content: center;">
            <image class="com_img" src="https://yanfeiobpub.obs.cn-east-3.myhuaweicloud.com/dfg/act_invite_230717_04.png"></image>
            
            <div class="gz_txt">
                <p>
                    1、本次活动将在次月1号进行统计结算,结算邀请人数的时间范围为参加活动的时间至活动结束时间
                </p>
                <p>2、活动奖励会在结算后直接发放到用户【我的】-【余额】中</p>
                <p>3、有效粉丝定义:指活动期间,报名该活动后邀请注册并填写您邀请码的用户</p>
            </div>
        </div>
 
        <div v-if="showType" class="shadow">
            <div class="popup">
                <div class="popclose" v-on:click="closegz()">X</div>
                <div class="popupCongratulate"> 活动规则 </div>
                <div class="popupSon">
                    <p>
                        1、本次活动将在次月1号进行统计结算,结算邀请人数的时间范围为参加活动的时间至活动结束时间
                    </p>
                    <p>2、活动奖励会在结算后直接发放到用户【我的】-【余额】中</p>
                    <p>3、有效粉丝定义:指活动期间,报名该活动后邀请注册并填写您邀请码的用户</p>
                    <p>4、同一设备号、同一手机号、同一淘宝授权号等均视为同一用户</p>
                    <p>5、活动设置反作弊机制,凡参加本次活动,必须遵守活动的相关规则,不得使用任何包括但不限于舞弊、扰乱系统、侵犯第三方合法权益等手段以谋求奖励。一经证实用户在活动中使用任何不正当作弊手段恶意刷取奖励,平台有权删除用户活动的相关记录,取消您参加活动的资格,平台将直接取消本次活动所有权益。同时,平台保留追究其法律责任的权利。平台会在本次邀粉结算前统计分析新粉丝质量,如出现异常数据,平台会要求邀请者出示真实的邀粉凭证才予以结算,异常包括但不限于出现大规模的非常规时间注册用户、同一时间批量注册、连号手机号码注册、新粉丝次日留存率极低等情况,为保护广大邀请者的权益,请各邀请用户保留不低于活动邀粉数*30%的真实的邀粉凭证,能证明真实邀粉的邀粉视频、照片等均可,以防平台进行反作弊筛查。</p>
                    <p>
                    6、本次活动中所称作弊行为,包括但不限于:
                        (1)用户通过第三方平台发布粉丝注册任务、任何形式的付费买粉、机器刷粉、通过开通关联小号进行邀粉;
                        (2)同一用户或者IP地址注册多个账号,利用专业软件或者人工方法违反活动规则以获取更多奖励的行为;
                        (3)同一用户盗用、借用他人已有账号参与活动或者盗用、借用他人信息注册账号参与活动以获取更多奖励的行为;
                        (4)恶意利用活动规则或技术漏洞刷奖的行为;
                        (5)批量注册用户、用机器注册账户、用机器模拟客广端的行为;
                        (6)平台有合理理由认定用户在活动中的其他作弊行为;
                        (7)新粉丝使用虚拟运营商号码、使用同一设备号注册或同一授权淘宝号下单、刷单或下单商品为虚拟商品(充值、代拍、刷好评、电子文档、公益捐款)或下单商品重合度≥30%。
                    </p>
 
                </div>
                
            </div>
        </div>
        <div v-if="isShowcj" class="btngo" v-on:click="joinAct()">
            <image style="width: 70%;" src="https://yanfeiobpub.obs.cn-east-3.myhuaweicloud.com/dfg/invite_btn.png"></image>
        </div>
    </div>
    </div>
    </div>
</body>
 
</html>
<script type="text/javascript" src="https://cdn.staticfile.org/vue/2.6.11/vue.min.js"></script>
<script>
 
(function () {
        var size1=document.body.clientWidth;
        var size2=document.documentElement.clientWidth;
        var size=size1<=0?size2:size1;
        size=size<=0?400:size;
        document.documentElement.style.fontSize = (size > 750 ? 750 : size) / 7.5 + 'px';
    })();
    
    Vue.use(VueLazyload, {
        preLoad: 1.3,//
        error: 'https://sr.ffquan.cn/cms_pic/20200622/bro7s7f6vrkd3jat4ujg0.png',
        loading: 'https://sr.ffquan.cn/cms_pic/20200612/brhjkf76vrkcrfpi79eg0.png',
        attempt: 1
    })
  var app=  new Vue({
        el: '#inviteact',
        data:{
          //posturl:'http://dfg.shop.com',
          posturl:'https://appapitest.ushopvip.com',
          //posturl:'http://dfgapp.ushopvip.com',
          activityid:'3432534sdsd',
          loadingTxt:'加载中...',
          loading:true,
          showType:false,
          isShowcj:false,
          joinInfo:{},
          ranklist:[]
        },
        methods:{
            topBack:function()
            {
                uni.postMessage({
                      data: {
                         action: 'back'
                      }
                });
            },
            closegz:function()
            {
                this.showType=false;
            },
            showgz:function()
            {
                this.showType=true;
            },
            getActivity()
            {
                var _this = this;
                $.ajax({
                        headers:{
                            "token":_this.getUrlPar("token")
                        },
                        url:_this.posturl+'/api/Activity/getActInfo',
                        type:"post",
                        dataType:"json",
                        data:{
                            actid:_this.activityid
                        }
                    }).done(function(res){
                       if(res.data.actstatus==1)
                       {//活动正常
                            _this.isShowcj=res.data.joinstatus==0;
                            _this.loading=false;
                            _this.getPaiHang();
                            if(res.data.joinstatus==1)
                            {//活动参加的活动信息
                                _this.getActMember();
                            }
                            else{
                                //未参加过活动
                                _this.isShowcj=true;
                            }
                       }
                       else{
                            switch(res.data.actstatus)
                            {
                                case 0:
                                    _this.loadingTxt='活动不存在';
                                    break;
                                case -1:
                                case -3:
                                    _this.loadingTxt='活动已结束';
                                    break;
                                    case -2:
                                    _this.loadingTxt='活动未开始';
                                    break;
                                default:
                                _this.loadingTxt='活动异常';
                                    break;
                            }
                       }
                    })
            },
            getActMember:function()
            {
                var _this = this;
                $.ajax({
                        headers:{
                            "token":_this.getUrlPar("token")
                        },
                        url:_this.posturl+'/api/Activity/getActRecruitCount',
                        type:"post",
                        dataType:"json",
                        data:{
                            actid:_this.activityid
                        }
                    }).done(function(res){
                        _this.joinInfo=res.data;
                    })
            },
            getUrlPar:function(name)
            {
                var reg=new RegExp("(^|&)" + name + "=([^&]*)(&|$)");
                 var r=window.location.search.substr(1).match(reg);
                if(r !=null)return unescape(r[2]);
                 return null;
            },
            //参加活动
            joinAct:function()
            {
                var _this = this;
                $.ajax({
                        headers:{
                            "token":_this.getUrlPar("token")
                        },
                        url:_this.posturl+'/api/Activity/attendAct',
                        type:"post",
                        dataType:"json",
                        data:{
                            actid:_this.activityid
                        }
                    }).done(function(res){
                       if(res.code==0)
                       {
                        alert("参加成功!");
                        _this.getActMember();
                       }
                       else
                       {
                        alert("活动参加失败,请联系客服");
                       }
                    })
            },
            getPaiHang:function()
            {//获取排行
                var _this = this;
                $.ajax({
                        headers:{
                            "token":_this.getUrlPar("token")
                        },
                        url:_this.posturl+'/api/Activity/getRankingList',
                        type:"post",
                        dataType:"json",
                        data:{
                            actid:_this.activityid
                        }
                    }).done(function(res){
                       if(res.code==0)
                       {
                        _this.ranklist=res.data;
                       }
                       
                    })
            },
            touch:function()
            {
                const box = document.querySelector('.box')
                const list = document.querySelector('.list');
                // 按下屏幕的位置
                let touchStartPosition = 0
            
                // touchstart事件
                box.addEventListener('touchstart', function (e) {
                    let touch = e.touches[0]
                    touchStartPosition = touch.pageY
                })
                // touchmove事件
                box.addEventListener('touchmove', function (e) {
                   
                    let touch = e.touches[0]
                    // 列表的top值等于列表相对于box的偏移量+滑动的距离
                    let pySize= list.offsetTop + touch.pageY - touchStartPosition;
                    if(pySize>=110)
                    {
                      return;
                    }
                    if(pySize<0)
                    {
                        return;
                    }
                    var scroll = document.getElementsByClassName('contscore')
                        var srollPos = $('.contscore').scrollTop(); //滚动条距顶部距离(页面超出窗口的高度)
                    if(srollPos>0)
                    {
                        return;
                    }
                    list.style.top =pySize + 'px';
                    // 实现平滑的滑动
                    touchStartPosition = touch.pageY
                })
                // touchend事件
                box.addEventListener('touchend', function (e) {
                    let top = list.offsetTop
                    if (top > 70) {
                        // 在此处调用刷新后的回调
                        console.log('刷新');
                        location.reload();
                    }
                    if(top<0)
                    {
                        list.style.top=0;
                    }
                    if (top > 0) {
                        // 通过定时器平滑的将list的top = 0
                        let timer = setInterval(() => {
                            top=top-5;
                        list.style.top = top + 'px'
                        if (top <= 0) {
                            list.style.top=0;
                            clearInterval(timer)
                        }
                        },1)
                    }
                })
            },
        },
        mounted:function(){
           this.getActivity();
           this.touch();
        }
    })
</script>