Prechádzať zdrojové kódy

个性化错题-暂不上线

吴朋磊 2 mesiacov pred
rodič
commit
4628fc4dcc

+ 6 - 2
src/views/analysisReport/studentPage/mainPage.vue

@@ -34,9 +34,9 @@
                                 <button class="mm_btn mb_10" :class="{ active: activeBtn === pathOne }"
                                     @click="toPage(pathOne)">成绩分析</button>
 
-                                <button class="mm_btn mb_10" :class="{ active: activeBtn === pathTwo }"
+                                <button v-if="isShowKnowledgeButtons" class="mm_btn mb_10" :class="{ active: activeBtn === pathTwo }"
                                     @click="toPage(pathTwo)">个性化错题</button>
-                                <button class="mm_btn mb_10" :class="{ active: activeBtn === pathThree }"
+                                <button  class="mm_btn mb_10" :class="{ active: activeBtn === pathThree }"
                                     @click="toPage(pathThree)">个人画像</button>
                             </div>
 
@@ -76,6 +76,10 @@ export default {
         updateScrollTop() {
             return this.$store.state.report.updateScrollTop;//监听改变滚动条参数 
         },
+        isShowKnowledgeButtons() {
+            // 从环境变量中获取基础URL,判断是否显示按钮
+            return process.env.VUE_APP_BASE !== 'https://www.k12100.com';
+        },
         // 判断是否为总分科目,用于控制个人画像按钮显示
         isTotalScore() {
             return this.$store.state.report.isTotalScore;