wzx %!s(int64=4) %!d(string=hai) anos
pai
achega
64f9e0cbdf

+ 9 - 2
src/Global.js

@@ -5,10 +5,12 @@ companyInfo = {
     year: new Date().getFullYear(),
 };
 
-// APP类型  0: beswell  1: 小飞龙
+// APP类型  0: beswell  1: 小飞龙  2: 健身馆
 // appType = 0;
-appType = 1;
+// appType = 1;
+appType = 2;
 
+// 默认值为beswell的设置
 serverUrl = 'http://bswlt.beswell.com:9002/';           // 数据源地址
 updateUrl = 'http://bcal.beswell.com:85/v1/Sensors/';   // 版本更新源地址
 
@@ -16,6 +18,11 @@ if (appType == 1) {    // 1: 小飞龙
     serverUrl = 'http://bswlt.beswell.com:9000/';
     updateUrl = 'http://cal.beswell.com:85/v1/Sensors/';
 }
+// else if (appType == 2) {    // 2: 健身馆
+//     // serverUrl = 'http://bswlt.beswell.com:9000/';
+//     // updateUrl = 'http://cal.beswell.com:85/v1/Sensors/';
+// }
+
 
 // 本机测试 TV端映射到本机进行测试
 // runVersion = 'localtest';    //tmp mod

+ 4 - 3
src/components/actionScore.vue

@@ -18,8 +18,8 @@
               <em>{{ index + 1 }}</em>
               <div class="head">
                 <img :src="item.Head" alt="" v-if="item.Head" :class="[{'boy':item.Sex == 1},{'girl':item.Sex == 2}]">
-                <img src="../static/img/people/flyhead.png" alt="" v-if="!item.Head"
-                     :class="[{'boy':item.Sex == 1},{'girl':item.Sex == 2}]">
+                <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!item.Head" :class="[{'boy':item.Sex == 1},{'girl':item.Sex == 2}]"> -->
+                <default-head v-if="!item.Head" :class="[{'boy':item.Sex == 1},{'girl':item.Sex == 2}]"></default-head>                
               </div>
               <span class="names">{{ item.Name }}</span>
               <span class="score" v-for="item in item.DetailScore">
@@ -39,6 +39,7 @@
 
 <script>
 import Headside from '@/components/Headside'
+import defaultHead from '@/components/defaultHead'
 import {ClassUserRank} from "@/api/getApiRes";
 
 let qs = require('qs');
@@ -202,7 +203,7 @@ export default {
     },
   },
   components: {
-    Headside
+    Headside, defaultHead
   }
 }
 </script>

+ 26 - 0
src/components/defaultHead.vue

@@ -0,0 +1,26 @@
+<template>
+  <img src="../static/img/people/flyhead.png" v-if="appType == 1">
+  <img src="../static/img/people/jsgHead.png" v-else-if="appType == 2">
+  <img src="../static/img/people/bswHead.png" v-else>
+</template>
+
+<script>
+// import global from '../Global'
+export default {
+  data() {
+    return {
+      appType: appType,
+    };
+  },
+  // props: [''],
+}
+</script>
+
+<style lang="scss" scoped>
+
+// img {
+//   width: 0.33rem;
+//   line-height: 0.3rem;
+// }
+
+</style>

+ 8 - 2
src/components/newRecord.vue

@@ -5,8 +5,9 @@
         <div class="toper">
           <img :src="toperInfo.toper.Head" alt="" v-if="toperInfo.toper.Head"
                :class="[{'boy':toperInfo.toper.Sex == 1},{'girl':toperInfo.toper.Sex == 2}]">
-          <img src="../static/img/people/flyhead.png" alt="" v-if="!toperInfo.toper.Head"
-               :class="[{'boy':toperInfo.toper.Sex == 1},{'girl':toperInfo.toper.Sex == 2}]">
+          <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!toperInfo.toper.Head"
+               :class="[{'boy':toperInfo.toper.Sex == 1},{'girl':toperInfo.toper.Sex == 2}]"> -->
+          <default-head v-if="!toperInfo.toper.Head" :class="[{'boy':toperInfo.toper.Sex == 1},{'girl':toperInfo.toper.Sex == 2}]"></default-head>
           <span class="names">{{ toperInfo.toper.UserName }}</span>
         </div>
         <div class="info">
@@ -24,6 +25,8 @@
 </template>
 
 <script>
