lex-xin há 4 meses atrás
pai
commit
c4aa2f2638

Diff do ficheiro suprimidas por serem muito extensas
+ 0 - 0
dist/app.ca05be327855a8ebf848.js


Diff do ficheiro suprimidas por serem muito extensas
+ 0 - 0
dist/css/creation.86a55b52.css


Diff do ficheiro suprimidas por serem muito extensas
+ 0 - 0
dist/css/creationindex-share.acd145cf.css


Diff do ficheiro suprimidas por serem muito extensas
+ 1 - 0
dist/index.html


Diff do ficheiro suprimidas por serem muito extensas
+ 1 - 0
dist/js/creation.8ff913e2.js


Diff do ficheiro suprimidas por serem muito extensas
+ 1 - 0
dist/js/creation.ed3dd534.js


Diff do ficheiro suprimidas por serem muito extensas
+ 0 - 0
dist/js/creationindex-share.a6811590.js


+ 2 - 17
src/common/common.js

@@ -168,22 +168,7 @@ const _throttle = (fn, time) => {
 //       }, 200)
 //   }
 // }
-// 学生地址
-const validStudentUrl = () => {
-  let url = window.location.hostname;
-  let returnUrl = "";
-  if (/test/.test(url)) {
-    // test环境
-    returnUrl = "https://test.gym.lexiaoya.cn/mdaya";
-  } else if (/dev/.test(url)) {
-    // dev 环境
-    returnUrl = "https://dev.gym.lexiaoya.cn/mdaya";
-  } else {
-    //线上
-    returnUrl = "https://gym.lexiaoya.cn/mdaya";
-  }
-  return returnUrl;
-};
+
 
 /**
  * 转换金额为保留2位小数
@@ -256,4 +241,4 @@ export const removeAuthToken = (type) => {
     lStorage.remove("Authorization");
   }
 };
-export { browser, calcMinute, getSTD, getYMD, getDateList, _debounce, _throttle, validStudentUrl, changeTwoDecimal };
+export { browser, calcMinute, getSTD, getYMD, getDateList, _debounce, _throttle, changeTwoDecimal };

+ 16 - 0
src/common/util.js

@@ -156,6 +156,7 @@ export function checkPhone(phoneNumber) {
   return result;
 }
 
+
 // 学生地址
 export function validStudentUrl() {
   let url = window.location.hostname;
@@ -190,6 +191,21 @@ export function validTeacherUrl() {
   return returnUrl;
 }
 
+export function vaildMusicScoreUrl() {
+  const url = window.location.hostname
+  let returnUrl = ""
+  if (/dev/.test(url) || /192.168/.test(url)) {
+     returnUrl = "https://test.gym.lexiaoya.cn"
+  } else if (/test/.test(url)) {
+     // test 环境
+     returnUrl = "https://test.gym.lexiaoya.cn"
+  } else {
+     returnUrl = "https://gym.lexiaoya.cn"
+  }
+  return returnUrl
+}
+
+
 /**
  * @desc 函数防抖
  * @param func 目标函数

+ 2 - 4
src/components/MImgCode.vue

@@ -33,10 +33,9 @@ export default {
     phone: String || Number,
   },
   data() {
-    let origin = window.location.origin;
     return {
       showImgCode: this.value,
-      identifyingCode: origin + "/api-teacher/code/getLoginImage?phone=" + this.phone,
+      identifyingCode:  "/api-teacher/code/getLoginImage?phone=" + this.phone,
       code: null,
     };
   },
@@ -47,8 +46,7 @@ export default {
   methods: {
     async updateIdentifyingCode() {
       // 刷新token
-      let origin = window.location.origin;
-      this.identifyingCode = `${origin}/api-teacher/code/getLoginImage?phone=${this.phone}&token=${Math.random()}`;
+      this.identifyingCode = `/api-teacher/code/getLoginImage?phone=${this.phone}&token=${Math.random()}`;
     },
     async checkVerifyLoginImage() {
       try {

+ 2 - 1
src/components/MPayment.vue

@@ -42,7 +42,8 @@
 </template>
 
 <script>
-import { changeTwoDecimal, validStudentUrl } from "@/common/common";
+import { changeTwoDecimal } from "@/common/common";
+import { validStudentUrl } from "@/common/util"
 // import { executePayment } from '@/api/student'
 // const axios = require('@/common/axios').default
 export default {

+ 6 - 5
src/views/app/ClassDetail.vue

@@ -119,11 +119,12 @@ export default {
                 })
                 .then(() => {
                   // this.$router.push('/studentDownLoad')
-                  if (this.checkUrl()) {
-                    window.location.href = "https://gym.lexiaoya.cn/mdaya/#/transfer";
-                  } else {
-                    window.location.href = "https://test.gym.lexiaoya.cn/mdaya/#/transfer";
-                  }
+                  // if (this.checkUrl()) {
+                  //   window.location.href = "https://gym.lexiaoya.cn/mdaya/#/transfer";
+                  // } else {
+                  //   window.location.href = "https://test.gym.lexiaoya.cn/mdaya/#/transfer";
+                  // }
+                  window.location.href = "/mdaya/#/transfer";
                 });
             } else if (result.code == 302) {
               this.onSubmitStatus = true;

+ 2 - 1
src/views/app/PaymentResult.vue

@@ -55,7 +55,8 @@
 <script>
 /* eslint-disable */
 import MHeader from "@/components/header";
-import { browser, validStudentUrl } from "@/common/common";
+import { browser } from "@/common/common";
+import {validStudentUrl} from "@/common/util"
 import { queryByOrderNoAuth, queryOrderInfo } from "@/api/app";
 
 export default {

+ 1 - 15
src/views/creation/audioVisualDraw.js

@@ -139,18 +139,4 @@ export function generateMixedData(size) {
    }
 
    return dataArray
-}
-
-export function vaildMusicScoreUrl() {
-   const url = window.location.hostname
-   let returnUrl = ""
-   if (/dev/.test(url) || /192.168/.test(url)) {
-      returnUrl = "https://test.gym.lexiaoya.cn"
-   } else if (/test/.test(url)) {
-      // test 环境
-      returnUrl = "https://test.gym.lexiaoya.cn"
-   } else {
-      returnUrl = "https://gym.lexiaoya.cn"
-   }
-   return returnUrl
-}
+}

