Browse Source

fix 首页logo code

Michael Wang 4 năm trước cách đây
mục cha
commit
a7ff28b3a7

+ 1 - 4
src/constant/constants.js

@@ -6,9 +6,6 @@ if (!localStorage.getItem("deviceId")) {
 }
 }
 export const DEVICE_ID = localStorage.getItem("deviceId");
 export const DEVICE_ID = localStorage.getItem("deviceId");
 
 
-export const ORG_CODE =
-  process.env.VUE_APP_ORG_CODE || window.location.hostname.split(".")[0];
-
 export const INVIGILATOR_IMPORT_TEMPLATE_DOWNLOAD_URL =
 export const INVIGILATOR_IMPORT_TEMPLATE_DOWNLOAD_URL =
   "/file/考场监考老师导入.xlsx";
   "/file/考场监考老师导入.xlsx";
 export const EXAM_STUDENT_IMPORT_TEMPLATE_DOWNLOAD_URL =
 export const EXAM_STUDENT_IMPORT_TEMPLATE_DOWNLOAD_URL =
@@ -19,4 +16,4 @@ if (process.env.VUE_APP_SELF_DEFINE_DOMAIN === "true") {
   domain = window.localStorage.getItem("domain_in_url");
   domain = window.localStorage.getItem("domain_in_url");
 }
 }
 if (!domain) domain = window.location.hostname.split(".")[0];
 if (!domain) domain = window.location.hostname.split(".")[0];
-export const DOMAIN_IN_URL = domain;
+export const ORG_CODE = domain;

+ 2 - 2
src/features/Login/Login.vue

@@ -91,7 +91,7 @@
 
 
 <script>
 <script>
 import { LOGIN_BY_USERNAME } from "../../store/action-types";
 import { LOGIN_BY_USERNAME } from "../../store/action-types";
-import { ORG_CODE, DOMAIN_IN_URL } from "../../constant/constants";
+import { ORG_CODE } from "../../constant/constants";
 import { getLogo } from "@/api/login";
 import { getLogo } from "@/api/login";
 
 
 export default {
 export default {
@@ -119,7 +119,7 @@ export default {
             await this.$store.dispatch(LOGIN_BY_USERNAME, {
             await this.$store.dispatch(LOGIN_BY_USERNAME, {
               loginName: this.user.username,
               loginName: this.user.username,
               password: this.user.password,
               password: this.user.password,
-              code: DOMAIN_IN_URL,
+              code: ORG_CODE,
             });
             });
             // console.log(res);
             // console.log(res);
             // localStorage.setItem("themis-user", res.data);
             // localStorage.setItem("themis-user", res.data);