Ver Fonte

页面微调

Changpeng Duan há 4 anos atrás
pai
commit
5e38619451

+ 5 - 5
v2tv/src/Mock/index.js

@@ -402,7 +402,7 @@ if (t == 1) {
 
     // 0: 下课 团课/私教/PK 的排名
     let LessonClass = 0;
-    let LessonDp = 0;
+    let LessonDp = 3;
     // 1:团课/私教
     // 2:竞技课2PK
     // 3:竞技课threepk
@@ -424,10 +424,10 @@ if (t == 1) {
         // 上3队PK课
         Mock.mock(curheadapi + 'ClassStatQuery', 'post', getClassStat(1, 3));
         Mock.mock(Mockapi + 'ClassStatQuery', 'post', getClassStat(1, 3));
-        Mock.mock(curheadapi + 'UserListInfo', 'post', testStudent(8, 3,));
-        Mock.mock(Mockapi + 'UserListInfo', 'post', testStudent(8, 3,));
-        Mock.mock(curheadapi + 'ClassUserRank', 'post', testStudent(8, 2));
-        Mock.mock(Mockapi + 'ClassUserRank', 'post', testStudent(8, 2));
+        Mock.mock(curheadapi + 'UserListInfo', 'post', testStudent(2, 3,));
+        Mock.mock(Mockapi + 'UserListInfo', 'post', testStudent(4, 3,));
+        Mock.mock(curheadapi + 'ClassUserRank', 'post', testStudent(1, 2));
+        Mock.mock(Mockapi + 'ClassUserRank', 'post', testStudent(1, 2));
     } else if (LessonClass == 0) {
         // 下课
         if (LessonDp == 0) {

+ 33 - 15
v2tv/src/components/threestudent.vue

@@ -314,8 +314,9 @@ ul {
 
 
   .lt {
-    width: 35%;
+    width: 31%;
     float: left;
+    padding-right: 4%;
 
     span {
       float: right;
@@ -352,22 +353,22 @@ ul {
         border-radius: 250rem;
 
         &.girl {
-          border: 0.05rem solid #EA26EA;
+          border: 2px solid #EA26EA;
         }
 
         &.boy {
-          border: 0.05rem solid #39B6FF;
+          border: 2px solid #39B6FF;
         }
       }
     }
 
     .names {
       @include cube;
-      width: 2rem;
-      background: rgba(0, 0, 0, 0.49);
+      width: 1.2rem;
+      background: rgba(0, 0, 0, 0.7);
       font-size: 0.3rem;
       text-align: center;
-      padding: 3% 1%;
+      padding: 1% 1%;
       border-radius: 250rem;
       position: relative;
       bottom: 0.45rem;
@@ -450,7 +451,7 @@ ul {
   width: 0.6rem;
   float: right;
   position: relative;
-  bottom: 2.8rem;
+  bottom: 2.9rem;
 }
 
 .max {
@@ -482,8 +483,9 @@ ul {
     height: 2rem;
 
     .names {
-      width: 1.6rem;
+      width: 1.2rem;
       font-size: 0.2rem;
+      bottom: 0.3rem;
     }
   }
 
@@ -496,13 +498,28 @@ ul {
     }
 
     img {
-      width: 0.4rem;
+      width: 0.3rem;
       margin-right: 10%;
     }
   }
 
   .userSport {
     line-height: 0.5rem;
+
+    img {
+      width: 0.3rem;
+    }
+
+    em {
+      font-size: 0.35rem;
+    }
+  }
+
+  .IsPrivate {
+    width: 0.5rem;
+    float: right;
+    position: relative;
+    bottom: 2.2rem;
   }
 }
 
@@ -535,8 +552,9 @@ ul {
     height: 2.1rem;
 
     .names {
-      width: 1.6rem;
+      width: 1.2rem;
       font-size: 0.2rem;
+      bottom: 0.3rem;
     }
   }
 
@@ -742,8 +760,8 @@ ul {
 
 .twentyFive {
   width: 3.18rem;
-  height: 1.6rem;
-  margin-top: 0.04rem;
+  height: 1.55rem;
+  margin-top: 0.1rem;
 
   .lt span {
     margin-top: 3%;
@@ -755,7 +773,7 @@ ul {
 
     s {
       font-size: 0.2rem;
-      margin-top: -0.1rem;
+      margin-top: 0rem;
     }
   }
 
@@ -775,9 +793,9 @@ ul {
     }
 
     .names {
-      width: 0.8rem;
+      width: 0.7rem;
       font-size: 0.15rem;
-      bottom: 0.3rem;
+      bottom: 0.2rem;
     }
   }
 

+ 2 - 0
v2tv/src/views/2pkRank.vue

@@ -587,6 +587,8 @@ export default {
   }
 
   .pageDetail {
+    overflow: hidden;
+
     .sumTitle {
       @include cube;
       width: 90%;

+ 127 - 27
v2tv/src/views/3pkRank.vue

@@ -12,8 +12,7 @@
           </span>
           <span class="center">CK</span>
           <span class="ckValue">
-            <em class="winner" v-if="winner == 1">217.9</em>
-            <em class="loser" v-else>217.9</em>
+            <em class="loser">217.9</em>
           </span>
           <div class="mvp">
             <div class="head">
@@ -42,8 +41,7 @@
           </span>
           <span class="center">CK</span>
           <span class="ckValue">
-            <em class="winner" v-if="winner == 1">217.9</em>
-            <em class="loser" v-else>217.9</em>
+            <em class="winner">217.9</em>
           </span>
           <div class="mvp">
             <div class="head">
@@ -62,7 +60,7 @@
             人均卡路里 8392
           </div>
           <div class="teamName">
-            
+            
           </div>
         </div>
         <div class="rt">
@@ -71,8 +69,7 @@
           </span>
           <span class="center">CK</span>
           <span class="ckValue">
-            <em class="winner" v-if="winner == 2">217.9</em>
-            <em class="loser" v-else>217.9</em>
+            <em class="loser">217.9</em>
           </span>
           <div class="mvp">
             <div class="head">
@@ -244,8 +241,6 @@ export default {
       pages: 2,
       eqSn: '30:9C:23:0C:8B:1E',
       pageStyle: RandomBg(),
-      redMvp: {},
-      blueMvp: {},
       winner: 1,
       trueDate: true,//真实数据 true false
       autoJump: true,//开启自动跳走
@@ -253,6 +248,84 @@ export default {
         CkSort: [],
         CalSort: [],
       },
+      redMvp: {
+        Age: 13,
+        AvgHr: 0,
+        BeginTime: 1608188579,
+        Ck: "@float(1,99,0,1)",
+        Cle: "@float(1,9999,0,1)",
+        DuId: 119,
+        EndTime: 0,
+        Head: require('../static/img/testhead.png'),
+        Height: 160,
+        HrId: 41,
+        IsBirthday: 0,
+        IsBreaking: 0,
+        IsNewUser: 0,
+        MaxHr: 80,
+        PowerPercent: "@integer(10, 100)",
+        Name: "姜泽志",
+        PkSucessnum: '1',//胜场数
+        PkTotalnum: '1',//总场数
+        PlanId: 60,
+        PureCalorieNoVo2: "@integer(1, 999)",
+        Sex: 1,
+        Sn: "22735",
+        StaticHr: 60,
+        SvId: 20,
+        UserId: 104,
+        UserMd5: "55661a861f8fae20dd505b2b4575dc0e",
+        Weight: 50,
+        ActivePercent: "@integer(10, 100)",
+        bmrMSjRmrcb: 66.00000000000001,
+        FormatCk: "@integer(1, 999)",
+        isAlive: true,
+        isFinish: false,
+        isOver: false,
+        IsPrivate: 1,
+        lastPushDataTime: 1608188947175,
+        lastUpdateTime: 1608188945184,
+        queuePushData: [],
+      },
+      blueMvp: {
+        Age: 13,
+        AvgHr: 0,
+        BeginTime: 1608188579,
+        Ck: "@float(1,99,0,1)",
+        Cle: "@float(1,9999,0,1)",
+        DuId: 119,
+        EndTime: 0,
+        Head: require('../static/img/testhead.png'),
+        Height: 160,
+        HrId: 41,
+        IsBirthday: 0,
+        IsBreaking: 0,
+        IsNewUser: 0,
+        MaxHr: 80,
+        PowerPercent: "@integer(10, 100)",
+        Name: "姜泽志",
+        PkSucessnum: '1',//胜场数
+        PkTotalnum: '1',//总场数
+        PlanId: 60,
+        PureCalorieNoVo2: "@integer(1, 999)",
+        Sex: 1,
+        Sn: "22735",
+        StaticHr: 60,
+        SvId: 20,
+        UserId: 104,
+        UserMd5: "55661a861f8fae20dd505b2b4575dc0e",
+        Weight: 50,
+        ActivePercent: "@integer(10, 100)",
+        bmrMSjRmrcb: 66.00000000000001,
+        FormatCk: "@integer(1, 999)",
+        isAlive: true,
+        isFinish: false,
+        isOver: false,
+        IsPrivate: 1,
+        lastPushDataTime: 1608188947175,
+        lastUpdateTime: 1608188945184,
+        queuePushData: [],
+      },
       rankTimer: null,
       totalTime: '',
       Listate: [
@@ -272,13 +345,13 @@ export default {
     this.cardPlay();
     let pages = 1;
     // 五秒后翻页
-    this.rankTimer = setInterval(() => {
-      this.pages = 2;
-      if (pages == 1) {
-        this.cardPlay();
-        pages = 2;
-      }
-    }, 5000);
+    // this.rankTimer = setInterval(() => {
+    //   this.pages = 2;
+    //   if (pages == 1) {
+    //     this.cardPlay();
+    //     pages = 2;
+    //   }
+    // }, 5000);
   },
   watch: {
     '$route': function (val) {
@@ -507,25 +580,29 @@ export default {
       .center {
         @include cube;
         color: white;
-        font-size: 0.35rem;
+        font-size: 0.4rem;
       }
 
       .ckValue {
         @include cube;
         color: white;
-        height: 0.8rem;
-        line-height: 0.7rem;
+        height: 1rem;
+
+        .winner {
+          color: #FFEB50;
+        }
 
         em {
+          position: relative;
+          bottom: 0.3rem;
+          font-size: 0.8rem;
+          font-weight: bold;
           font-style: normal;
-          font-size: 0.5rem;
         }
       }
 
       .mvp {
         @include cube;
-        margin-top: 0.2rem;
-
         .head {
           @include cube;
           height: 1.6rem;
@@ -536,13 +613,28 @@ export default {
             border-radius: 250rem;
 
             &.girl {
-              border: 0.05rem solid #EA26EA;
+              border: 2px solid #EA26EA;
             }
 
             &.boy {
-              border: 0.05rem solid #39B6FF;
+              border: 2px solid #39B6FF;
             }
           }
+
+          .names {
+            background: rgba(0, 0, 0, 0.7);
+            text-align: center;
+            padding: 1% 1%;
+            border-radius: 250rem;
+            position: relative;
+            width: 1.2rem;
+            height: 0.2rem;
+            line-height: 0.2rem;
+            font-size: 0.2rem;
+            bottom: 0.25rem;
+            color: white;
+            margin: 0 auto;
+          }
         }
 
         .mvpCode {
@@ -638,18 +730,22 @@ export default {
           em {
             float: left;
             color: white;
-            font-size: 0.4rem;
+            font-size: 0.3rem;
             font-style: normal;
+            line-height: 0.6rem;
+            font-weight: bold;
           }
 
           s {
             text-decoration: none;
             float: right;
             text-align: right;
-            font-size: 0.6rem;
+            font-size: 0.75rem;
             color: white;
-            line-height: 0.5rem;
+            line-height: 0.6rem;
             padding: 0 0.2rem;
+            font-weight: bold;
+            font-family: "Arial";
 
             &.winnerSum {
               color: #FFEB50;
@@ -720,6 +816,7 @@ export default {
 
           &:last-child {
             float: right;
+            padding-right: 0.2rem;
           }
         }
       }
@@ -741,6 +838,8 @@ export default {
             background-position: top center;
             background-size: 100% 100%;
             overflow: visible;
+            border: 1px solid rgba(255, 255, 255, 0.1);
+            border-left: 0;
 
             &.redrow {
               background: url("../assets/imgs/3pkRank/redrow.png");
@@ -823,6 +922,7 @@ export default {
             font-weight: bold;
             font-style: italic;
             text-align: center;
+            padding-right: 0.2rem;
           }
         }
       }

+ 1 - 1
v2tv/src/views/Wait.vue

@@ -231,7 +231,7 @@ export default {
   },
   mounted() {
     // test
-    this.$router.push({path: '/threepk'});
+    this.$router.push({path: '/3pkrank'});
 
     this.init();
     this.grpcServe();

+ 16 - 5
v2tv/src/views/threepk.vue

@@ -32,7 +32,7 @@
         </div>
         <div class="md">
           <img class="vsIcon leftVs" src="../assets/imgs/pk/vs.png" alt="">
-          <span :style="{'width':RedProgress+'%'}">
+          <span :style="{'width':BlueProgress+'%'}">
             </span>
           <em>蓝队{{ bluePerson }}人</em>
           <img class="vsIcon rightVs" src="../assets/imgs/pk/vs.png" alt="">
@@ -334,29 +334,39 @@ export default {
       // 当为0时均分
       if (redFmtSum == 0) {
         that.Redflag = 0;
-        that.RedProgress = 22;
+        that.RedProgress = 28;
       } else {
         // 限制最大
         that.Redflag = parseInt((redFmtSum / sumMax) * 100) > 100 ? 100 : parseInt((redFmtSum / sumMax) * 100);
         that.RedProgress = that.Redflag + 28
+        if (that.RedProgress > 75) {
+          that.RedProgress = 75
+        }
       }
 
       if (blueFmtSum == 0) {
         that.BlueFlag = 0;
-        that.BlueProgress = 22;
+        that.BlueProgress = 28;
       } else {
         // 限制最大
         that.BlueFlag = parseInt((blueFmtSum / sumMax) * 100) > 100 ? 100 : parseInt((blueFmtSum / sumMax) * 100);
         that.BlueProgress = that.BlueFlag + 28
+        if (that.BlueProgress > 75) {
+          that.BlueProgress = 75
+        }
+
       }
 
       if (yellowFmtSum == 0) {
         that.yellowFlag = 0;
-        that.yellowProgress = 22;
+        that.yellowProgress = 28;
       } else {
         // 限制最大
         that.yellowFlag = parseInt((yellowFmtSum / sumMax) * 100) > 100 ? 100 : parseInt((blueFmtSum / sumMax) * 100);
         that.yellowProgress = that.yellowFlag + 28
+        if (that.yellowProgress > 75) {
+          that.yellowProgress = 75
+        }
       }
     },
     // 获取上课学生信息
@@ -733,7 +743,8 @@ export default {
   width: 100%;
   position: relative;
   bottom: 1rem;
-  height: 6.5rem;
+  height: 7rem;
+  padding-top: 0.1rem;
 
   .lt {
     @include cube;