diff --git a/.env.development b/.env.development index 78976cddd..7ffad86e9 100644 --- a/.env.development +++ b/.env.development @@ -34,4 +34,7 @@ VITE_OUT_DIR=dist VITE_INTERFACE_URL='http://localhost:12080/magic/web/index.html' # 积木报表请求路径 -VITE_JMREPORT_BASE_URL='http://localhost:12080' \ No newline at end of file +VITE_JMREPORT_BASE_URL='http://localhost:12080' + +# 租户配置 +VITE_TENANT='["长春","成都"]' \ No newline at end of file diff --git a/.env.test b/.env.test index a42a17cd3..27d463213 100644 --- a/.env.test +++ b/.env.test @@ -35,3 +35,6 @@ VITE_INTERFACE_URL='http://dev.ccwin-in.com:25310/magic/web/index.html' # 积木报表请求路径 VITE_JMREPORT_BASE_URL='http://dev.ccwin-in.com:25310' + +# 租户配置 +VITE_TENANT='["长春","成都"]' \ No newline at end of file diff --git a/.env.test-scp b/.env.test-scp index a68d25459..e64386900 100644 --- a/.env.test-scp +++ b/.env.test-scp @@ -35,3 +35,7 @@ VITE_INTERFACE_URL='http://dev.ccwin-in.com:25311/magic/web/index.html' # 积木报表请求路径 VITE_JMREPORT_BASE_URL='http://dev.ccwin-in.com:25311' + + +# 租户配置 +VITE_TENANT='["长春","成都"]' diff --git a/.env.wyf b/.env.wyf index 4c5de71c6..ae1a58502 100644 --- a/.env.wyf +++ b/.env.wyf @@ -4,9 +4,9 @@ NODE_ENV=test VITE_DEV=false # 请求路径 -VITE_BASE_URL='http://192.168.0.113:12080' +VITE_BASE_URL='http://192.168.0.108:12080' # 上传路径 -VITE_UPLOAD_URL='http://192.168.0.113:12080/admin-api/infra/file/upload' +VITE_UPLOAD_URL='http://192.168.0.108:12080/admin-api/infra/file/upload' # # 请求路径 # VITE_BASE_URL='http://dev.ccwin-in.com:25300/api' @@ -46,3 +46,6 @@ VITE_JMREPORT_BASE_URL='http://192.168.0.108:12080' # # 积木报表请求路径 # VITE_JMREPORT_BASE_URL='http://dev.ccwin-in.com:25310' + +# 租户配置 +VITE_TENANT='["长春","成都"]' \ No newline at end of file diff --git a/src/views/login/components/LoginForm.vue b/src/views/login/components/LoginForm.vue index 6f79ce15e..67607c1dc 100644 --- a/src/views/login/components/LoginForm.vue +++ b/src/views/login/components/LoginForm.vue @@ -9,8 +9,16 @@ - + + + + @@ -110,6 +118,7 @@ // 验证码开关 const captchaEnabled = ref(true); const codeUrl = ref(""); + const tenantArray = JSON.parse(import.meta.env.VITE_TENANT); const LoginRules = { tenantName: [required], @@ -121,7 +130,7 @@ captchaEnable: import.meta.env.VITE_APP_CAPTCHA_ENABLE, tenantEnable: import.meta.env.VITE_APP_TENANT_ENABLE, loginForm: { - tenantName: '闻荫源码', + tenantName: tenantArray[0], username: 'admin', password: '123456', captchaVerification: '', diff --git a/src/views/login/components/MobileForm.vue b/src/views/login/components/MobileForm.vue index fa42de03d..1d7038231 100644 --- a/src/views/login/components/MobileForm.vue +++ b/src/views/login/components/MobileForm.vue @@ -18,13 +18,21 @@ - + /> --> + + + @@ -117,6 +125,7 @@ const iconCircleCheck = useIcon({ icon: 'ep:circle-check' }) const { validForm } = useFormValid(formSmsLogin) const { handleBackLogin, getLoginState } = useLoginState() const getShow = computed(() => unref(getLoginState) === LoginStateEnum.MOBILE) +const tenantArray = JSON.parse(import.meta.env.VITE_TENANT); const rules = { tenantName: [required], @@ -132,7 +141,7 @@ const loginData = reactive({ }, loginForm: { uuid: '', - tenantName: '闻荫源码', + tenantName: tenantArray[0], mobileNumber: '', code: '' }