Browse Source

fix:没有名称的情况

xuqiaoying 3 years ago
parent
commit
aead832b41
2 changed files with 5 additions and 3 deletions
  1. 2 2
      src/axios.js
  2. 3 1
      src/pages/person-center/my-course/index.vue

+ 2 - 2
src/axios.js

@@ -3,9 +3,9 @@ import store from './store'
 import { Message } from 'element-ui'
 // export const BASE_URL = 'https://api.xyyxt.net'   //release
 // export const BASE_URL = 'http://42.192.164.187:19005'    //test
-// export const BASE_URL = 'https://test.xyyxt.net'   //预发布
+export const BASE_URL = 'https://test.xyyxt.net'   //预发布
 // export const BASE_URL = 'http://192.168.1.7:5055'    //dev
-export const BASE_URL = 'http://120.79.166.78:19012'    //测试-外网
+// export const BASE_URL = 'http://120.79.166.78:19012'    //测试-外网
 // export const BASE_URL = 'http://42.192.164.187:19005'    //test
 // export const BASE_URL = 'http://192.168.1.222:5055'    //测试
 export const tenantId = '867735392558919680'

+ 3 - 1
src/pages/person-center/my-course/index.vue

@@ -40,6 +40,7 @@
         </el-button>
       </h4>
       <div style="margin: 14px 0px">
+
         <el-button
           size="small"
           v-for="(item, index) in subjectList"
@@ -650,7 +651,8 @@ export default {
               id: "",
               name: "全部",
             });
-            this.subjectList = array;
+            // this.subjectList = array;
+            this.subjectList = array.filter((item) => item.name)
             this.newActiveSubjectId = "";
             resolve();
             // if (res.rows && res.rows.length > 0) {