Explorar el Código

日本服定制化修改

bill hace 11 meses
padre
commit
cb28a9469d
Se han modificado 8 ficheros con 26 adiciones y 10 borrados
  1. 3 0
      .env
  2. 3 0
      .env.ja
  3. 10 3
      src/env/index.ts
  4. 2 2
      src/lang/en/material.ts
  5. 2 2
      src/lang/zh/material.ts
  6. 1 1
      src/lang/zh/sys.ts
  7. 3 0
      src/vite-env.d.ts
  8. 2 2
      vite.config.ts

+ 3 - 0
.env

@@ -0,0 +1,3 @@
+VITE_REGISTER=/login/register
+VITE_FORGET=/login/forget
+VITE_USER_INFO=/information

+ 3 - 0
.env.ja

@@ -0,0 +1,3 @@
+VITE_REGISTER=/login
+VITE_FORGET=/login
+VITE_USER_INFO=/login

+ 10 - 3
src/env/index.ts

@@ -12,9 +12,16 @@ export const baseURL = import.meta.env.DEV ? '/api' : '/'
 export const gotoLang = lang === langNameEum.zh ? 'zh' : 'en'
 
 const goto = import.meta.env.DEV ? 'https://test.4dkankan.com/' : '/'
-export const registerLink = `${goto}?lang=${gotoLang}#/login/register`
-export const forgetLink = `${goto}?lang=${gotoLang}#/login/forget`
-export const userInfoLink = `${goto}?lang=${gotoLang}#/information`
+export const registerLink = `${goto}?lang=${gotoLang}#${
+  import.meta.env.VITE_REGISTER
+}`
+console.log(import.meta)
+export const forgetLink = `${goto}?lang=${gotoLang}#${
+  import.meta.env.VITE_FORGET
+}`
+export const userInfoLink = `${goto}?lang=${gotoLang}#${
+  import.meta.env.VITE_USER_INFO
+}`
 
 export let projectManage = `${goto}smarts/smart-viewer.html?lang=${lang}`
 

+ 2 - 2
src/lang/en/material.ts

@@ -3,7 +3,7 @@ export default {
     "userNameLabel": "Account",
     "remarkLabel": "Notes",
     "roleLabel": "Role",
-    "bindAccountLabel": "Phone",
+    "bindAccountLabel": "Account",
     "createTimeLabel": "Added Time",
     "name": "Project Members",
     "ruleUserName": "Please enter a user account",
@@ -12,7 +12,7 @@ export default {
     "ruleRemark": "Please enter a note",
     "ruleRemark1": "Maximum {max} words for a note",
     "ruleRole": "Please select a project role",
-    "rulebindAccount": "Please enter the user's mobile phone number",
+    "rulebindAccount": "Please enter ",
     "addMertial": "New Note",
     "filterName": "Please enter ",
     "add": "Add a new member",

+ 2 - 2
src/lang/zh/material.ts

@@ -3,7 +3,7 @@ export default {
     "userNameLabel": "账号",
     "remarkLabel": "备注",
     "roleLabel": "项目角色",
-    "bindAccountLabel": "绑定手机号",
+    "bindAccountLabel": "绑定号",
     "createTimeLabel": "添加时间",
     "name": "项目成员",
     "ruleUserName": "请输入用户账号",
@@ -12,7 +12,7 @@ export default {
     "ruleRemark": "请输入备注",
     "ruleRemark1": "备注最多{max}字",
     "ruleRole": "请选择项目角色",
-    "rulebindAccount": "请输入用户手机号",
+    "rulebindAccount": "请输入用户号",
     "addMertial": "新建备注",
     "filterName": "请输入笔记名称",
     "add": "新增成员",

+ 1 - 1
src/lang/zh/sys.ts

@@ -68,7 +68,7 @@ export default {
     "phoneRule": "请输入账号",
     "passwordRule": "请输入账号",
     "phoneRul1": "请输入正确账号",
-    "passwordRule1": "手机号或密码有误",
+    "passwordRule1": "号或密码有误",
     "rememberLabel": "记住密码",
     "login": "登录",
     "forget": "忘记密码",

+ 3 - 0
src/vite-env.d.ts

@@ -14,6 +14,9 @@ interface ComponentConstructor<P = any> {
 
 interface ImportMetaEnv {
   readonly VITE_SERVER: string
+  readonly VITE_REGISTER: string
+  readonly VITE_FORGET: string
+  readonly VITE_USER_INFO: string
 }
 
 interface ImportMeta {

+ 2 - 2
vite.config.ts

@@ -18,7 +18,7 @@ export default async ({ mode }) => {
       rewrite: path => path.replace(/^\/dev/, '/dev')
     },
     '/api': {
-      target: 'https://test.4dkankan.com',
+      target: 'https://test-jp.4dkankan.com/',
       changeOrigin: true,
       rewrite: path => path.replace(/^\/api/, '')
     },
@@ -77,7 +77,7 @@ export default async ({ mode }) => {
     },
     server: {
       host: '0.0.0.0',
-      port: 5173,
+      port: 5176,
       open: true,
       proxy: proxy
     }