+ 5 - 4
src/views/creation/index-shareRoute.vue

@@ -216,10 +216,11 @@
 
 <script>
 import dayjs from "dayjs"
-import { browser, getSecondRPM, getGradeCh, validStudentUrl } from "@/common/common"
+import { browser, getSecondRPM, getGradeCh } from "@/common/common"
+import { validStudentUrl } from "@/common/util"
 import { postMessage } from "@/helpers/native-message"
 import { api_openUserMusicPage, api_userMusicStar, api_openUserMusicDetail } from "./api"
-import audioVisualDraw, { vaildMusicScoreUrl } from "./audioVisualDraw"
+import audioVisualDraw from "./audioVisualDraw"
 import textEllipsis from "./textEllipsis"
 import Loading from "./loading"
 import "plyr/dist/plyr.css"
@@ -288,7 +289,7 @@ export default {
       goBack() {
          if (browser().isApp) {
             this.setStatusBarTextColor(false)
-            postMessage({ api: "setBarStatus", content: { status: 1, backButtonHidden: 0 } })
+            !browser().android && postMessage({ api: "setBarStatus", content: { status: 1, backButtonHidden: 0 } })
             postMessage({
                api: "back"
             })
@@ -466,7 +467,7 @@ export default {
       },
       // 初始化五线谱
       initStaff() {
-         const src = `${vaildMusicScoreUrl()}/gym-music-score/#/simple-detail?id=${this.state.musicDetail.musicSheetId}&musicRenderType=${
+         const src = `/gym-music-score/#/simple-detail?id=${this.state.musicDetail.musicSheetId}&musicRenderType=${
             this.staffState.musicRenderType
          }&part-index=${this.staffState.partIndex}`
          //const src = `http://192.168.3.122:3000/gym-music-score.html#/simple-detail?id=${state.musicDetail.musicSheetId}&musicRenderType=${staffState.musicRenderType}&part-index=${staffState.partIndex}`;

+ 3 - 3
src/views/creation/index.vue

@@ -214,7 +214,7 @@ import dayjs from "dayjs"
 import { browser, getSecondRPM, getGradeCh} from "@/common/common"
 import { postMessage } from "@/helpers/native-message"
 import { api_userMusicDetail, api_userMusicRemove, api_userMusicStarPage } from "./api"
-import audioVisualDraw, { vaildMusicScoreUrl } from "./audioVisualDraw"
+import audioVisualDraw from "./audioVisualDraw"
 import textEllipsis from "./textEllipsis"
 import Loading from "./loading"
 import "plyr/dist/plyr.css"
@@ -279,7 +279,7 @@ export default {
       goBack() {
          if (browser().isApp) {
             this.setStatusBarTextColor(false)
-            postMessage({ api: "setBarStatus", content: { status: 1, backButtonHidden: 0 } })
+            !browser().android && postMessage({ api: "setBarStatus", content: { status: 1, backButtonHidden: 0 } })
             postMessage({
                api: "goBack"
             })
@@ -404,7 +404,7 @@ export default {
       },
       // 初始化五线谱
       initStaff() {
-         const src = `${vaildMusicScoreUrl()}/gym-music-score/#/simple-detail?id=${this.state.musicDetail.musicSheetId}&musicRenderType=${
+         const src = `/gym-music-score/#/simple-detail?id=${this.state.musicDetail.musicSheetId}&musicRenderType=${
             this.staffState.musicRenderType
          }&part-index=${this.staffState.partIndex}`
          //const src = `http://192.168.3.122:3000/gym-music-score.html#/simple-detail?id=${state.musicDetail.musicSheetId}&musicRenderType=${staffState.musicRenderType}&part-index=${staffState.partIndex}`;

Alguns ficheiros não foram mostrados porque muitos ficheiros mudaram neste diff