Commit e477179cd5a100440855bff8a951cefa70567ed1
1 parent
4bf8576d
refactor: store action name
Showing
5 changed files
with
15 additions
and
15 deletions
yudao-server/src/main/resources/application-local.yaml
| @@ -45,33 +45,33 @@ spring: | @@ -45,33 +45,33 @@ spring: | ||
| 45 | datasource: | 45 | datasource: |
| 46 | master: | 46 | master: |
| 47 | name: ruoyi-vue-pro | 47 | name: ruoyi-vue-pro |
| 48 | - url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.master.name}?allowMultiQueries=true&useUnicode=true&useSSL=false&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&autoReconnect=true&nullCatalogMeansCurrent=true # MySQL Connector/J 8.X 连接的示例 | 48 | + url: jdbc:mysql://39.107.87.6:3306/${spring.datasource.dynamic.datasource.master.name}?allowMultiQueries=true&useUnicode=true&useSSL=false&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&autoReconnect=true&nullCatalogMeansCurrent=true # MySQL Connector/J 8.X 连接的示例 |
| 49 | # url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.master.name}?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=UTF-8&serverTimezone=CTT # MySQL Connector/J 5.X 连接的示例 | 49 | # url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.master.name}?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=UTF-8&serverTimezone=CTT # MySQL Connector/J 5.X 连接的示例 |
| 50 | # url: jdbc:postgresql://127.0.0.1:5432/${spring.datasource.dynamic.datasource.slave.name} # PostgreSQL 连接的示例 | 50 | # url: jdbc:postgresql://127.0.0.1:5432/${spring.datasource.dynamic.datasource.slave.name} # PostgreSQL 连接的示例 |
| 51 | # url: jdbc:oracle:thin:@127.0.0.1:1521:xe # Oracle 连接的示例 | 51 | # url: jdbc:oracle:thin:@127.0.0.1:1521:xe # Oracle 连接的示例 |
| 52 | # url: jdbc:sqlserver://127.0.0.1:1433;DatabaseName=${spring.datasource.dynamic.datasource.master.name} # SQLServer 连接的示例 | 52 | # url: jdbc:sqlserver://127.0.0.1:1433;DatabaseName=${spring.datasource.dynamic.datasource.master.name} # SQLServer 连接的示例 |
| 53 | username: root | 53 | username: root |
| 54 | - password: 123456 | ||
| 55 | - # username: sa | ||
| 56 | - # password: JSm:g(*%lU4ZAkz06cd52KqT3)i1?H7W | 54 | + password: Root@xingyu123 |
| 55 | + # username: sa | ||
| 56 | + # password: JSm:g(*%lU4ZAkz06cd52KqT3)i1?H7W | ||
| 57 | slave: # 模拟从库,可根据自己需要修改 | 57 | slave: # 模拟从库,可根据自己需要修改 |
| 58 | name: ruoyi-vue-pro | 58 | name: ruoyi-vue-pro |
| 59 | - url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.slave.name}?allowMultiQueries=true&useUnicode=true&useSSL=false&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&autoReconnect=true&nullCatalogMeansCurrent=true # MySQL Connector/J 8.X 连接的示例 | 59 | + url: jdbc:mysql://39.107.87.6:3306/${spring.datasource.dynamic.datasource.slave.name}?allowMultiQueries=true&useUnicode=true&useSSL=false&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&autoReconnect=true&nullCatalogMeansCurrent=true # MySQL Connector/J 8.X 连接的示例 |
| 60 | # url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.slave.name}?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=UTF-8&serverTimezone=CTT # MySQL Connector/J 5.X 连接的示例 | 60 | # url: jdbc:mysql://127.0.0.1:3306/${spring.datasource.dynamic.datasource.slave.name}?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=UTF-8&serverTimezone=CTT # MySQL Connector/J 5.X 连接的示例 |
| 61 | # url: jdbc:postgresql://127.0.0.1:5432/${spring.datasource.dynamic.datasource.slave.name} # PostgreSQL 连接的示例 | 61 | # url: jdbc:postgresql://127.0.0.1:5432/${spring.datasource.dynamic.datasource.slave.name} # PostgreSQL 连接的示例 |
| 62 | # url: jdbc:oracle:thin:@127.0.0.1:1521:xe # Oracle 连接的示例 | 62 | # url: jdbc:oracle:thin:@127.0.0.1:1521:xe # Oracle 连接的示例 |
| 63 | # url: jdbc:sqlserver://127.0.0.1:1433;DatabaseName=${spring.datasource.dynamic.datasource.slave.name} # SQLServer 连接的示例 | 63 | # url: jdbc:sqlserver://127.0.0.1:1433;DatabaseName=${spring.datasource.dynamic.datasource.slave.name} # SQLServer 连接的示例 |
| 64 | username: root | 64 | username: root |
| 65 | - password: 123456 | ||
| 66 | - # username: sa | ||
| 67 | - # password: JSm:g(*%lU4ZAkz06cd52KqT3)i1?H7W | 65 | + password: Root@xingyu123 |
| 66 | + # username: sa | ||
| 67 | + # password: JSm:g(*%lU4ZAkz06cd52KqT3)i1?H7W | ||
| 68 | 68 | ||
| 69 | # Redis 配置。Redisson 默认的配置足够使用,一般不需要进行调优 | 69 | # Redis 配置。Redisson 默认的配置足够使用,一般不需要进行调优 |
| 70 | redis: | 70 | redis: |
| 71 | - host: 127.0.0.1 # 地址 | 71 | + host: 39.107.87.6 # 地址 |
| 72 | port: 6379 # 端口 | 72 | port: 6379 # 端口 |
| 73 | - database: 0 # 数据库索引 | ||
| 74 | -# password: 123456 # 密码,建议生产环境开启 | 73 | + database: 4 # 数据库索引 |
| 74 | + password: xingyu # 密码,建议生产环境开启 | ||
| 75 | 75 | ||
| 76 | jasypt: | 76 | jasypt: |
| 77 | encryptor: | 77 | encryptor: |
yudao-ui-admin-vue3/src/store/modules/user.ts
| @@ -39,7 +39,7 @@ export const useUserStore = defineStore({ | @@ -39,7 +39,7 @@ export const useUserStore = defineStore({ | ||
| 39 | } | 39 | } |
| 40 | }, | 40 | }, |
| 41 | actions: { | 41 | actions: { |
| 42 | - async getUserInfoAction(userInfo: UserInfoVO) { | 42 | + async setUserInfoAction(userInfo: UserInfoVO) { |
| 43 | if (!getAccessToken()) { | 43 | if (!getAccessToken()) { |
| 44 | this.resetState() | 44 | this.resetState() |
| 45 | return null | 45 | return null |
yudao-ui-admin-vue3/src/views/Login/components/LoginForm.vue
| @@ -112,7 +112,7 @@ const handleLogin = async (params) => { | @@ -112,7 +112,7 @@ const handleLogin = async (params) => { | ||
| 112 | const res = await LoginApi.loginApi(loginData.loginForm) | 112 | const res = await LoginApi.loginApi(loginData.loginForm) |
| 113 | setToken(res) | 113 | setToken(res) |
| 114 | const userInfo = await LoginApi.getInfoApi() | 114 | const userInfo = await LoginApi.getInfoApi() |
| 115 | - await userStore.getUserInfoAction(userInfo) | 115 | + await userStore.setUserInfoAction(userInfo) |
| 116 | await getRoutes() | 116 | await getRoutes() |
| 117 | loginLoading.value = false | 117 | loginLoading.value = false |
| 118 | } | 118 | } |
yudao-ui-admin-vue3/src/views/Login/components/MobileForm.vue
| @@ -103,7 +103,7 @@ const signIn = async () => { | @@ -103,7 +103,7 @@ const signIn = async () => { | ||
| 103 | .then(async (res) => { | 103 | .then(async (res) => { |
| 104 | setToken(res?.token) | 104 | setToken(res?.token) |
| 105 | const userInfo = await getInfoApi() | 105 | const userInfo = await getInfoApi() |
| 106 | - await userStore.getUserInfoAction(userInfo) | 106 | + await userStore.setUserInfoAction(userInfo) |
| 107 | getRoutes() | 107 | getRoutes() |
| 108 | }) | 108 | }) |
| 109 | .catch(() => {}) | 109 | .catch(() => {}) |
yudao-ui-admin/vue.config.js
| @@ -10,7 +10,7 @@ const CompressionPlugin = require('compression-webpack-plugin') | @@ -10,7 +10,7 @@ const CompressionPlugin = require('compression-webpack-plugin') | ||
| 10 | 10 | ||
| 11 | const name = process.env.VUE_APP_TITLE || '芋道管理系统' // 网页标题 | 11 | const name = process.env.VUE_APP_TITLE || '芋道管理系统' // 网页标题 |
| 12 | 12 | ||
| 13 | -const port = process.env.port || process.env.npm_config_port || 80 // 端口 | 13 | +const port = process.env.port || process.env.npm_config_port || 8081 // 端口 |
| 14 | 14 | ||
| 15 | // vue.config.js 配置说明 | 15 | // vue.config.js 配置说明 |
| 16 | //官方vue.config.js 参考文档 https://cli.vuejs.org/zh/config/#css-loaderoptions | 16 | //官方vue.config.js 参考文档 https://cli.vuejs.org/zh/config/#css-loaderoptions |