陈冉 6 lat temu
rodzic
commit
81af2ec224
2 zmienionych plików z 203 dodań i 149 usunięć
  1. 1
    1
      src/components/music.vue
  2. 202
    148
      src/views/vote/list.vue

+ 1
- 1
src/components/music.vue Wyświetl plik

29
       yttjmusicoff:'https://spaceofcheng.oss-cn-beijing.aliyuncs.com/voting/yttj_icon_music_close.png',
29
       yttjmusicoff:'https://spaceofcheng.oss-cn-beijing.aliyuncs.com/voting/yttj_icon_music_close.png',
30
       yjsmusicoff:'https://spaceofcheng.oss-cn-beijing.aliyuncs.com/voting/yjs_icon_music_close.png',
30
       yjsmusicoff:'https://spaceofcheng.oss-cn-beijing.aliyuncs.com/voting/yjs_icon_music_close.png',
31
       audioPlayShow: true,
31
       audioPlayShow: true,
32
-      actid: this.$route.query.actid
33
     };
32
     };
34
   },
33
   },
35
   methods: {
34
   methods: {
63
     width: 0.24rem;
62
     width: 0.24rem;
64
     height: 0.24rem;
63
     height: 0.24rem;
65
     border-radius: 50%;
64
     border-radius: 50%;
65
+    z-index: 10;
66
 
66
 
67
     .play {
67
     .play {
68
       width: 100%;
68
       width: 100%;

+ 202
- 148
src/views/vote/list.vue Wyświetl plik

1
 <template>
1
 <template>
2
   <div class="context" :style="{backgroundImage: 'url(' + (coverImgUrl ?BgImage:BgImg) + ')'}">
2
   <div class="context" :style="{backgroundImage: 'url(' + (coverImgUrl ?BgImage:BgImg) + ')'}">
3
     <img class="BannerImage" :src="activity.Banner">
3
     <img class="BannerImage" :src="activity.Banner">
4
-    <div :class="isOK?searchs:searchb">
5
-      <input placeholder="输入编号或姓名" v-model="q">
6
-      <img class="IconSearch" :src="IconSearch" @click="search">
7
-      <!-- <i class="iconfont icon-sousuo3 IconSearch"></i> -->
4
+    <div :class="IsOk?onscroll1:onscroll2">
5
+      <div :class="isOK?searchs:searchb">
6
+        <input placeholder="输入编号或姓名" v-model="q">
7
+        <img class="IconSearch" :src="IconSearch" @click="search">
8
+        <!-- <i class="iconfont icon-sousuo3 IconSearch"></i> -->
9
+      </div>
8
     </div>
10
     </div>
9
     <img class="informationimg" :src="activity.Desc">
11
     <img class="informationimg" :src="activity.Desc">
10
     <span class="box"></span>
12
     <span class="box"></span>
15
             <van-list v-model="loading" :finished="finished" finished-text="没有更多了" @load="onLoad">
17
             <van-list v-model="loading" :finished="finished" finished-text="没有更多了" @load="onLoad">
16
               <div class="LatestUpload">
18
               <div class="LatestUpload">
17
                 <div class="LatestUploadList" v-for="(item,index) in newList" :key="index">
19
                 <div class="LatestUploadList" v-for="(item,index) in newList" :key="index">
18
-                  <div :class="signupBtn?ActivePersonnelBox1:ActivePersonnelBox2" @click="gotovotingdetails(item.MemberId)">
20
+                  <div
21
+                    :class="signupBtn?ActivePersonnelBox1:ActivePersonnelBox2"
22
+                    @click="gotovotingdetails(item.MemberId)"
23
+                  >
19
                     <img :src="item.Photo">
24
                     <img :src="item.Photo">
20
                   </div>
25
                   </div>
21
                   <span :class="signupBtn?ballot1:ballot2">NO.{{item.MemberId}}</span>
26
                   <span :class="signupBtn?ballot1:ballot2">NO.{{item.MemberId}}</span>
32
           <van-tab title="TOP50">
37
           <van-tab title="TOP50">
33
             <div class="LatestUpload">
38
             <div class="LatestUpload">
34
               <div class="LatestUploadList" v-for="(item,index) in topList" :key="index">
39
               <div class="LatestUploadList" v-for="(item,index) in topList" :key="index">
35
-                <div :class="signupBtn?ActivePersonnelBox1:ActivePersonnelBox2" @click="gotovotingdetails(item.MemberId)">
40
+                <div
41
+                  :class="signupBtn?ActivePersonnelBox1:ActivePersonnelBox2"
42
+                  @click="gotovotingdetails(item.MemberId)"
43
+                >
36
                   <img :src="item.Photo">
44
                   <img :src="item.Photo">
37
                 </div>
45
                 </div>
38
                 <span :class="signupBtn?ballot1:ballot2">NO.{{item.MemberId}}</span>
46
                 <span :class="signupBtn?ballot1:ballot2">NO.{{item.MemberId}}</span>
69
   data() {
77
   data() {
70
     return {
78
     return {
71
       // AudioPlay: ''
79
       // AudioPlay: ''
72
-      signupBtn:true,
73
-      signupBtnOne:"signupBtnOne",
74
-      signupBtnTwo:"signupBtnTwo",
75
-      VoteBtn1:'VoteBtn1',
76
-      VoteBtn2:'VoteBtn2',
77
-      ballot1:'ballot1',
78
-      ballot2:'ballot2',
80
+      signupBtn: true,
81
+      signupBtnOne: "signupBtnOne",
82
+      signupBtnTwo: "signupBtnTwo",
83
+      VoteBtn1: "VoteBtn1",
84
+      VoteBtn2: "VoteBtn2",
85
+      ballot1: "ballot1",
86
+      ballot2: "ballot2",
79
       coverImgUrl: true,
87
       coverImgUrl: true,
80
       isOK: true,
88
       isOK: true,
89
+      IsOk:true,
81
       searchs: "searchs",
90
       searchs: "searchs",
82
       searchb: "searchb",
91
       searchb: "searchb",
83
-      ActivePersonnelBox1:'ActivePersonnelBox1',
84
-      ActivePersonnelBox2:'ActivePersonnelBox2',
92
+      onscroll1:'onscroll1',
93
+      onscroll2:'onscroll2',
94
+      ActivePersonnelBox1: "ActivePersonnelBox1",
95
+      ActivePersonnelBox2: "ActivePersonnelBox2",
85
       BgImg,
96
       BgImg,
86
       BgImage,
97
       BgImage,
87
       IconSearch:
98
       IconSearch:
116
     console.log(this.actid);
127
     console.log(this.actid);
117
     if (this.actid == 1) {
128
     if (this.actid == 1) {
118
       this.coverImgUrl = true;
129
       this.coverImgUrl = true;
119
-      this.signupBtn =true;
130
+      this.signupBtn = true;
120
       this.isOK = true;
131
       this.isOK = true;
121
     } else if (this.actid == 2) {
132
     } else if (this.actid == 2) {
122
       this.coverImgUrl = false;
133
       this.coverImgUrl = false;
123
-      this.signupBtn=false;
134
+      this.signupBtn = false;
124
       this.isOK = false;
135
       this.isOK = false;
125
     }
136
     }
126
     this.getActivity({
137
     this.getActivity({
130
     this.toplist();
141
     this.toplist();
131
   },
142
   },
132
   methods: {
143
   methods: {
133
-    // handleScroll() {
134
-    //   // 页面滚动距顶部距离
135
-    //   var scrollTop =
136
-    //     window.pageYOffset ||
137
-    //     document.documentElement.scrollTop ||
138
-    //     document.body.scrollTop;
139
-    //   if (scrollTop >= 280) {
140
-    //     this.isOK = false;
141
-    //   } else {
142
-    //     this.isOK = true;
143
-    //   }
144
-    // },
144
+    handleScroll() {
145
+      // 页面滚动距顶部距离
146
+      var scrollTop =
147
+        window.pageYOffset ||
148
+        document.documentElement.scrollTop ||
149
+        document.body.scrollTop;
150
+      if (scrollTop >= 269) {
151
+        this.IsOk = false;
152
+      } else {
153
+        this.IsOk = true;
154
+      }
155
+    },
145
 
156
 
146
     ...mapactivityActions(["getList", "getTopList", "getActivity", "vote"]),
157
     ...mapactivityActions(["getList", "getTopList", "getActivity", "vote"]),
147
     newlist() {
158
     newlist() {
273
     width: 100%;
284
     width: 100%;
274
     height: 3.4rem;
285
     height: 3.4rem;
275
   }
286
   }
276
-  .searchb {
287
+
288
+  .onscroll1 {
277
     width: 90%;
289
     width: 90%;
278
     height: 0.44rem;
290
     height: 0.44rem;
279
-    background-color: rgba(118,89,81,1);
280
-    border-radius: 0.22rem;
281
-    border: 0.01rem solid rgba(255, 255, 255, 1);
282
-    display: flex;
283
-    flex-direction: row;
284
-    justify-content: space-between;
285
-    align-items: center;
286
     position: absolute;
291
     position: absolute;
287
     top: 2.8rem;
292
     top: 2.8rem;
288
     left: calc(5%);
293
     left: calc(5%);
289
 
294
 
290
-    input {
291
-      // padding: 0.11rem 1.2rem 0.11rem 0.13rem;
292
-      background-color: rgba(255, 255, 255, 0);
293
-      color: rgba(255, 255, 255, 1);
294
-      font-size: 0.16rem;
295
-      font-family: PingFangSC-Regular;
296
-      font-weight: 400;
297
-      line-height: 0.22rem;
298
-      width: 5rem;
299
-      text-indent: 0.1rem;
300
-    }
301
-    input::-webkit-input-placeholder {
302
-      color: rgba(255, 255, 255, 1);
303
-      font-size: 0.16rem;
304
-      font-family: PingFangSC-Regular;
305
-      font-weight: 400;
306
-      line-height: 0.22rem;
295
+    .searchb {
296
+      width: 100%;
297
+      height: 100%;
298
+      background-color: rgba(118, 89, 81, 1);
299
+      border-radius: 0.22rem;
300
+      border: 0.01rem solid rgba(255, 255, 255, 1);
301
+      display: flex;
302
+      flex-direction: row;
303
+      justify-content: space-between;
304
+      align-items: center;
305
+
306
+      input {
307
+        // padding: 0.11rem 1.2rem 0.11rem 0.13rem;
308
+        background-color: rgba(255, 255, 255, 0);
309
+        color: rgba(255, 255, 255, 1);
310
+        font-size: 0.16rem;
311
+        font-family: PingFangSC-Regular;
312
+        font-weight: 400;
313
+        line-height: 0.22rem;
314
+        width: 5rem;
315
+        text-indent: 0.1rem;
316
+      }
317
+      input::-webkit-input-placeholder {
318
+        color: rgba(255, 255, 255, 1);
319
+        font-size: 0.16rem;
320
+        font-family: PingFangSC-Regular;
321
+        font-weight: 400;
322
+        line-height: 0.22rem;
323
+      }
324
+      .IconSearch {
325
+        width: 0.2rem;
326
+        height: 0.2rem;
327
+        margin-right: 0.1rem;
328
+      }
307
     }
329
     }
308
-    .IconSearch {
309
-      width: 0.2rem;
310
-      height: 0.2rem;
311
-      margin-right: 0.1rem;
330
+  }
331
+
332
+ .onscroll2 {
333
+    width: 90%;
334
+    height: 0.44rem;
335
+    position: fixed;
336
+    top: 0.11rem;
337
+    left: calc(5%);
338
+
339
+    .searchb {
340
+      width: 100%;
341
+      height: 100%;
342
+      background-color: rgba(118, 89, 81, 1);
343
+      border-radius: 0.22rem;
344
+      border: 0.01rem solid rgba(255, 255, 255, 1);
345
+      display: flex;
346
+      flex-direction: row;
347
+      justify-content: space-between;
348
+      align-items: center;
349
+
350
+      input {
351
+        // padding: 0.11rem 1.2rem 0.11rem 0.13rem;
352
+        background-color: rgba(255, 255, 255, 0);
353
+        color: rgba(255, 255, 255, 1);
354
+        font-size: 0.16rem;
355
+        font-family: PingFangSC-Regular;
356
+        font-weight: 400;
357
+        line-height: 0.22rem;
358
+        width: 5rem;
359
+        text-indent: 0.1rem;
360
+      }
361
+      input::-webkit-input-placeholder {
362
+        color: rgba(255, 255, 255, 1);
363
+        font-size: 0.16rem;
364
+        font-family: PingFangSC-Regular;
365
+        font-weight: 400;
366
+        line-height: 0.22rem;
367
+      }
368
+      .IconSearch {
369
+        width: 0.2rem;
370
+        height: 0.2rem;
371
+        margin-right: 0.1rem;
372
+      }
312
     }
373
     }
313
   }
374
   }
314
-  .searchs {
375
+
376
+  .onscroll1 {
315
     width: 93%;
377
     width: 93%;
316
     height: 0.44rem;
378
     height: 0.44rem;
317
-    background-color: rgba(201, 214, 224, 1);
318
-    border-radius: 0.06rem;
319
-    border: 0.01rem solid rgba(255, 255, 255, 1);
320
-    display: flex;
321
-    flex-direction: row;
322
-    justify-content: space-between;
323
-    align-items: center;
324
     position: absolute;
379
     position: absolute;
325
     top: 2.8rem;
380
     top: 2.8rem;
326
     left: calc(3.1%);
381
     left: calc(3.1%);
327
 
382
 
328
-    input {
329
-      // padding: 0.11rem 1.2rem 0.11rem 0.13rem;
330
-      background-color: rgba(255, 255, 255, 0);
331
-      color: rgba(255, 255, 255, 1);
332
-      font-size: 0.16rem;
333
-      font-family: PingFangSC-Regular;
334
-      font-weight: 400;
335
-      line-height: 0.22rem;
336
-      width: 5rem;
337
-      text-indent: 0.1rem;
338
-    }
339
-    input::-webkit-input-placeholder {
340
-      color: rgba(255, 255, 255, 1);
341
-      font-size: 0.16rem;
342
-      font-family: PingFangSC-Regular;
343
-      font-weight: 400;
344
-      line-height: 0.22rem;
345
-    }
383
+    .searchs {
384
+      width: 100%;
385
+      height: 100%;
386
+      background-color: rgba(201, 214, 224, 1);
387
+      border-radius: 0.06rem;
388
+      border: 0.01rem solid rgba(255, 255, 255, 1);
389
+      display: flex;
390
+      flex-direction: row;
391
+      justify-content: space-between;
392
+      align-items: center;
393
+
394
+      input {
395
+        // padding: 0.11rem 1.2rem 0.11rem 0.13rem;
396
+        background-color: rgba(255, 255, 255, 0);
397
+        color: rgba(255, 255, 255, 1);
398
+        font-size: 0.16rem;
399
+        font-family: PingFangSC-Regular;
400
+        font-weight: 400;
401
+        line-height: 0.22rem;
402
+        width: 5rem;
403
+        text-indent: 0.1rem;
404
+      }
405
+      input::-webkit-input-placeholder {
406
+        color: rgba(255, 255, 255, 1);
407
+        font-size: 0.16rem;
408
+        font-family: PingFangSC-Regular;
409
+        font-weight: 400;
410
+        line-height: 0.22rem;
411
+      }
346
 
412
 
347
-    .IconSearch {
348
-      width: 0.2rem;
349
-      height: 0.2rem;
350
-      margin-right: 0.1rem;
413
+      .IconSearch {
414
+        width: 0.2rem;
415
+        height: 0.2rem;
416
+        margin-right: 0.1rem;
417
+      }
351
     }
418
     }
352
   }
419
   }
353
 
420
 
354
-  #searchone{
355
-
356
-    .searchs {
421
+  .onscroll2 {
357
     width: 93%;
422
     width: 93%;
358
     height: 0.44rem;
423
     height: 0.44rem;
359
-    background-color: rgba(201, 214, 224, 1);
360
-    border-radius: 6px;
361
-    border: 0.01rem solid rgba(255, 255, 255, 1);
362
-    display: flex;
363
-    flex-direction: row;
364
-    justify-content: space-between;
365
-    align-items: center;
366
-    position: absolute;
367
-    top: 2.8rem;
424
+    position: fixed;
425
+    top: 0.11rem;
368
     left: calc(3.1%);
426
     left: calc(3.1%);
369
 
427
 
370
-    input {
371
-      // padding: 0.11rem 1.2rem 0.11rem 0.13rem;
372
-      background-color: rgba(255, 255, 255, 0);
373
-      color: rgba(255, 255, 255, 1);
374
-      font-size: 0.16rem;
375
-      font-family: PingFangSC-Regular;
376
-      font-weight: 400;
377
-      line-height: 0.22rem;
378
-      width: 5rem;
379
-      text-indent: 0.1rem;
380
-    }
381
-    input::-webkit-input-placeholder {
382
-      color: rgba(255, 255, 255, 1);
383
-      font-size: 0.16rem;
384
-      font-family: PingFangSC-Regular;
385
-      font-weight: 400;
386
-      line-height: 0.22rem;
387
-    }
428
+    .searchs {
429
+      width: 100%;
430
+      height: 100%;
431
+      background-color: rgba(201, 214, 224, 1);
432
+      border-radius: 0.06rem;
433
+      border: 0.01rem solid rgba(255, 255, 255, 1);
434
+      display: flex;
435
+      flex-direction: row;
436
+      justify-content: space-between;
437
+      align-items: center;
438
+
439
+      input {
440
+        // padding: 0.11rem 1.2rem 0.11rem 0.13rem;
441
+        background-color: rgba(255, 255, 255, 0);
442
+        color: rgba(255, 255, 255, 1);
443
+        font-size: 0.16rem;
444
+        font-family: PingFangSC-Regular;
445
+        font-weight: 400;
446
+        line-height: 0.22rem;
447
+        width: 5rem;
448
+        text-indent: 0.1rem;
449
+      }
450
+      input::-webkit-input-placeholder {
451
+        color: rgba(255, 255, 255, 1);
452
+        font-size: 0.16rem;
453
+        font-family: PingFangSC-Regular;
454
+        font-weight: 400;
455
+        line-height: 0.22rem;
456
+      }
388
 
457
 
389
-    .IconSearch {
390
-      width: 0.2rem;
391
-      height: 0.2rem;
392
-      margin-right: 0.1rem;
458
+      .IconSearch {
459
+        width: 0.2rem;
460
+        height: 0.2rem;
461
+        margin-right: 0.1rem;
462
+      }
393
     }
463
     }
394
   }
464
   }
395
 
465
 
396
-  }
397
   .informationimg {
466
   .informationimg {
398
     width: 97%;
467
     width: 97%;
399
     height: 6.24rem;
468
     height: 6.24rem;
452
               border-radius: 0.1rem;
521
               border-radius: 0.1rem;
453
             }
522
             }
454
           }
523
           }
455
- .ActivePersonnelBox2 {
524
+          .ActivePersonnelBox2 {
456
             width: 90%;
525
             width: 90%;
457
             height: 1.83rem;
526
             height: 1.83rem;
458
             border-radius: 0.15rem;
527
             border-radius: 0.15rem;
459
             margin-bottom: 0.11rem;
528
             margin-bottom: 0.11rem;
460
-            border: 0.04rem solid rgba(126,100,86,1);
529
+            border: 0.04rem solid rgba(126, 100, 86, 1);
461
 
530
 
462
             img {
531
             img {
463
               width: 100%;
532
               width: 100%;
481
           .ballot2 {
550
           .ballot2 {
482
             position: absolute;
551
             position: absolute;
483
             top: 0;
552
             top: 0;
484
-            background: rgba(126,100,86,1);
553
+            background: rgba(126, 100, 86, 1);
485
             border-radius: 0 0 0.08rem 0.08rem;
554
             border-radius: 0 0 0.08rem 0.08rem;
486
             padding: 0.02rem 0.12rem;
555
             padding: 0.02rem 0.12rem;
487
             font-size: 0.14rem;
556
             font-size: 0.14rem;
513
             line-height: 0.2rem;
582
             line-height: 0.2rem;
514
             margin-bottom: 0.14rem;
583
             margin-bottom: 0.14rem;
515
           }
584
           }
516
-          .VoteBtn2{
585
+          .VoteBtn2 {
517
             width: 56%;
586
             width: 56%;
518
             height: 0.23rem;
587
             height: 0.23rem;
519
             border-radius: 0.25rem;
588
             border-radius: 0.25rem;
520
-            background-color: rgba(126,100,86,1);
589
+            background-color: rgba(126, 100, 86, 1);
521
             border: none;
590
             border: none;
522
             font-size: 0.14rem;
591
             font-size: 0.14rem;
523
             font-family: PingFangSC-Medium;
592
             font-family: PingFangSC-Medium;
550
       }
619
       }
551
     }
620
     }
552
   }
621
   }
553
-  .signupBtnOne{
554
-     width: 91%;
622
+  .signupBtnOne {
623
+    width: 91%;
555
     height: 0.5rem;
624
     height: 0.5rem;
556
     border-radius: 0.25rem;
625
     border-radius: 0.25rem;
557
     background: rgba(166, 184, 201, 1);
626
     background: rgba(166, 184, 201, 1);
565
     bottom: 0.19rem;
634
     bottom: 0.19rem;
566
     left: calc(4.25%);
635
     left: calc(4.25%);
567
   }
636
   }
568
-  .signupBtnTwo{
569
-     width: 91%;
637
+  .signupBtnTwo {
638
+    width: 91%;
570
     height: 0.5rem;
639
     height: 0.5rem;
571
     border-radius: 0.25rem;
640
     border-radius: 0.25rem;
572
-    background: rgba(173,145,129,1);
641
+    background: rgba(173, 145, 129, 1);
573
     border: none;
642
     border: none;
574
     font-size: 0.2rem;
643
     font-size: 0.2rem;
575
     font-family: PingFangSC-Medium;
644
     font-family: PingFangSC-Medium;
580
     bottom: 0.19rem;
649
     bottom: 0.19rem;
581
     left: calc(4.25%);
650
     left: calc(4.25%);
582
   }
651
   }
583
-  // .signupBtn {
584
-  //   width: 91%;
585
-  //   height: 0.5rem;
586
-  //   border-radius: 0.25rem;
587
-  //   background: rgba(166, 184, 201, 1);
588
-  //   border: none;
589
-  //   font-size: 0.2rem;
590
-  //   font-family: PingFangSC-Medium;
591
-  //   font-weight: bold;
592
-  //   color: rgba(255, 255, 255, 1);
593
-  //   line-height: 0.28rem;
594
-  //   position: fixed;
595
-  //   bottom: 0.19rem;
596
-  //   left: calc(4.25%);
597
-  // }
598
 }
652
 }
599
 </style>
653
 </style>
600
 
654