Changpeng Duan před 4 roky
rodič
revize
596e9808e8

+ 13 - 12
v2tv/src/Mock/index.js

@@ -120,7 +120,7 @@ let getUserList = function () {
 let testStudent = function (num, team, mustbeTeamOne) {
     let item = [];
     let group = team == 2 ? "@integer(1, 2)" : "@integer(1, 3)";
-    group = 1;
+    // group = 1;
     if (mustbeTeamOne) {
         group = mustbeTeamOne;
     }
@@ -197,7 +197,7 @@ let testStudent = function (num, team, mustbeTeamOne) {
 let getNewUser = function (code, t) {
 
     let item = [];
-    for (var i = 0; i <= t; i++) {
+    for (var i = 0; i < t; i++) {
         item.push({
             "SvId": "@guid",
             "UserId": "@integer(15253135600, 15253135699)",
@@ -403,31 +403,32 @@ if (t == 1) {
     // 0: 下课 团课/私教/PK 的排名
     let LessonClass = 1;
     let LessonDp = 1;
+    console.log(123);
     // 1:团课/私教
     // 2:竞技课2PK
     // 3:竞技课threepk
 
-    // 人数  1 3 5 9  11
+    // 人数  1 3 5 10 17
     if (LessonClass == 1) {
         // 上团课
         Mock.mock(curheadapi + 'ClassStatQuery', 'post', getClassStat(1, 1));
         Mock.mock(Mockapi + 'ClassStatQuery', 'post', getClassStat(1, 1));
         Mock.mock(curheadapi + 'UserListInfo', 'post', testStudent(1, 1));//true
-        Mock.mock(Mockapi + 'UserListInfo', 'post', testStudent(1, 1)); //
+        Mock.mock(Mockapi + 'UserListInfo', 'post', testStudent(25, 2)); //
     } else if (LessonClass == 2) {
         // 上2队PK课
         Mock.mock(curheadapi + 'ClassStatQuery', 'post', getClassStat(1, 2));
         Mock.mock(Mockapi + 'ClassStatQuery', 'post', getClassStat(1, 2));
-        Mock.mock(curheadapi + 'UserListInfo', 'post', testStudent(8, 1,));
-        Mock.mock(Mockapi + 'UserListInfo', 'post', testStudent(6, 1,));
+        Mock.mock(curheadapi + 'UserListInfo', 'post', testStudent(9, 1,));
+        Mock.mock(Mockapi + 'UserListInfo', 'post', testStudent(8, 1,));
     } else if (LessonClass == 3) {
         // 上3队PK课
         Mock.mock(curheadapi + 'ClassStatQuery', 'post', getClassStat(1, 3));
         Mock.mock(Mockapi + 'ClassStatQuery', 'post', getClassStat(1, 3));
         Mock.mock(curheadapi + 'UserListInfo', 'post', testStudent(2, 3,));
-        Mock.mock(Mockapi + 'UserListInfo', 'post', testStudent(6, 3,));
+        Mock.mock(Mockapi + 'UserListInfo', 'post', testStudent(12, 3,));
         Mock.mock(curheadapi + 'ClassUserRank', 'post', testStudent(1, 2));
-        Mock.mock(Mockapi + 'ClassUserRank', 'post', testStudent(1, 2));
+        Mock.mock(Mockapi + 'ClassUserRank', 'post', testStudent(1, 3));
     } else if (LessonClass == 0) {
         // 下课
         if (LessonDp == 0) {
@@ -468,11 +469,11 @@ if (t == 1) {
     Mock.mock(curheadapi + 'UserRankingQuery', 'post', UserRankingQuery(8));
     Mock.mock(Mockapi + 'UserRankingQuery', 'post', UserRankingQuery(8));
     // 新同学 0 999
-    Mock.mock(curheadapi + 'getNewUser', 'post', getNewUser(999, 12));
-    Mock.mock(Mockapi + 'getNewUser', 'post', getNewUser(999, 12));
+    Mock.mock(curheadapi + 'getNewUser', 'post', getNewUser(0, 2));
+    Mock.mock(Mockapi + 'getNewUser', 'post', getNewUser(0, 2));
     // 彩蛋 0 999
-    Mock.mock(curheadapi + 'getRecordBreak', 'post', getRecordBreak(0));
-    Mock.mock(Mockapi + 'getRecordBreak', 'post', getRecordBreak(0));
+    Mock.mock(curheadapi + 'getRecordBreak', 'post', getRecordBreak(999));
+    Mock.mock(Mockapi + 'getRecordBreak', 'post', getRecordBreak(999));
 }
 
 export default Mock;

+ 7 - 7
v2tv/src/components/newRecord.vue

@@ -74,8 +74,8 @@ export default {
   top: 0;
   left: 0;
   right: 0;
-  bottom: 0;
-  width: 6.5rem;
+  bottom: 0.5rem;
+  width: 6.2rem;
   //background: url("../assets/imgs/newRecord/bg.svg");
   background: url("../assets/imgs/newRecord/newRecordBg.svg");
   background-position: top center;
@@ -84,8 +84,6 @@ export default {
   box-shadow: none;
   background-color: transparent;
   margin-top: 0 !important;
-
-
 }
 
 .eggContainer {
@@ -94,7 +92,7 @@ export default {
   .eggBg {
     @include cube;
     //background: url("../assets/imgs/newRecord/bg.svg");
-    padding-left: 5%;
+    padding-left: 3%;
     background-position: top center;
     background-repeat: no-repeat;
     background-size: 100%;
@@ -104,7 +102,7 @@ export default {
     .toper {
       @include cube;
       position: relative;
-      top: -50%;
+      bottom: 0.2rem;
 
       img {
         @include cube;
@@ -137,7 +135,7 @@ export default {
   }
 
   .type {
-    height: 2rem;
+    height: 1.8rem;
     color: white;
     font-weight: bold;
     font-size: 0.8rem;
@@ -149,6 +147,8 @@ export default {
     @include cube;
 
     em {
+      position: relative;
+      bottom: 0.1rem;
       @include cube;
       font-weight: bold;
       font-size: 1.1rem;

+ 1 - 1
v2tv/src/components/newStudent.vue

@@ -92,7 +92,7 @@ ul {
   &.two {
     justify-content: space-between;
     padding-top: 20%;
-    width: 80%;
+    width: 40%;
 
     .bigLi img {
       width: 1.9rem;

+ 1 - 1
v2tv/src/components/student.vue

@@ -608,7 +608,7 @@ ul {
 
   .IsPrivate {
     bottom: 2.65rem;
-    right: 0.1rem;
+    right: 0rem;
   }
 
   .names {

+ 2 - 2
v2tv/src/components/threestudent.vue

@@ -568,7 +568,7 @@ ul {
     }
 
     img {
-      width: 0.4rem;
+      width: 0.3rem;
       margin-right: 10%;
     }
   }
@@ -825,7 +825,7 @@ ul {
     padding-right: 5%;
 
     img {
-      width: 0.2rem;
+      width: 0.15rem;
       margin-right: 5%;
     }
 

+ 4 - 0
v2tv/src/grpc/readme.md

@@ -4,6 +4,10 @@
 
 执行gen.bat 重新生成服务文件
 
+### 安装依赖
+
+cnpm i google-protobuf cnpm install --save grpc-web
+
 ### 使用
 
 #### 单页引用

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

@@ -174,7 +174,7 @@ let qs = require('qs');
 export default {
   data() {
     return {
-      pages: 2,
+      pages: 1,
       eqSn: '30:9C:23:0C:8B:1E',
       pageStyle: RandomBg(),
       redMvp: {
@@ -285,7 +285,7 @@ export default {
     //   this.pages = 2;
     //   if (pages == 1) {
     this.cardPlay();
-    pages = 2;
+    pages = 1;
     //   }
     // }, 5000);
   },

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

@@ -782,7 +782,7 @@ export default {
 
       img:nth-child(2) {
         float: right;
-        right: 33%;
+        right: 32%;
       }
     }
 
@@ -793,7 +793,7 @@ export default {
       bottom: 1.5rem;
 
       .lt {
-        width: 33.33%;
+        width: 32.5%;
         float: left;
       }
 
@@ -803,7 +803,7 @@ export default {
       }
 
       .rt {
-        width: 33.33%;
+        width: 32.5%;
         float: right;
       }
 

+ 4 - 2
v2tv/src/views/Wait.vue

@@ -231,8 +231,10 @@ export default {
   },
   mounted() {
     // test
+    // this.$router.push({path: '/rank'});
+    // this.$router.push({path: '/2pkrank'});
     // this.$router.push({path: '/threepk'});
-    // this.$router.push({path: '/3pkrank'});
+    this.$router.push({path: '/3pkrank'});
 
     this.init();
     this.grpcServe();
@@ -243,7 +245,7 @@ export default {
         this.page = !this.page;
         this.init();
         this.cardPlay();
-      }, 30000)
+      }, 6000)
     }
     this.cardPlay();
   },

+ 2 - 2
v2tv/src/views/pk.vue

@@ -648,8 +648,8 @@ export default {
   @include cube;
   width: 88%;
   position: relative;
-  bottom: 1rem;
-  height: 7.45rem;
+  bottom: 1.1rem;
+  height: 7.4rem;
 
   .lt {
     @include cube;

+ 1 - 0
v2tv/src/views/threepk.vue

@@ -716,6 +716,7 @@ export default {
       &.rightVs {
         float: right;
         left: 0.7rem;
+        bottom: 0.65rem;
       }
     }