liyongli 2 years ago
parent
commit
fc913a68a3

+ 3 - 4
src/view/WorldCup/components/match.vue

@@ -183,10 +183,8 @@ function line3(x, textY, col, colWidth) {
 
 
 function selectFlag(index) {
 function selectFlag(index) {
   const select = flag[index];
   const select = flag[index];
-  console.log(select[6].isED)
-  if (select[2] == 4 || select[6].isED || select[6].isForeast) return;
+  if (select[2] == 4 || select[4].text === '?' || select[6].isED || select[6].isForeast) return;
   const linkSelect = flag[select[3] % 2 === 0 ? index + 1 : index - 1] || undefined;
   const linkSelect = flag[select[3] % 2 === 0 ? index + 1 : index - 1] || undefined;
-  console.log(linkSelect,select[3])
   const startRow = select[2]; // 行数
   const startRow = select[2]; // 行数
   const startCol = select[3]; // 点击列数
   const startCol = select[3]; // 点击列数
   const isDown = startRow < 4 ? 1 : -1; // 递增系数
   const isDown = startRow < 4 ? 1 : -1; // 递增系数
@@ -232,8 +230,9 @@ function upData() {
   for (let i = 0; i < flag.length; i++) {
   for (let i = 0; i < flag.length; i++) {
     const v = flag[i];
     const v = flag[i];
     if (!v[6].pSelectId || !v[4].text || v[4].text == "?") continue;
     if (!v[6].pSelectId || !v[4].text || v[4].text == "?") continue;
+    let raceId = v[6].pSelectId != -1 ? v[6].pSelectId : 15;
     objFlag.push({
     objFlag.push({
-      raceId: v[6].selectId,
+      raceId,
       winner: v[4].text,
       winner: v[4].text,
     });
     });
   }
   }

+ 10 - 3
src/view/WorldCup/components/ranking.vue

@@ -1,7 +1,11 @@
 <template>
 <template>
   <div class="ranking">
   <div class="ranking">
     <img class="activityTitle" :src="require('../../../assets/img/vote.png')" />
     <img class="activityTitle" :src="require('../../../assets/img/vote.png')" />
-    <div class="subTitle">123</div>
+    <div class="subTitle">
+      <p>1.每人每日可投票2次;</p>
+      <p>2.下载闪视频App参与活动,每日可投票3次。</p>
+      <p>3.可在排行榜下方搜索选手姓名或编号为喜爱的作品投票</p>
+    </div>
     <div class="topThree">
     <div class="topThree">
       <div class="topUser">
       <div class="topUser">
         <div
         <div
@@ -59,7 +63,7 @@
       <van-row
       <van-row
         justify="center"
         justify="center"
         class="van-hairline--bottom"
         class="van-hairline--bottom"
-        v-for="(i, o) in (vote[1] || [])"
+        v-for="(i, o) in vote[1] || []"
         :key="o"
         :key="o"
         @click="() => toNewPage(i.phone)"
         @click="() => toNewPage(i.phone)"
       >
       >
@@ -126,7 +130,7 @@ function searchuser() {
           onclick={() => toNewPage(v.phone)}
           onclick={() => toNewPage(v.phone)}
         >
         >
           <van-col span="9">{v.name}</van-col>
           <van-col span="9">{v.name}</van-col>
-          <van-col span="8">{v.votes + '票'}</van-col>
+          <van-col span="8">{v.votes + "票"}</van-col>
           <van-col span="7">详情</van-col>
           <van-col span="7">详情</van-col>
         </van-row>
         </van-row>
       );
       );
@@ -206,6 +210,9 @@ function searchuser() {
     color: #ffffff;
     color: #ffffff;
     line-height: 17px;
     line-height: 17px;
     margin: 0 21px;
     margin: 0 21px;
+    p {
+      line-height: 1.8em;
+    }
   }
   }
   .list {
   .list {
     position: relative;
     position: relative;

+ 5 - 5
src/view/WorldCup/index.vue

@@ -167,7 +167,7 @@ function formmateMatch(matchList) {
           isED: !!v.winner,
           isED: !!v.winner,
           isHome: true,
           isHome: true,
           selectId: v.id,
           selectId: v.id,
-          pSelectId: v.pid,
+          pSelectId: v.homePid,
         },
         },
       ];
       ];
       team[5] = [
       team[5] = [
@@ -179,7 +179,7 @@ function formmateMatch(matchList) {
           isED: !!v.winner,
           isED: !!v.winner,
           isHome: true,
           isHome: true,
           selectId: v.id,
           selectId: v.id,
-          pSelectId: v.pid,
+          pSelectId: v.awayPid,
         },
         },
       ];
       ];
       team[Math.ceil((maxcol.length - 1) / 2)] = [
       team[Math.ceil((maxcol.length - 1) / 2)] = [
@@ -196,7 +196,7 @@ function formmateMatch(matchList) {
           isForeast,
           isForeast,
           isED: !!v.winner,
           isED: !!v.winner,
           selectId: v.id,
           selectId: v.id,
-          pSelectId: v.pid,
+          pSelectId: -1,
         },
         },
       ];
       ];
     }
     }
@@ -228,7 +228,7 @@ function setTeam(teamIndex, item, isForeast) {
     isForeast,
     isForeast,
     isHome: true,
     isHome: true,
     selectId: item.id,
     selectId: item.id,
-    pSelectId: item.pid,
+    pSelectId: item.homePid,
   });
   });
   team[teamIndex].push({
   team[teamIndex].push({
     team: item.away || "",
     team: item.away || "",
@@ -238,7 +238,7 @@ function setTeam(teamIndex, item, isForeast) {
     isForeast,
     isForeast,
     isHome: false,
     isHome: false,
     selectId: item.id,
     selectId: item.id,
-    pSelectId: item.pid,
+    pSelectId: item.awayPid,
   });
   });
 }
 }