+import defaultHead from '@/components/defaultHead'
+
 export default {
   data() {
     return {
@@ -56,6 +59,9 @@ export default {
       }
     },
   },
+  components: {
+    defaultHead
+  }
 }
 </script>
 

+ 7 - 1
src/components/newStudent.vue

@@ -6,7 +6,8 @@
           <li v-for="(s,i) in studentInfo.Rs.slice(0, maxShowNum)"
               :class="[{'bigLi':studentInfo.Rs.length <= 4}, {'smallLi':studentInfo.Rs.length > 10}]">
             <img :src="s.Head" alt="" v-if="s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
-            <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
+            <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"> -->
+            <default-head v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"></default-head>
             <span class="names">{{ s.Name }}</span>
           </li>
         </ul>
@@ -17,6 +18,8 @@
 </template>
 
 <script>
+import defaultHead from '@/components/defaultHead'
+
 export default {
   data() {
     return {
@@ -43,6 +46,9 @@ export default {
       deep: true,
       immediate: true
     }
+  },
+  components: {
+    defaultHead
   }
 }
 </script>

+ 4 - 2
src/components/pkstudent.vue

@@ -17,7 +17,8 @@
           <div class="md">
             <div class="head">
               <img :src="s.Head" alt="" v-if="s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
-              <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
+              <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"> -->
+              <default-head v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"></default-head>
               <div class="names">
               <span>
                   {{ s.Name }}
@@ -75,6 +76,7 @@
 </template>
 <script>
 import power from '@/components/power'
+import defaultHead from '@/components/defaultHead'
 
 export default {
   data() {
@@ -186,7 +188,7 @@ export default {
     }
   },
   components: {
-    power
+    power, defaultHead
   }
 }
 </script>

+ 4 - 4
src/components/power.vue

@@ -11,10 +11,10 @@
 </template>
 
 <script>
-    import '../libs/rem';
-    export default {
-        props: ['curPower', 'curHr'],
-    }
+import '../libs/rem';
+export default {
+  props: ['curPower', 'curHr'],
+}
 </script>
 
 <style lang="scss" scoped>

+ 10 - 8
src/components/student.vue

@@ -17,7 +17,8 @@
           <div class="md">
             <div class="head">
               <img :src="s.Head" alt="" v-if="s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
-              <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
+              <!-- <img src="../static/img/people/bswHead.png" alt="" v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"> -->
+              <default-head v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"></default-head>
               <div class="names">
               <span>
                   {{ s.Name }}
@@ -75,6 +76,7 @@
 </template>
 <script>
 import power from '@/components/power'
+import defaultHead from '@/components/defaultHead'
 
 export default {
   data() {
@@ -218,7 +220,7 @@ export default {
     }
   },
   components: {
-    power
+    power, defaultHead
   }
 }
 </script>
@@ -403,7 +405,7 @@ ul {
       @include cube;
       height: 3rem;
 
-      img {
+      /deep/ img {
         @include cube;
         width: 2.6rem;
         height: 2.6rem;
@@ -567,7 +569,7 @@ ul {
       width: 30%;
       height: 2.5rem;
       
-      .head {
+      /deep/ .head {
         height: 2.7rem;
 
         img {
@@ -667,7 +669,7 @@ ul {
     .md {
       height: 2.5rem;
       
-      .head {
+      /deep/ .head {
         height: 2.6rem;
 
         img {
@@ -769,7 +771,7 @@ ul {
       width: 30%;
       height: 1.8rem;
       
-      .head {
+      /deep/ .head {
         height: 1.7rem;
 
         img {
@@ -885,7 +887,7 @@ ul {
       height: 1.5rem;
       padding-top: 0.1rem;
       
-      .head {
+      /deep/ .head {
         height: 1.4rem;
 
         img {
@@ -1014,7 +1016,7 @@ ul {
       height: 1.0rem;
       padding-top: 0.06rem;
       
-      .head {
+      /deep/ .head {
         height: 1.1rem;
 
         img {

+ 4 - 2
src/components/threestudent.vue

@@ -17,7 +17,8 @@
           <div class="md">
             <div class="head">
               <img :src="s.Head" alt="" v-if="s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
-              <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
+              <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"> -->
+              <default-head v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"></default-head>
               <div class="names">
               <span>
                   {{ s.Name }}
@@ -75,6 +76,7 @@
 </template>
 <script>
 import power from '@/components/power'
+import defaultHead from '@/components/defaultHead'
 
 export default {
   data() {
@@ -185,7 +187,7 @@ export default {
     }
   },
   components: {
-    power
+    power, defaultHead
   }
 }
 </script>

BIN=BIN
src/static/img/people/bswHead.png


BIN=BIN
src/static/img/people/bswHead2.png


BIN=BIN
src/static/img/people/jsgHead.png


+ 15 - 10
src/views/2pkRank.vue

@@ -22,8 +22,9 @@
               <div class="head">
                 <img :src="redMvp.Head" alt="" v-if="redMvp.Head"
                     :class="[{'boy':redMvp.Sex == 1},{'girl':redMvp.Sex == 2}]">
-                <img src="../static/img/people/flyhead.png" alt="" v-if="!redMvp.Head" 
-                    :class="[{'boy':redMvp.Sex == 1},{'girl':redMvp.Sex == 2}]">
+                <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!redMvp.Head" 
+                    :class="[{'boy':redMvp.Sex == 1},{'girl':redMvp.Sex == 2}]"> -->
+                <default-head v-if="!redMvp.Head" :class="[{'boy':redMvp.Sex == 1},{'girl':redMvp.Sex == 2}]"></default-head>
                 <div class="names">
                 <span>
                     {{ redMvp.Name }}
@@ -56,8 +57,9 @@
               <div class="head">
                 <img :src="blueMvp.Head" alt="" v-if="blueMvp.Head"
                     :class="[{'boy':blueMvp.Sex == 1},{'girl':blueMvp.Sex == 2}]">
-                <img src="../static/img/people/flyhead.png" alt="" v-if="!blueMvp.Head"
-                    :class="[{'boy':blueMvp.Sex == 1},{'girl':blueMvp.Sex == 2}]">
+                <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!blueMvp.Head"
+                    :class="[{'boy':blueMvp.Sex == 1},{'girl':blueMvp.Sex == 2}]"> -->
+                <default-head v-if="!blueMvp.Head" :class="[{'boy':blueMvp.Sex == 1},{'girl':blueMvp.Sex == 2}]"></default-head>
                 <div class="names">
                 <span>
                     {{ blueMvp.Name }}
@@ -119,8 +121,9 @@
                 <em>{{ i + 1 }}</em>
                 <div class="head">
                   <img :src="s.Head" alt="" v-if="s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
-                  <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
-                       :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
+                  <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
+                       :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"> -->
+                  <default-head v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"></default-head>
                 </div>
                 <span class="names">{{ s.Name }}</span>
                 <span class="glory">
@@ -148,8 +151,9 @@
                 <em>{{ i + 1 }}</em>
                 <div class="head">
                   <img :src="s.Head" alt="" v-if="s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
-                  <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
-                       :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
+                  <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
+                       :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"> -->
+                  <default-head v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"></default-head>
                 </div>
                 <span class="names">{{ s.Name }}</span>
                 <span class="glory">
@@ -181,7 +185,8 @@
 
 <script>
 import Headside from '@/components/Headside'
-import {ClassUserRank, AddPkInfo} from "@/api/getApiRes";
+import defaultHead from '@/components/defaultHead'
+import {ClassUserRank, AddPkInfo} from "@/api/getApiRes"
 import eiRank from '@/components/eiRank'
 
 let qs = require('qs');
@@ -594,7 +599,7 @@ export default {
     },
   },
   components: {
-    Headside, eiRank
+    Headside, defaultHead, eiRank
   }
 }
 </script>

+ 21 - 14
src/views/3pkRank.vue

@@ -19,8 +19,9 @@
             <div class="head">
               <img :src="teamRank[1].mvp.Head" alt="" v-if="teamRank[1].mvp.Head"
                   :class="[{'boy':teamRank[1].mvp.Sex == 1},{'girl':teamRank[1].mvp.Sex == 2}]">
-              <img src="../static/img/people/flyhead.png" alt="" v-if="!teamRank[1].mvp.Head"
-                  :class="[{'boy':teamRank[1].mvp.Sex == 1},{'girl':teamRank[1].mvp.Sex == 2}]">
+              <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!teamRank[1].mvp.Head"
+                  :class="[{'boy':teamRank[1].mvp.Sex == 1},{'girl':teamRank[1].mvp.Sex == 2}]"> -->
+              <default-head v-if="!teamRank[1].mvp.Head" :class="[{'boy':teamRank[1].mvp.Sex == 1},{'girl':teamRank[1].mvp.Sex == 2}]"></default-head>
               <div class="names">
               <span>
                   {{ teamRank[1].mvp.Name }}
@@ -51,8 +52,9 @@
               <div class="head">
                 <img :src="teamRank[0].mvp.Head" alt="" v-if="teamRank[0].mvp.Head"
                     :class="[{'boy':teamRank[0].mvp.Sex == 1},{'girl':teamRank[0].mvp.Sex == 2}]">
-                <img src="../static/img/people/flyhead.png" alt="" v-if="!teamRank[0].mvp.Head"
-                    :class="[{'boy':teamRank[0].mvp.Sex == 1},{'girl':teamRank[0].mvp.Sex == 2}]">
+                <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!teamRank[0].mvp.Head"
+                    :class="[{'boy':teamRank[0].mvp.Sex == 1},{'girl':teamRank[0].mvp.Sex == 2}]"> -->
+                <default-head v-if="!teamRank[0].mvp.Head" :class="[{'boy':teamRank[0].mvp.Sex == 1},{'girl':teamRank[0].mvp.Sex == 2}]"></default-head>
                 <div class="names">
                 <span>
                   {{ teamRank[0].mvp.Name }}
@@ -82,8 +84,9 @@
               <div class="head">
                 <img :src="teamRank[2].mvp.Head" alt="" v-if="teamRank[2].mvp.Head"
                     :class="[{'boy':teamRank[2].mvp.Sex == 1},{'girl':teamRank[2].mvp.Sex == 2}]">
-                <img src="../static/img/people/flyhead.png" alt="" v-if="!teamRank[2].mvp.Head"
-                    :class="[{'boy':teamRank[2].mvp.Sex == 1},{'girl':teamRank[2].mvp.Sex == 2}]">
+                <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!teamRank[2].mvp.Head"
+                    :class="[{'boy':teamRank[2].mvp.Sex == 1},{'girl':teamRank[2].mvp.Sex == 2}]"> -->
+                <default-head v-if="!teamRank[2].mvp.Head" :class="[{'boy':teamRank[2].mvp.Sex == 1},{'girl':teamRank[2].mvp.Sex == 2}]"></default-head>
                 <div class="names">
                 <span>
                     {{ teamRank[2].mvp.Name }}
@@ -158,8 +161,9 @@
                 <em>{{ i + 1 }}</em>
                 <div class="head">
                   <img :src="s.Head" alt="" v-if="s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
-                  <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
-                       :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
+                  <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
+                       :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"> -->
+                  <default-head v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"></default-head>
                 </div>
                 <span class="names">{{ s.Name }}</span>
                 <span class="glory">
@@ -188,8 +192,9 @@
                 <em>{{ i + 1 }}</em>
                 <div class="head">
                   <img :src="s.Head" alt="" v-if="s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
-                  <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
-                       :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
+                  <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
+                       :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"> -->
+                  <default-head v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"></default-head>
                 </div>
                 <span class="names">{{ s.Name }}</span>
                 <span class="glory">
@@ -218,8 +223,9 @@
                 <em>{{ i + 1 }}</em>
                 <div class="head">
                   <img :src="s.Head" alt="" v-if="s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
-                  <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
-                       :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
+                  <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
+                       :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"> -->
+                  <default-head v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"></default-head>
                 </div>
                 <span class="names">{{ s.Name }}</span>
                 <span class="glory">
@@ -251,7 +257,8 @@
 
 <script>
 import Headside from '@/components/Headside'
-import {ClassUserRank, AddPkInfo} from "@/api/getApiRes";
+import defaultHead from '@/components/defaultHead'
+import {ClassUserRank, AddPkInfo} from "@/api/getApiRes"
 import eiRank from '@/components/eiRank'
 
 let qs = require('qs');
@@ -857,7 +864,7 @@ export default {
     },
   },
   components: {
-    Headside, eiRank
+    Headside, defaultHead, eiRank
   }
 }
 </script>

+ 9 - 6
src/views/Rank.vue

@@ -30,8 +30,9 @@
                 <em>{{ i + 1 }}</em>
                 <div class="head">
                   <img :src="s.Head" alt="" v-if="s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
-                  <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
-                      :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
+                  <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
+                      :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"> -->
+                  <default-head v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"></default-head>
                 </div>
                 <span class="names">{{ s.Name }}</span>
                 <span class="glory">
@@ -57,8 +58,9 @@
                 <em>{{ i + 1 }}</em>
                 <div class="head">
                   <img :src="s.Head" alt="" v-if="s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
-                  <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
-                      :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
+                  <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
+                      :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"> -->
+                  <default-head v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"></default-head>
                 </div>
                 <span class="names">{{ s.Name }}</span>
                 <span class="glory">
@@ -89,7 +91,8 @@
 
 <script>
 import Headside from '@/components/Headside'
-import {ClassUserRank} from "@/api/getApiRes";
+import defaultHead from '@/components/defaultHead'
+import {ClassUserRank} from "@/api/getApiRes"
 import eiRank from '@/components/eiRank'
 
 let qs = require('qs');
@@ -300,7 +303,7 @@ export default {
     },
   },
   components: {
-    Headside, eiRank
+    Headside, defaultHead, eiRank
   }
 }
 </script>

+ 12 - 8
src/views/Rank2.vue

@@ -32,8 +32,9 @@
               <em>{{ i + 1 }}</em>
               <div class="head">
                 <img :src="s.Head" alt="" v-if="s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
-                <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
-                     :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
+                <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
+                     :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"> -->
+                <default-head v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"></default-head>
               </div>
               <span class="names">{{ s.Name }}</span>
               <span class="glory">
@@ -61,8 +62,9 @@
               <em>{{ i + 1 }}</em>
               <div class="head">
                 <img :src="s.Head" alt="" v-if="s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
-                <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
-                     :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
+                <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
+                     :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"> -->
+                <default-head v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"></default-head>
               </div>
               <span class="names">{{ s.Name }}</span>
               <span class="glory">
@@ -90,8 +92,9 @@
               <em>{{ i + 1 }}</em>
               <div class="head">
                 <img :src="s.Head" alt="" v-if="s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
-                <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
-                     :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]">
+                <!-- <img src="../static/img/people/flyhead.png" alt="" v-if="!s.Head"
+                     :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"> -->
+                <default-head v-if="!s.Head" :class="[{'boy':s.Sex == 1},{'girl':s.Sex == 2}]"></default-head>
               </div>
               <span class="names">{{ s.Name }}</span>
               <span class="glory">
@@ -116,7 +119,8 @@
 
 <script>
 import Headside from '@/components/Headside'
-import {ClassUserRank} from "@/api/getApiRes";
+import defaultHead from '@/components/defaultHead'
+import {ClassUserRank} from "@/api/getApiRes"
 
 let qs = require('qs');
 export default {
@@ -289,7 +293,7 @@ export default {
     },
   },
   components: {
-    Headside
+    Headside, defaultHead
   }
 }
 </script>

+ 17 - 7
src/views/Wait.vue

@@ -16,7 +16,8 @@
           <li v-for="(s,i) in calcWeekRank" v-show="Listate[i].state" :class="[{ 'box animate__animated animate__flipInX': Listate[i].state }]">
             <div class="num">{{ i + 1 }}</div>
             <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" :src="s.Head" alt="" v-if="s.Head">
-            <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" v-bind:src="require('../static/img/people/flyhead.png')" alt="学生头像" v-if="!s.Head">
+            <!-- <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" v-bind:src="require('../static/img/people/flyhead.png')" alt="学生头像" v-if="!s.Head"> -->
+            <default-head v-if="!s.Head" :class="[{'headImg':true},{'girl':s.Sex == 2}]"></default-head>
             <span>{{ s.UserName }}</span>
             <!-- <img class="crIcon" v-bind:src="require('../assets/imgs/rank/cr.png')" v-if="i == 0" alt=""> -->
             <img class="pbIcon" src="../assets/imgs/rank/pb.png" v-if="s.IsBreaking == 1" alt="">
@@ -47,7 +48,8 @@
             <li v-for="(s,index) in Heros">
               <div class="person">
                 <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" :src="s.Head" alt="" v-if="s.Head">
-                <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" v-bind:src="require('../static/img/people/flyhead.png')" alt="学生头像" v-if="!s.Head">
+                <!-- <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" v-bind:src="require('../static/img/people/flyhead.png')" alt="学生头像" v-if="!s.Head"> -->
+                <default-head v-if="!s.Head" :class="[{'headImg':true},{'girl':s.Sex == 2}]"></default-head>
                 <span class="name">{{ s.UserName }}</span>
                 <div class="calcHero">
                   <img src="../assets/imgs/wait/calcIcon.svg" alt="">
@@ -79,7 +81,8 @@
           <li v-for="(s,i) in CKWeekRank" v-show="Listate[i].state" :class="[{ 'box animate__animated animate__flipInX': Listate[i].state }]">
             <div class="num">{{ i + 1 }}</div>
             <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" :src="s.Head" alt="" v-if="s.Head">
-            <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" v-bind:src="require('../static/img/people/flyhead.png')" alt="学生头像" v-if="!s.Head">
+            <!-- <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" v-bind:src="require('../static/img/people/flyhead.png')" alt="学生头像" v-if="!s.Head"> -->
+            <default-head v-if="!s.Head" :class="[{'headImg':true},{'girl':s.Sex == 2}]"></default-head>
             <span>{{ s.UserName }}</span>
             <!-- <img class="crIcon" v-bind:src="require('../assets/imgs/rank/cr.png')" v-if="i == 0" alt=""> -->
             <img class="pbIcon" src="../assets/imgs/rank/pb.png" v-if="s.IsBreaking == 1" alt="">
@@ -106,7 +109,8 @@
           <li v-for="(s,t) in calcMouthRank" v-show="Listate[t].state" :class="[{ 'box animate__animated animate__flipInX': Listate[t].state }]">
             <div class="num">{{ t + 1 }}</div>
             <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" :src="s.Head" alt="" v-if="s.Head">
-            <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" v-bind:src="require('../static/img/people/flyhead.png')" alt="学生头像" v-if="!s.Head">
+            <!-- <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" v-bind:src="require('../static/img/people/flyhead.png')" alt="学生头像" v-if="!s.Head"> -->
+            <default-head v-if="!s.Head" :class="[{'headImg':true},{'girl':s.Sex == 2}]"></default-head>
             <span>{{ s.UserName }}</span>
             <!-- <img class="crIcon" v-bind:src="require('../assets/imgs/rank/cr.png')" v-if="t == 0" alt=""> -->
             <img class="pbIcon" src="../assets/imgs/rank/pb.png" v-if="s.IsBreaking == 1" alt="">
@@ -136,7 +140,8 @@
             <li v-for="(s,index) in ClassNumToper">
               <div class="person">
                 <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" :src="s.Head" alt="" v-if="s.Head">
-                <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" v-bind:src="require('../static/img/people/flyhead.png')" alt="学生头像" v-if="!s.Head">
+                <!-- <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" v-bind:src="require('../static/img/people/flyhead.png')" alt="学生头像" v-if="!s.Head"> -->
+                <default-head v-if="!s.Head" :class="[{'headImg':true},{'girl':s.Sex == 2}]"></default-head>
                 <span class="name">{{ s.UserName }}</span>
                 <div class="calcHero">
                   <img src="../assets/imgs/wait/classNum.svg" alt="">
@@ -161,7 +166,8 @@
           <li v-for="(s,i) in CKMonthRank" v-show="Listate[i].state" :class="[{ 'box animate__animated animate__flipInX': Listate[i].state }]">
             <div class="num">{{ i + 1 }}</div>
             <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" :src="s.Head" alt="" v-if="s.Head">
-            <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" v-bind:src="require('../static/img/people/flyhead.png')" alt="学生头像" v-if="!s.Head">
+            <!-- <img :class="[{'headImg':true},{'girl':s.Sex == 2}]" v-bind:src="require('../static/img/people/flyhead.png')" alt="学生头像" v-if="!s.Head"> -->
+            <default-head v-if="!s.Head" :class="[{'headImg':true},{'girl':s.Sex == 2}]"></default-head>
             <span>{{ s.UserName }}</span>
             <!-- <img class="crIcon" v-bind:src="require('../assets/imgs/rank/cr.png')" v-if="i == 0" alt=""> -->
             <img class="pbIcon" src="../assets/imgs/rank/pb.png" v-if="s.IsBreaking == 1" alt="">
@@ -183,6 +189,8 @@
 
 <script>
 import Headside from '@/components/Headside'
+import defaultHead from '@/components/defaultHead'
+
 import '../libs/rem';
 import '../Global'
 import {
@@ -196,7 +204,9 @@ import {
 import audio from '../static/sound/bell.wav'
 import {SignInPasswordRequest} from "@/grpc/im_pb";
 import { stringify } from 'qs';
+
 let qs = require('qs');
+
 export default {
   data() {
     return {
@@ -464,7 +474,7 @@ export default {
     },
   },
   components: {
-    Headside
+    Headside, defaultHead
   }
 }
 </script>