From c790f74905e20c2e7ec4be7e460bc0960e2b8579 Mon Sep 17 00:00:00 2001 From: zhenhui <1276357500@qq.com> Date: Tue, 17 Mar 2026 11:42:16 +0800 Subject: [PATCH] =?UTF-8?q?=E6=89=80=E6=9C=89=E9=A1=B5=E9=9D=A2-=E5=88=9B?= =?UTF-8?q?=E5=BB=BA=E4=B8=AD=E8=8B=B1=E5=8F=8C=E8=AF=AD=E5=AF=B9=E7=85=A7?= =?UTF-8?q?-=E4=BC=98=E5=8C=96=E7=BF=BB=E8=AF=91=E6=96=87=E6=A1=A3?= =?UTF-8?q?=E7=BB=93=E6=9E=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../core/layouts/art-header-bar/index.vue | 2 + .../core/tables/art-table/index.vue | 4 +- saiadmin-artd/src/locales/langs/README.md | 42 ++++++++++ saiadmin-artd/src/locales/langs/en.json | 50 +++++++++++ .../src/locales/langs/en/dice/config.json | 18 ++++ .../langs/en/dice/lottery_pool_config.json | 24 ++++++ .../locales/langs/en/dice/play_record.json | 40 +++++++++ .../langs/en/dice/play_record_test.json | 37 ++++++++ .../src/locales/langs/en/dice/player.json | 34 ++++++++ .../langs/en/dice/player_ticket_record.json | 21 +++++ .../langs/en/dice/player_wallet_record.json | 29 +++++++ .../src/locales/langs/en/dice/reward.json | 21 +++++ .../locales/langs/en/dice/reward_config.json | 23 +++++ .../langs/en/dice/reward_config_record.json | 18 ++++ .../langs/en/safeguard/attachment.json | 18 ++++ .../locales/langs/en/safeguard/database.json | 19 +++++ .../src/locales/langs/en/safeguard/dict.json | 12 +++ .../locales/langs/en/safeguard/login-log.json | 22 +++++ .../locales/langs/en/safeguard/oper-log.json | 20 +++++ .../src/locales/langs/en/system/config.json | 15 ++++ .../src/locales/langs/en/system/dept.json | 18 ++++ .../src/locales/langs/en/system/menu.json | 21 +++++ .../src/locales/langs/en/system/post.json | 17 ++++ .../src/locales/langs/en/system/role.json | 18 ++++ .../src/locales/langs/en/system/user.json | 21 +++++ .../src/locales/langs/en/tool/code.json | 20 +++++ .../src/locales/langs/en/tool/crontab.json | 21 +++++ saiadmin-artd/src/locales/langs/zh.json | 84 ++++++++++++++++++- .../src/locales/langs/zh/dice/config.json | 18 ++++ .../langs/zh/dice/lottery_pool_config.json | 24 ++++++ .../locales/langs/zh/dice/play_record.json | 40 +++++++++ .../langs/zh/dice/play_record_test.json | 37 ++++++++ .../src/locales/langs/zh/dice/player.json | 34 ++++++++ .../langs/zh/dice/player_ticket_record.json | 21 +++++ .../langs/zh/dice/player_wallet_record.json | 29 +++++++ .../src/locales/langs/zh/dice/reward.json | 21 +++++ .../locales/langs/zh/dice/reward_config.json | 23 +++++ .../langs/zh/dice/reward_config_record.json | 18 ++++ .../langs/zh/safeguard/attachment.json | 18 ++++ .../locales/langs/zh/safeguard/database.json | 19 +++++ .../src/locales/langs/zh/safeguard/dict.json | 12 +++ .../locales/langs/zh/safeguard/email-log.json | 20 +++++ .../locales/langs/zh/safeguard/login-log.json | 22 +++++ .../locales/langs/zh/safeguard/oper-log.json | 20 +++++ .../src/locales/langs/zh/system/config.json | 15 ++++ .../src/locales/langs/zh/system/dept.json | 18 ++++ .../src/locales/langs/zh/system/menu.json | 21 +++++ .../src/locales/langs/zh/system/post.json | 17 ++++ .../src/locales/langs/zh/system/role.json | 18 ++++ .../src/locales/langs/zh/system/user.json | 21 +++++ .../src/locales/langs/zh/tool/code.json | 20 +++++ .../src/locales/langs/zh/tool/crontab.json | 21 +++++ saiadmin-artd/src/locales/pageLocaleLoader.ts | 84 +++++++++++++++++++ saiadmin-artd/src/router/guards/beforeEach.ts | 2 + .../dashboard/console/modules/active-user.vue | 2 +- .../dashboard/console/modules/card-list.vue | 16 ++-- .../console/modules/dynamic-stats.vue | 4 +- .../console/modules/new-player-list.vue | 10 +-- .../dashboard/console/modules/new-user.vue | 22 ++--- .../console/modules/sales-overview.vue | 2 +- .../dashboard/console/modules/todo-list.vue | 4 +- .../console/modules/wallet-record-list.vue | 10 +-- .../views/plugin/dice/config/index/index.vue | 12 +-- .../config/index/modules/table-search.vue | 12 +-- .../dice/lottery_pool_config/index/index.vue | 22 ++--- .../index/modules/table-search.vue | 20 +++-- .../plugin/dice/play_record/index/index.vue | 40 ++++----- .../index/modules/table-search.vue | 36 ++++---- .../dice/play_record_test/index/index.vue | 46 +++++----- .../index/modules/table-search.vue | 24 +++--- .../views/plugin/dice/player/index/index.vue | 32 +++---- .../player/index/modules/table-search.vue | 22 ++--- .../dice/player_ticket_record/index/index.vue | 16 ++-- .../index/modules/table-search.vue | 14 ++-- .../dice/player_wallet_record/index/index.vue | 40 ++++----- .../index/modules/table-search.vue | 20 ++--- .../views/plugin/dice/reward/index/index.vue | 24 +++--- .../reward/index/modules/table-search.vue | 2 +- .../plugin/dice/reward_config/index/index.vue | 4 +- .../index/modules/table-search.vue | 10 +-- .../dice/reward_config_record/index/index.vue | 28 ++++--- .../src/views/safeguard/attachment/index.vue | 12 +-- .../attachment/modules/table-search.vue | 12 +-- .../src/views/safeguard/database/index.vue | 18 ++-- .../database/modules/recycle-list.vue | 4 +- .../database/modules/table-search.vue | 4 +- .../src/views/safeguard/dict/index.vue | 18 ++-- .../src/views/safeguard/email-log/index.vue | 16 ++-- .../email-log/modules/table-search.vue | 14 ++-- .../src/views/safeguard/login-log/index.vue | 18 ++-- .../login-log/modules/table-search.vue | 14 ++-- .../src/views/safeguard/oper-log/index.vue | 14 ++-- .../oper-log/modules/table-search.vue | 14 ++-- .../src/views/system/config/index.vue | 6 +- saiadmin-artd/src/views/system/dept/index.vue | 12 +-- .../system/dept/modules/table-search.vue | 12 +-- saiadmin-artd/src/views/system/menu/index.vue | 16 ++-- .../system/menu/modules/table-search.vue | 12 +-- saiadmin-artd/src/views/system/post/index.vue | 10 +-- .../system/post/modules/table-search.vue | 12 +-- saiadmin-artd/src/views/system/role/index.vue | 12 +-- .../system/role/modules/table-search.vue | 12 +-- saiadmin-artd/src/views/system/user/index.vue | 14 ++-- .../system/user/modules/table-search.vue | 12 +-- .../views/tool/code/components/loadTable.vue | 10 +-- saiadmin-artd/src/views/tool/code/index.vue | 14 ++-- .../views/tool/code/modules/table-search.vue | 8 +- .../src/views/tool/crontab/index.vue | 14 ++-- .../views/tool/crontab/modules/log-list.vue | 8 +- .../tool/crontab/modules/table-search.vue | 12 +-- 110 files changed, 1729 insertions(+), 421 deletions(-) create mode 100644 saiadmin-artd/src/locales/langs/README.md create mode 100644 saiadmin-artd/src/locales/langs/en/dice/config.json create mode 100644 saiadmin-artd/src/locales/langs/en/dice/lottery_pool_config.json create mode 100644 saiadmin-artd/src/locales/langs/en/dice/play_record.json create mode 100644 saiadmin-artd/src/locales/langs/en/dice/play_record_test.json create mode 100644 saiadmin-artd/src/locales/langs/en/dice/player.json create mode 100644 saiadmin-artd/src/locales/langs/en/dice/player_ticket_record.json create mode 100644 saiadmin-artd/src/locales/langs/en/dice/player_wallet_record.json create mode 100644 saiadmin-artd/src/locales/langs/en/dice/reward.json create mode 100644 saiadmin-artd/src/locales/langs/en/dice/reward_config.json create mode 100644 saiadmin-artd/src/locales/langs/en/dice/reward_config_record.json create mode 100644 saiadmin-artd/src/locales/langs/en/safeguard/attachment.json create mode 100644 saiadmin-artd/src/locales/langs/en/safeguard/database.json create mode 100644 saiadmin-artd/src/locales/langs/en/safeguard/dict.json create mode 100644 saiadmin-artd/src/locales/langs/en/safeguard/login-log.json create mode 100644 saiadmin-artd/src/locales/langs/en/safeguard/oper-log.json create mode 100644 saiadmin-artd/src/locales/langs/en/system/config.json create mode 100644 saiadmin-artd/src/locales/langs/en/system/dept.json create mode 100644 saiadmin-artd/src/locales/langs/en/system/menu.json create mode 100644 saiadmin-artd/src/locales/langs/en/system/post.json create mode 100644 saiadmin-artd/src/locales/langs/en/system/role.json create mode 100644 saiadmin-artd/src/locales/langs/en/system/user.json create mode 100644 saiadmin-artd/src/locales/langs/en/tool/code.json create mode 100644 saiadmin-artd/src/locales/langs/en/tool/crontab.json create mode 100644 saiadmin-artd/src/locales/langs/zh/dice/config.json create mode 100644 saiadmin-artd/src/locales/langs/zh/dice/lottery_pool_config.json create mode 100644 saiadmin-artd/src/locales/langs/zh/dice/play_record.json create mode 100644 saiadmin-artd/src/locales/langs/zh/dice/play_record_test.json create mode 100644 saiadmin-artd/src/locales/langs/zh/dice/player.json create mode 100644 saiadmin-artd/src/locales/langs/zh/dice/player_ticket_record.json create mode 100644 saiadmin-artd/src/locales/langs/zh/dice/player_wallet_record.json create mode 100644 saiadmin-artd/src/locales/langs/zh/dice/reward.json create mode 100644 saiadmin-artd/src/locales/langs/zh/dice/reward_config.json create mode 100644 saiadmin-artd/src/locales/langs/zh/dice/reward_config_record.json create mode 100644 saiadmin-artd/src/locales/langs/zh/safeguard/attachment.json create mode 100644 saiadmin-artd/src/locales/langs/zh/safeguard/database.json create mode 100644 saiadmin-artd/src/locales/langs/zh/safeguard/dict.json create mode 100644 saiadmin-artd/src/locales/langs/zh/safeguard/email-log.json create mode 100644 saiadmin-artd/src/locales/langs/zh/safeguard/login-log.json create mode 100644 saiadmin-artd/src/locales/langs/zh/safeguard/oper-log.json create mode 100644 saiadmin-artd/src/locales/langs/zh/system/config.json create mode 100644 saiadmin-artd/src/locales/langs/zh/system/dept.json create mode 100644 saiadmin-artd/src/locales/langs/zh/system/menu.json create mode 100644 saiadmin-artd/src/locales/langs/zh/system/post.json create mode 100644 saiadmin-artd/src/locales/langs/zh/system/role.json create mode 100644 saiadmin-artd/src/locales/langs/zh/system/user.json create mode 100644 saiadmin-artd/src/locales/langs/zh/tool/code.json create mode 100644 saiadmin-artd/src/locales/langs/zh/tool/crontab.json create mode 100644 saiadmin-artd/src/locales/pageLocaleLoader.ts diff --git a/saiadmin-artd/src/components/core/layouts/art-header-bar/index.vue b/saiadmin-artd/src/components/core/layouts/art-header-bar/index.vue index 41d0f7a..4b62334 100644 --- a/saiadmin-artd/src/components/core/layouts/art-header-bar/index.vue +++ b/saiadmin-artd/src/components/core/layouts/art-header-bar/index.vue @@ -178,6 +178,7 @@ import { useMenuStore } from '@/store/modules/menu' import AppConfig from '@/config' import { languageOptions } from '@/locales' + import { invalidatePageLocaleCache } from '@/locales/pageLocaleLoader' import { mittBus } from '@/utils/sys' import { themeAnimation } from '@/utils/ui/animation' import { useCommon } from '@/hooks/core/useCommon' @@ -288,6 +289,7 @@ if (locale.value === lang) return locale.value = lang userStore.setLanguage(lang) + invalidatePageLocaleCache() reload(50) } diff --git a/saiadmin-artd/src/components/core/tables/art-table/index.vue b/saiadmin-artd/src/components/core/tables/art-table/index.vue index 5e99526..ff4e24e 100644 --- a/saiadmin-artd/src/components/core/tables/art-table/index.vue +++ b/saiadmin-artd/src/components/core/tables/art-table/index.vue @@ -308,12 +308,12 @@ // 是否显示分页器 const showPagination = computed(() => props.pagination && !isEmpty.value) - /** 表头 label 为 table. 开头的 i18n key 时自动翻译,切换语言后表头随动 */ + /** 表头 label 为 table. 或 page. 开头的 i18n key 时自动翻译,切换语言后表头随动 */ const displayColumns = computed(() => { const list = props.columns || [] return list.map((col) => { const label = col.label - if (label && typeof label === 'string' && label.startsWith('table.') && i18n.global.te(label)) { + if (label && typeof label === 'string' && (label.startsWith('table.') || label.startsWith('page.')) && i18n.global.te(label)) { return { ...col, label: $t(label) } } return col diff --git a/saiadmin-artd/src/locales/langs/README.md b/saiadmin-artd/src/locales/langs/README.md new file mode 100644 index 0000000..ebd5672 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/README.md @@ -0,0 +1,42 @@ +# 多语言文件说明 + +## 全局翻译(所有页面共用) + +- `zh.json`、`en.json`:放在 `langs/` 根目录,包含菜单、公共表格操作(删除/添加/选择/操作/刷新等)、公共搜索栏(查询/重置/展开/收起、请输入/请选择、全部/启用/禁用等)、以及非页面级的文案(httpMsg、topBar、common、setting、login 等)。 + +## 页面级翻译(按路由加载) + +路径规则:`langs/{语言}/{目录名}/{菜单名}.json` + +示例:路由 `/dice/lottery_pool_config/index` 对应: + +- 中文:`langs/zh/dice/lottery_pool_config.json` +- 英文:`langs/en/dice/lottery_pool_config.json` + +### 单文件结构 + +```json +{ + "name": "名称", + "search": { + "字段或占位 key": "中文文案" + }, + "table": { + "列 key": "表头中文文案" + } +} +``` + +- 顶层字段(如 `name`):该页面用到的通用字段标签,在搜索或表格中通过 `$t('page.name')` 使用。 +- `search`:搜索栏专用,如 `$t('page.search.poolType')`、`$t('page.search.placeholderName')`。 +- `table`:表格列头专用,如 `$t('page.table.poolType')`;列配置里 `label: 'page.table.xxx'` 会由表格组件自动翻译。 + +### 使用方式 + +- 搜索栏:`$t('page.name')`、`$t('page.search.xxx')`。 +- 表格列:`label: 'page.table.xxx'`(art-table 会自动对 `page.` 开头的 label 做 `$t`)。 +- 公共操作(删除、新增、操作等):继续使用 `$t('table.actions.xxx')`,来自全局 `zh.json` / `en.json`。 + +### 加载逻辑 + +- 进入某路由时,`pageLocaleLoader` 根据 path 解析出 `目录名/菜单名`,动态加载对应语言的 json 并合并到 i18n 的 `page` 命名空间;切换语言会清空缓存,下次进入或刷新后加载新语言文件。 diff --git a/saiadmin-artd/src/locales/langs/en.json b/saiadmin-artd/src/locales/langs/en.json index e7ea88c..53beec1 100644 --- a/saiadmin-artd/src/locales/langs/en.json +++ b/saiadmin-artd/src/locales/langs/en.json @@ -230,6 +230,56 @@ "500": "Sorry, there was an error on the server", "gohome": "Go Home" }, + "console": { + "card": { + "playerRegister": "Player Register", + "playerCharge": "Player Charge", + "playerWithdraw": "Player Withdraw", + "playerPlayCount": "Player Play Count", + "vsLastWeek": "vs Last Week" + }, + "newPlayer": { + "title": "New Players", + "subtitle": "Latest 50 new player records", + "player": "Player", + "balance": "Balance", + "ticket": "Tickets" + }, + "walletRecord": { + "title": "Player Charge Records", + "subtitle": "Latest 50 charge records", + "player": "Player", + "chargeAmount": "Amount", + "chargeTime": "Charge Time" + }, + "salesOverview": { + "title": "Recent Player Charge Stats" + }, + "activeUser": { + "title": "Monthly Player Charge Summary" + }, + "todo": { + "title": "To Do", + "pending": "Pending" + }, + "newUser": { + "title": "New Users", + "growth": "Growth this month", + "thisMonth": "This Month", + "lastMonth": "Last Month", + "thisYear": "This Year", + "avatar": "Avatar", + "region": "Region", + "gender": "Gender", + "progress": "Progress", + "male": "Male", + "female": "Female" + }, + "dynamic": { + "title": "Activity", + "newCount": "New" + } + }, "menus": { "login": { "title": "Login" diff --git a/saiadmin-artd/src/locales/langs/en/dice/config.json b/saiadmin-artd/src/locales/langs/en/dice/config.json new file mode 100644 index 0000000..83d824b --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/dice/config.json @@ -0,0 +1,18 @@ +{ + "search": { + "group": "Group", + "title": "Title", + "configName": "Config Name", + "placeholderGroup": "Please enter group", + "placeholderTitle": "Please enter title", + "placeholderConfigName": "Please enter config name" + }, + "table": { + "group": "Group", + "title": "Title", + "titleEn": "Title (EN)", + "configName": "Config Name", + "value": "Value", + "valueEn": "Value (EN)" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/dice/lottery_pool_config.json b/saiadmin-artd/src/locales/langs/en/dice/lottery_pool_config.json new file mode 100644 index 0000000..a788e5a --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/dice/lottery_pool_config.json @@ -0,0 +1,24 @@ +{ + "name": "Name", + "toolbar": { + "viewCurrentPool": "View Current Pool" + }, + "search": { + "poolType": "Pool Type", + "placeholderName": "Please enter name", + "placeholderPoolType": "Please select pool type", + "poolTypeNormal": "Normal", + "poolTypeKill": "Force Kill", + "poolTypeT1": "T1 High Rate" + }, + "table": { + "name": "Name", + "poolType": "Pool Type", + "safetyLine": "Safety Line", + "t1PoolWeight": "T1 Pool Weight", + "t2PoolWeight": "T2 Pool Weight", + "t3PoolWeight": "T3 Pool Weight", + "t4PoolWeight": "T4 Pool Weight", + "t5PoolWeight": "T5 Pool Weight" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/dice/play_record.json b/saiadmin-artd/src/locales/langs/en/dice/play_record.json new file mode 100644 index 0000000..2ae1d0a --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/dice/play_record.json @@ -0,0 +1,40 @@ +{ + "search": { + "player": "Player", + "lotteryPoolConfig": "Lottery Pool Config", + "drawType": "Draw Type", + "isBigWin": "Is Big Win", + "direction": "Direction", + "winCoin": "Win Coin", + "rollNumber": "Roll Number", + "rewardConfig": "Reward Config", + "rewardTier": "Reward Tier", + "usernameFuzzy": "Username (fuzzy)", + "nameFuzzy": "Name (fuzzy)", + "uiTextFuzzy": "UI Text (fuzzy)", + "paid": "Paid", + "free": "Free", + "noBigWin": "No", + "bigWin": "Big Win", + "clockwise": "Clockwise", + "anticlockwise": "Anticlockwise" + }, + "table": { + "id": "ID", + "player": "Player", + "lotteryPoolConfig": "Lottery Pool Config", + "drawType": "Draw Type", + "isBigWin": "Is Big Win", + "winCoin": "Win Coin", + "superWinCoin": "Super Win Coin", + "rewardWinCoin": "Reward Win Coin", + "direction": "Direction", + "startIndex": "Start Index", + "targetIndex": "Target Index", + "rollArray": "Roll Array", + "rollNumber": "Roll Number", + "rewardConfig": "Reward Config", + "createTime": "Create Time", + "updateTime": "Update Time" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/dice/play_record_test.json b/saiadmin-artd/src/locales/langs/en/dice/play_record_test.json new file mode 100644 index 0000000..0ee72b4 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/dice/play_record_test.json @@ -0,0 +1,37 @@ +{ + "toolbar": { + "clearAllData": "Clear All Data", + "platformTotalProfit": "Platform Total Profit" + }, + "search": { + "drawType": "Draw Type", + "direction": "Direction", + "isBigWin": "Is Big Win", + "winCoin": "Win Coin", + "rewardTier": "Reward Tier", + "rollNumber": "Roll Number", + "paid": "Paid", + "free": "Free", + "clockwise": "Clockwise", + "anticlockwise": "Anticlockwise", + "noBigWin": "No", + "bigWin": "Big Win" + }, + "table": { + "id": "ID", + "player": "Player", + "lotteryPoolConfig": "Lottery Pool Config", + "drawType": "Draw Type", + "isBigWin": "Is Big Win", + "winCoin": "Win Coin", + "superWinCoin": "Super Win Coin", + "rewardWinCoin": "Reward Win Coin", + "direction": "Direction", + "startIndex": "Start Index", + "targetIndex": "Target Index", + "rollArray": "Roll Array", + "rollNumber": "Roll Number", + "rewardConfig": "Reward Config", + "createTime": "Create Time" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/dice/player.json b/saiadmin-artd/src/locales/langs/en/dice/player.json new file mode 100644 index 0000000..099f1c1 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/dice/player.json @@ -0,0 +1,34 @@ +{ + "name": "Name", + "search": { + "username": "Username", + "nickname": "Nickname", + "phone": "Phone", + "status": "Status", + "coin": "Coin", + "lotteryPoolConfig": "Lottery Pool Config", + "placeholderUsername": "Please enter username", + "placeholderNickname": "Please enter nickname", + "placeholderPhoneFuzzy": "Phone (fuzzy)", + "placeholderAll": "All", + "exactSearch": "Exact" + }, + "table": { + "username": "Username", + "phone": "Phone", + "nickname": "Nickname", + "status": "Status", + "coin": "Coin", + "lotteryPoolConfig": "Lottery Pool Config", + "t1Weight": "T1 Weight", + "t2Weight": "T2 Weight", + "t3Weight": "T3 Weight", + "t4Weight": "T4 Weight", + "t5Weight": "T5 Weight", + "totalDrawCount": "Total Draw Count", + "paidDrawCount": "Paid Draw Count", + "freeDrawCount": "Free Draw Count", + "createTime": "Create Time", + "updateTime": "Update Time" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/dice/player_ticket_record.json b/saiadmin-artd/src/locales/langs/en/dice/player_ticket_record.json new file mode 100644 index 0000000..f5b89e8 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/dice/player_ticket_record.json @@ -0,0 +1,21 @@ +{ + "search": { + "player": "Player", + "useCoins": "Use Coins", + "totalDrawCount": "Total Draw Count", + "paidDrawCount": "Paid Draw Count", + "freeDrawCount": "Free Draw Count", + "createTime": "Create Time", + "byUsername": "By username" + }, + "table": { + "id": "ID", + "playerUsername": "Player Username", + "useCoins": "Use Coins", + "totalDrawCount": "Total Draw Count", + "paidDrawCount": "Paid Draw Count", + "freeDrawCount": "Free Draw Count", + "remark": "Remark", + "createTime": "Create Time" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/dice/player_wallet_record.json b/saiadmin-artd/src/locales/langs/en/dice/player_wallet_record.json new file mode 100644 index 0000000..6285446 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/dice/player_wallet_record.json @@ -0,0 +1,29 @@ +{ + "search": { + "type": "Type", + "user": "User", + "coin": "Coin", + "createTime": "Create Time", + "typeRecharge": "Recharge", + "typeWithdraw": "Withdraw", + "typeBuyTicket": "Buy Draw", + "typeAdminAdd": "Admin Add", + "typeAdminSub": "Admin Deduct", + "byUsername": "By username" + }, + "table": { + "id": "ID", + "user": "User", + "coinChange": "Coin Change", + "type": "Type", + "operator": "Operator", + "walletBefore": "Wallet Before", + "walletAfter": "Wallet After", + "remark": "Remark", + "totalDrawCount": "Total Draw Count", + "paidDrawCount": "Paid Draw Count", + "freeDrawCount": "Free Draw Count", + "createTime": "Create Time", + "typeDraw": "Draw" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/dice/reward.json b/saiadmin-artd/src/locales/langs/en/dice/reward.json new file mode 100644 index 0000000..42368b9 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/dice/reward.json @@ -0,0 +1,21 @@ +{ + "toolbar": { + "weightRatio": "Weight Ratio", + "weightTest": "Test Weight" + }, + "search": { + "tier": "Tier", + "clockwise": "Clockwise", + "anticlockwise": "Anticlockwise" + }, + "table": { + "startIndex": "Start Index", + "endIndex": "End Index", + "tier": "Tier", + "dicePoints": "Dice Points", + "displayText": "Display Text", + "realEv": "Real EV", + "remark": "Remark", + "weight": "Weight" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/dice/reward_config.json b/saiadmin-artd/src/locales/langs/en/dice/reward_config.json new file mode 100644 index 0000000..453f658 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/dice/reward_config.json @@ -0,0 +1,23 @@ +{ + "toolbar": { + "gameRewardConfig": "Game Reward Config", + "createRewardRef": "Create Reward Reference" + }, + "search": { + "dicePoints": "Dice Points", + "displayText": "Display Text", + "realEv": "Real EV", + "tier": "Tier", + "fuzzyQuery": "Fuzzy" + }, + "table": { + "startIndex": "Start Index", + "endIndex": "End Index", + "tier": "Tier", + "dicePoints": "Dice Points", + "displayText": "Display Text", + "realEv": "Real EV", + "remark": "Remark", + "weight": "Weight" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/dice/reward_config_record.json b/saiadmin-artd/src/locales/langs/en/dice/reward_config_record.json new file mode 100644 index 0000000..2af6425 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/dice/reward_config_record.json @@ -0,0 +1,18 @@ +{ + "toolbar": { + "viewDetail": "View Detail" + }, + "table": { + "id": "ID", + "status": "Status", + "paidDraw": "Paid Draw", + "freeDraw": "Free Draw", + "platformProfit": "Platform Profit", + "totalDrawCount": "Total Draw Count", + "createdBy": "Created By", + "createTime": "Create Time", + "statusFail": "Failed", + "statusDone": "Done", + "statusTesting": "Testing" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/safeguard/attachment.json b/saiadmin-artd/src/locales/langs/en/safeguard/attachment.json new file mode 100644 index 0000000..e177cab --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/safeguard/attachment.json @@ -0,0 +1,18 @@ +{ + "search": { + "username": "Username", + "phone": "Phone", + "status": "Status", + "placeholderUsername": "Please enter username", + "placeholderPhone": "Please enter phone", + "searchSelectPlaceholder": "Please select" + }, + "table": { + "preview": "Preview", + "fileName": "File Name", + "storageMode": "Storage", + "fileType": "File Type", + "fileSize": "File Size", + "uploadTime": "Upload Time" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/safeguard/database.json b/saiadmin-artd/src/locales/langs/en/safeguard/database.json new file mode 100644 index 0000000..d1bd8cd --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/safeguard/database.json @@ -0,0 +1,19 @@ +{ + "search": { + "tableName": "Table Name", + "placeholderTableName": "Please enter table name" + }, + "table": { + "tableName": "Table Name", + "tableComment": "Table Comment", + "tableEngine": "Table Engine", + "updateTime": "Update Time", + "totalRows": "Total Rows", + "fragmentSize": "Fragment Size", + "dataSize": "Data Size", + "collation": "Collation", + "createTime": "Create Time", + "deleteTime": "Delete Time", + "dataDetail": "Data Detail" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/safeguard/dict.json b/saiadmin-artd/src/locales/langs/en/safeguard/dict.json new file mode 100644 index 0000000..1cbb6f8 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/safeguard/dict.json @@ -0,0 +1,12 @@ +{ + "table": { + "select": "Select", + "dictName": "Dict Name", + "dictCode": "Dict Code", + "dictLabel": "Dict Label", + "dictValue": "Dict Value", + "color": "Color", + "sort": "Sort", + "status": "Status" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/safeguard/login-log.json b/saiadmin-artd/src/locales/langs/en/safeguard/login-log.json new file mode 100644 index 0000000..18e3a25 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/safeguard/login-log.json @@ -0,0 +1,22 @@ +{ + "search": { + "loginUser": "Login User", + "loginIp": "Login IP", + "loginStatus": "Login Status", + "operTime": "Time", + "placeholderLoginUser": "Please enter login user", + "placeholderLoginIp": "Please enter login IP", + "placeholderLoginStatus": "Please select login status" + }, + "table": { + "no": "No.", + "loginUser": "Login User", + "loginStatus": "Login Status", + "loginIp": "Login IP", + "operLocation": "Location", + "os": "OS", + "browser": "Browser", + "loginMessage": "Login Message", + "loginTime": "Login Time" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/safeguard/oper-log.json b/saiadmin-artd/src/locales/langs/en/safeguard/oper-log.json new file mode 100644 index 0000000..b35d6d9 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/safeguard/oper-log.json @@ -0,0 +1,20 @@ +{ + "search": { + "operator": "Operator", + "router": "Route", + "operIp": "IP", + "operTime": "Time", + "placeholderOperator": "Please enter operator", + "placeholderOperRouter": "Please enter route", + "placeholderOperIp": "Please enter IP" + }, + "table": { + "no": "No.", + "operator": "Operator", + "serviceName": "Service", + "router": "Route", + "operIp": "IP", + "operLocation": "Location", + "operTime": "Time" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/system/config.json b/saiadmin-artd/src/locales/langs/en/system/config.json new file mode 100644 index 0000000..e5d2d3f --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/system/config.json @@ -0,0 +1,15 @@ +{ + "search": { + "group": "Group", + "title": "Title", + "configName": "Config Name", + "placeholderGroup": "Please enter group", + "placeholderTitle": "Please enter title", + "placeholderConfigName": "Please enter config name" + }, + "table": { + "select": "Select", + "configName": "Config Name", + "configKey": "Config Key" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/system/dept.json b/saiadmin-artd/src/locales/langs/en/system/dept.json new file mode 100644 index 0000000..7cac943 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/system/dept.json @@ -0,0 +1,18 @@ +{ + "search": { + "deptName": "Dept Name", + "deptCode": "Dept Code", + "status": "Status", + "placeholderDeptName": "Please enter dept name", + "placeholderDeptCode": "Please enter dept code", + "searchSelectPlaceholder": "Please select" + }, + "table": { + "deptName": "Dept Name", + "deptCode": "Dept Code", + "leader": "Leader", + "sort": "Sort", + "status": "Status", + "createTime": "Create Time" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/system/menu.json b/saiadmin-artd/src/locales/langs/en/system/menu.json new file mode 100644 index 0000000..5ce02de --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/system/menu.json @@ -0,0 +1,21 @@ +{ + "search": { + "menuName": "Menu Name", + "route": "Route", + "status": "Status", + "placeholderMenuName": "Please enter menu name", + "placeholderMenuRoute": "Please enter menu route", + "searchSelectPlaceholder": "Please select" + }, + "table": { + "menuName": "Menu Name", + "menuType": "Menu Type", + "icon": "Icon", + "route": "Route", + "component": "Component", + "auth": "Auth", + "sort": "Sort", + "status": "Status", + "createTime": "Create Time" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/system/post.json b/saiadmin-artd/src/locales/langs/en/system/post.json new file mode 100644 index 0000000..bdb3894 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/system/post.json @@ -0,0 +1,17 @@ +{ + "search": { + "postName": "Post Name", + "postCode": "Post Code", + "status": "Status", + "placeholderPostName": "Please enter post name", + "placeholderPostCode": "Please enter post code", + "searchSelectPlaceholder": "Please select" + }, + "table": { + "postName": "Post Name", + "postCode": "Post Code", + "sort": "Sort", + "status": "Status", + "createTime": "Create Time" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/system/role.json b/saiadmin-artd/src/locales/langs/en/system/role.json new file mode 100644 index 0000000..c501794 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/system/role.json @@ -0,0 +1,18 @@ +{ + "search": { + "roleName": "Role Name", + "roleCode": "Role Code", + "status": "Status", + "placeholderRoleName": "Please enter role name", + "placeholderRoleCode": "Please enter role code", + "searchSelectPlaceholder": "Please select" + }, + "table": { + "roleName": "Role Name", + "roleCode": "Role Code", + "level": "Level", + "roleRemark": "Role Description", + "status": "Status", + "createTime": "Create Time" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/system/user.json b/saiadmin-artd/src/locales/langs/en/system/user.json new file mode 100644 index 0000000..502a936 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/system/user.json @@ -0,0 +1,21 @@ +{ + "search": { + "username": "Username", + "phone": "Phone", + "status": "Status", + "placeholderUsername": "Please enter username", + "placeholderPhone": "Please enter phone", + "searchSelectPlaceholder": "Please select" + }, + "table": { + "username": "Username", + "phone": "Phone", + "dept": "Department", + "dashboard": "Dashboard", + "loginTime": "Last Login", + "agentId": "Agent ID", + "status": "Status", + "createTime": "Create Time", + "updateTime": "Update Time" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/tool/code.json b/saiadmin-artd/src/locales/langs/en/tool/code.json new file mode 100644 index 0000000..9dc4cae --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/tool/code.json @@ -0,0 +1,20 @@ +{ + "search": { + "tableName": "Table Name", + "placeholderTableName": "Please enter table name", + "placeholderDataSource": "Please enter data source" + }, + "table": { + "tableName": "Table Name", + "tableDesc": "Table Desc", + "tableComment": "Table Comment", + "engine": "Engine", + "collation": "Collation", + "template": "Template", + "namespace": "Namespace", + "stub": "Stub", + "tplCategory": "Gen Type", + "updateTime": "Update Time", + "createTime": "Create Time" + } +} diff --git a/saiadmin-artd/src/locales/langs/en/tool/crontab.json b/saiadmin-artd/src/locales/langs/en/tool/crontab.json new file mode 100644 index 0000000..65c911c --- /dev/null +++ b/saiadmin-artd/src/locales/langs/en/tool/crontab.json @@ -0,0 +1,21 @@ +{ + "search": { + "taskName": "Task Name", + "taskType": "Task Type", + "status": "Status", + "placeholderTaskName": "Please enter task name", + "searchSelectPlaceholder": "Please select" + }, + "table": { + "no": "No.", + "taskName": "Task Name", + "taskType": "Task Type", + "rule": "Rule", + "target": "Target", + "status": "Status", + "updateDate": "Update Date", + "executeTime": "Execute Time", + "parameter": "Parameter", + "executeStatus": "Status" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh.json b/saiadmin-artd/src/locales/langs/zh.json index d8fc248..558b8d2 100644 --- a/saiadmin-artd/src/locales/langs/zh.json +++ b/saiadmin-artd/src/locales/langs/zh.json @@ -230,6 +230,56 @@ "500": "抱歉,服务器出错了", "gohome": "返回首页" }, + "console": { + "card": { + "playerRegister": "玩家注册", + "playerCharge": "玩家充值", + "playerWithdraw": "玩家提现", + "playerPlayCount": "玩家游玩次数", + "vsLastWeek": "较上周" + }, + "newPlayer": { + "title": "新增玩家", + "subtitle": "最新50条新增玩家记录", + "player": "玩家", + "balance": "余额", + "ticket": "抽奖券" + }, + "walletRecord": { + "title": "玩家充值记录", + "subtitle": "最新50条充值记录", + "player": "玩家", + "chargeAmount": "充值金额", + "chargeTime": "充值时间" + }, + "salesOverview": { + "title": "近期玩家充值统计" + }, + "activeUser": { + "title": "月度玩家充值汇总" + }, + "todo": { + "title": "代办事项", + "pending": "待处理" + }, + "newUser": { + "title": "新用户", + "growth": "这个月增长", + "thisMonth": "本月", + "lastMonth": "上月", + "thisYear": "今年", + "avatar": "头像", + "region": "地区", + "gender": "性别", + "progress": "进度", + "male": "男", + "female": "女" + }, + "dynamic": { + "title": "动态", + "newCount": "新增" + } + }, "menus": { "login": { "title": "登录" @@ -263,7 +313,39 @@ "user": "用户管理", "role": "角色管理", "userCenter": "个人中心", - "menu": "菜单管理" + "menu": "菜单管理", + "dept": "部门管理", + "post": "岗位管理", + "config": "系统配置" + }, + "safeguard": { + "title": "运维管理", + "dict": "数据字典", + "server": "服务监控", + "operLog": "操作日志", + "loginLog": "登录日志", + "emailLog": "邮件日志", + "database": "数据库", + "cache": "缓存管理", + "attachment": "附件管理" + }, + "tool": { + "title": "开发工具", + "crontab": "定时任务", + "code": "代码生成" + }, + "dice": { + "title": "大富翁-色子游戏", + "lotteryPoolConfig": "彩金池配置", + "player": "玩家管理", + "playerWalletRecord": "玩家钱包记录", + "playRecord": "玩家抽奖记录", + "playerTicketRecord": "玩家票券记录", + "rewardConfig": "奖励配置", + "reward": "色子奖励权重", + "rewardConfigRecord": "权重测试记录", + "playRecordTest": "抽奖记录(测试权重)", + "config": "游戏配置" } }, "table": { diff --git a/saiadmin-artd/src/locales/langs/zh/dice/config.json b/saiadmin-artd/src/locales/langs/zh/dice/config.json new file mode 100644 index 0000000..7ab27e1 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/dice/config.json @@ -0,0 +1,18 @@ +{ + "search": { + "group": "分组", + "title": "标题", + "configName": "配置名称", + "placeholderGroup": "请输入分组", + "placeholderTitle": "请输入标题", + "placeholderConfigName": "请输入配置名称" + }, + "table": { + "group": "分组", + "title": "标题", + "titleEn": "标题(英文)", + "configName": "配置名称", + "value": "值", + "valueEn": "值(英文)" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/dice/lottery_pool_config.json b/saiadmin-artd/src/locales/langs/zh/dice/lottery_pool_config.json new file mode 100644 index 0000000..b2b5e6f --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/dice/lottery_pool_config.json @@ -0,0 +1,24 @@ +{ + "name": "名称", + "toolbar": { + "viewCurrentPool": "查看当前彩金池" + }, + "search": { + "poolType": "奖池类型", + "placeholderName": "请输入名称", + "placeholderPoolType": "请选择奖池类型", + "poolTypeNormal": "正常", + "poolTypeKill": "强制杀猪", + "poolTypeT1": "T1高倍率" + }, + "table": { + "name": "名称", + "poolType": "奖池类型", + "safetyLine": "安全线", + "t1PoolWeight": "T1池权重", + "t2PoolWeight": "T2池权重", + "t3PoolWeight": "T3池权重", + "t4PoolWeight": "T4池权重", + "t5PoolWeight": "T5池权重" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/dice/play_record.json b/saiadmin-artd/src/locales/langs/zh/dice/play_record.json new file mode 100644 index 0000000..21346e6 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/dice/play_record.json @@ -0,0 +1,40 @@ +{ + "search": { + "player": "玩家", + "lotteryPoolConfig": "彩金池配置", + "drawType": "抽奖类型", + "isBigWin": "是否中大奖", + "direction": "方向", + "winCoin": "赢取平台币", + "rollNumber": "摇取点数和", + "rewardConfig": "奖励配置", + "rewardTier": "奖励档位", + "usernameFuzzy": "用户名模糊", + "nameFuzzy": "名称模糊", + "uiTextFuzzy": "前端显示文本模糊", + "paid": "付费", + "free": "赠送", + "noBigWin": "无", + "bigWin": "中大奖", + "clockwise": "顺时针", + "anticlockwise": "逆时针" + }, + "table": { + "id": "ID", + "player": "玩家", + "lotteryPoolConfig": "彩金池配置", + "drawType": "抽奖类型", + "isBigWin": "是否中大奖", + "winCoin": "赢取平台币", + "superWinCoin": "中大奖平台币", + "rewardWinCoin": "摇色子中奖平台币", + "direction": "方向", + "startIndex": "起始索引", + "targetIndex": "终点索引", + "rollArray": "摇取点数", + "rollNumber": "摇取点数和", + "rewardConfig": "奖励配置", + "createTime": "创建时间", + "updateTime": "更新时间" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/dice/play_record_test.json b/saiadmin-artd/src/locales/langs/zh/dice/play_record_test.json new file mode 100644 index 0000000..88b2a13 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/dice/play_record_test.json @@ -0,0 +1,37 @@ +{ + "toolbar": { + "clearAllData": "一键删除所有数据", + "platformTotalProfit": "平台总盈利" + }, + "search": { + "drawType": "抽奖类型", + "direction": "方向", + "isBigWin": "是否中大奖", + "winCoin": "赢取平台币", + "rewardTier": "奖励档位", + "rollNumber": "摇取点数和", + "paid": "付费", + "free": "赠送", + "clockwise": "顺时针", + "anticlockwise": "逆时针", + "noBigWin": "无", + "bigWin": "中大奖" + }, + "table": { + "id": "ID", + "player": "玩家", + "lotteryPoolConfig": "彩金池配置", + "drawType": "抽奖类型", + "isBigWin": "是否中大奖", + "winCoin": "赢取平台币", + "superWinCoin": "中大奖平台币", + "rewardWinCoin": "摇色子中奖平台币", + "direction": "方向", + "startIndex": "起始索引", + "targetIndex": "终点索引", + "rollArray": "摇取点数", + "rollNumber": "摇取点数和", + "rewardConfig": "奖励配置", + "createTime": "创建时间" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/dice/player.json b/saiadmin-artd/src/locales/langs/zh/dice/player.json new file mode 100644 index 0000000..173c396 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/dice/player.json @@ -0,0 +1,34 @@ +{ + "name": "名称", + "search": { + "username": "用户名", + "nickname": "昵称", + "phone": "手机号", + "status": "状态", + "coin": "平台币", + "lotteryPoolConfig": "彩金池配置", + "placeholderUsername": "请输入用户名", + "placeholderNickname": "请输入昵称", + "placeholderPhoneFuzzy": "手机号模糊查询", + "placeholderAll": "全部", + "exactSearch": "精确搜索" + }, + "table": { + "username": "用户名", + "phone": "手机号", + "nickname": "昵称", + "status": "状态", + "coin": "平台币", + "lotteryPoolConfig": "彩金池配置", + "t1Weight": "T1权重", + "t2Weight": "T2权重", + "t3Weight": "T3权重", + "t4Weight": "T4权重", + "t5Weight": "T5权重", + "totalDrawCount": "总抽奖次数", + "paidDrawCount": "购买抽奖次数", + "freeDrawCount": "赠送抽奖次数", + "createTime": "创建时间", + "updateTime": "更新时间" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/dice/player_ticket_record.json b/saiadmin-artd/src/locales/langs/zh/dice/player_ticket_record.json new file mode 100644 index 0000000..b40845c --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/dice/player_ticket_record.json @@ -0,0 +1,21 @@ +{ + "search": { + "player": "玩家", + "useCoins": "消耗硬币", + "totalDrawCount": "总抽奖次数", + "paidDrawCount": "购买抽奖次数", + "freeDrawCount": "赠送抽奖次数", + "createTime": "创建时间", + "byUsername": "按用户名搜索" + }, + "table": { + "id": "ID", + "playerUsername": "玩家用户名", + "useCoins": "消耗硬币", + "totalDrawCount": "总抽奖次数", + "paidDrawCount": "购买抽奖次数", + "freeDrawCount": "赠送抽奖次数", + "remark": "备注", + "createTime": "创建时间" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/dice/player_wallet_record.json b/saiadmin-artd/src/locales/langs/zh/dice/player_wallet_record.json new file mode 100644 index 0000000..1ee164c --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/dice/player_wallet_record.json @@ -0,0 +1,29 @@ +{ + "search": { + "type": "类型", + "user": "用户", + "coin": "平台币", + "createTime": "创建时间", + "typeRecharge": "充值", + "typeWithdraw": "提现", + "typeBuyTicket": "购买抽奖次数", + "typeAdminAdd": "管理员加点", + "typeAdminSub": "管理员扣点", + "byUsername": "按用户名搜索" + }, + "table": { + "id": "ID", + "user": "用户", + "coinChange": "平台币变化", + "type": "类型", + "operator": "操作人", + "walletBefore": "钱包操作前", + "walletAfter": "钱包操作后", + "remark": "备注", + "totalDrawCount": "总抽奖次数", + "paidDrawCount": "购买抽奖次数", + "freeDrawCount": "赠送抽奖次数", + "createTime": "创建时间", + "typeDraw": "抽奖" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/dice/reward.json b/saiadmin-artd/src/locales/langs/zh/dice/reward.json new file mode 100644 index 0000000..63f1762 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/dice/reward.json @@ -0,0 +1,21 @@ +{ + "toolbar": { + "weightRatio": "权重配比", + "weightTest": "一键测试权重" + }, + "search": { + "tier": "档位", + "clockwise": "顺时针", + "anticlockwise": "逆时针" + }, + "table": { + "startIndex": "起始索引", + "endIndex": "结束索引(end_index)", + "tier": "档位", + "dicePoints": "色子点数(摇取5-30)", + "displayText": "显示文本", + "realEv": "实际中奖金额", + "remark": "备注", + "weight": "权重(1-10000)" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/dice/reward_config.json b/saiadmin-artd/src/locales/langs/zh/dice/reward_config.json new file mode 100644 index 0000000..f8d4ef0 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/dice/reward_config.json @@ -0,0 +1,23 @@ +{ + "toolbar": { + "gameRewardConfig": "游戏奖励配置", + "createRewardRef": "创建奖励对照" + }, + "search": { + "dicePoints": "色子点数(摇取5-30)", + "displayText": "显示文本", + "realEv": "实际中奖金额", + "tier": "档位", + "fuzzyQuery": "模糊查询" + }, + "table": { + "startIndex": "起始索引", + "endIndex": "结束索引(end_index)", + "tier": "档位", + "dicePoints": "色子点数(摇取5-30)", + "displayText": "显示文本", + "realEv": "实际中奖金额", + "remark": "备注", + "weight": "权重(1-10000)" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/dice/reward_config_record.json b/saiadmin-artd/src/locales/langs/zh/dice/reward_config_record.json new file mode 100644 index 0000000..60e3cd6 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/dice/reward_config_record.json @@ -0,0 +1,18 @@ +{ + "toolbar": { + "viewDetail": "查看详情" + }, + "table": { + "id": "ID", + "status": "状态", + "paidDraw": "付费抽取", + "freeDraw": "免费抽取", + "platformProfit": "平台赚取金额", + "totalDrawCount": "总抽奖次数", + "createdBy": "创建管理员", + "createTime": "创建时间", + "statusFail": "失败", + "statusDone": "完成", + "statusTesting": "测试中" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/safeguard/attachment.json b/saiadmin-artd/src/locales/langs/zh/safeguard/attachment.json new file mode 100644 index 0000000..07bf85e --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/safeguard/attachment.json @@ -0,0 +1,18 @@ +{ + "search": { + "username": "用户名", + "phone": "手机号", + "status": "状态", + "placeholderUsername": "请输入用户名", + "placeholderPhone": "请输入手机号", + "searchSelectPlaceholder": "请选择" + }, + "table": { + "preview": "预览", + "fileName": "文件名称", + "storageMode": "存储模式", + "fileType": "文件类型", + "fileSize": "文件大小", + "uploadTime": "上传时间" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/safeguard/database.json b/saiadmin-artd/src/locales/langs/zh/safeguard/database.json new file mode 100644 index 0000000..4c5d5bd --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/safeguard/database.json @@ -0,0 +1,19 @@ +{ + "search": { + "tableName": "表名称", + "placeholderTableName": "请输入数据表名称" + }, + "table": { + "tableName": "表名称", + "tableComment": "表注释", + "tableEngine": "表引擎", + "updateTime": "更新时间", + "totalRows": "总行数", + "fragmentSize": "碎片大小", + "dataSize": "数据大小", + "collation": "编码", + "createTime": "创建时间", + "deleteTime": "删除时间", + "dataDetail": "数据详情" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/safeguard/dict.json b/saiadmin-artd/src/locales/langs/zh/safeguard/dict.json new file mode 100644 index 0000000..de2cbf2 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/safeguard/dict.json @@ -0,0 +1,12 @@ +{ + "table": { + "select": "选中", + "dictName": "字典名称", + "dictCode": "字典标识", + "dictLabel": "字典标签", + "dictValue": "字典键值", + "color": "颜色", + "sort": "排序", + "status": "状态" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/safeguard/email-log.json b/saiadmin-artd/src/locales/langs/zh/safeguard/email-log.json new file mode 100644 index 0000000..d74fd23 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/safeguard/email-log.json @@ -0,0 +1,20 @@ +{ + "search": { + "labelFrom": "发件人", + "labelTo": "收件人", + "placeholderSendStatus": "请选择发送状态", + "placeholderFrom": "请输入发件人", + "placeholderTo": "请输入收件人", + "operTime": "发送时间" + }, + "table": { + "no": "编号", + "gateway": "服务Host", + "emailFrom": "发件人", + "emailTo": "收件人", + "emailCode": "验证码", + "sendStatus": "发送状态", + "emailResponse": "发送结果", + "sendTime": "发送时间" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/safeguard/login-log.json b/saiadmin-artd/src/locales/langs/zh/safeguard/login-log.json new file mode 100644 index 0000000..aef4c89 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/safeguard/login-log.json @@ -0,0 +1,22 @@ +{ + "search": { + "loginUser": "登录用户", + "loginIp": "登录IP", + "loginStatus": "登录状态", + "operTime": "操作时间", + "placeholderLoginUser": "请输入登录用户", + "placeholderLoginIp": "请输入登录IP", + "placeholderLoginStatus": "请选择登录状态" + }, + "table": { + "no": "编号", + "loginUser": "登录用户", + "loginStatus": "登录状态", + "loginIp": "登录IP", + "operLocation": "操作地点", + "os": "操作系统", + "browser": "浏览器", + "loginMessage": "登录信息", + "loginTime": "登录时间" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/safeguard/oper-log.json b/saiadmin-artd/src/locales/langs/zh/safeguard/oper-log.json new file mode 100644 index 0000000..1f98baf --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/safeguard/oper-log.json @@ -0,0 +1,20 @@ +{ + "search": { + "operator": "操作用户", + "router": "路由", + "operIp": "操作IP", + "operTime": "操作时间", + "placeholderOperator": "请输入操作用户", + "placeholderOperRouter": "请输入操作路由", + "placeholderOperIp": "请输入操作IP" + }, + "table": { + "no": "编号", + "operator": "操作用户", + "serviceName": "业务名称", + "router": "路由", + "operIp": "操作IP", + "operLocation": "操作地点", + "operTime": "操作时间" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/system/config.json b/saiadmin-artd/src/locales/langs/zh/system/config.json new file mode 100644 index 0000000..88d30ca --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/system/config.json @@ -0,0 +1,15 @@ +{ + "search": { + "group": "分组", + "title": "标题", + "configName": "配置名称", + "placeholderGroup": "请输入分组", + "placeholderTitle": "请输入标题", + "placeholderConfigName": "请输入配置名称" + }, + "table": { + "select": "选中", + "configName": "配置名称", + "configKey": "配置标识" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/system/dept.json b/saiadmin-artd/src/locales/langs/zh/system/dept.json new file mode 100644 index 0000000..653c83a --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/system/dept.json @@ -0,0 +1,18 @@ +{ + "search": { + "deptName": "部门名称", + "deptCode": "部门编码", + "status": "状态", + "placeholderDeptName": "请输入部门名称", + "placeholderDeptCode": "请输入部门编码", + "searchSelectPlaceholder": "请选择" + }, + "table": { + "deptName": "部门名称", + "deptCode": "部门编码", + "leader": "部门领导", + "sort": "排序", + "status": "状态", + "createTime": "创建时间" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/system/menu.json b/saiadmin-artd/src/locales/langs/zh/system/menu.json new file mode 100644 index 0000000..c5fe29f --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/system/menu.json @@ -0,0 +1,21 @@ +{ + "search": { + "menuName": "菜单名称", + "route": "路由", + "status": "状态", + "placeholderMenuName": "请输入菜单名称", + "placeholderMenuRoute": "请输入菜单路由", + "searchSelectPlaceholder": "请选择" + }, + "table": { + "menuName": "菜单名称", + "menuType": "菜单类型", + "icon": "图标", + "route": "路由", + "component": "组件名称", + "auth": "权限标识", + "sort": "排序", + "status": "状态", + "createTime": "创建时间" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/system/post.json b/saiadmin-artd/src/locales/langs/zh/system/post.json new file mode 100644 index 0000000..d6586a3 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/system/post.json @@ -0,0 +1,17 @@ +{ + "search": { + "postName": "岗位名称", + "postCode": "岗位编码", + "status": "状态", + "placeholderPostName": "请输入岗位名称", + "placeholderPostCode": "请输入岗位编码", + "searchSelectPlaceholder": "请选择" + }, + "table": { + "postName": "岗位名称", + "postCode": "岗位编码", + "sort": "排序", + "status": "状态", + "createTime": "创建时间" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/system/role.json b/saiadmin-artd/src/locales/langs/zh/system/role.json new file mode 100644 index 0000000..124e53c --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/system/role.json @@ -0,0 +1,18 @@ +{ + "search": { + "roleName": "角色名称", + "roleCode": "角色编码", + "status": "状态", + "placeholderRoleName": "请输入角色名称", + "placeholderRoleCode": "请输入角色编码", + "searchSelectPlaceholder": "请选择" + }, + "table": { + "roleName": "角色名称", + "roleCode": "角色编码", + "level": "角色级别", + "roleRemark": "角色描述", + "status": "状态", + "createTime": "创建时间" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/system/user.json b/saiadmin-artd/src/locales/langs/zh/system/user.json new file mode 100644 index 0000000..f72e65c --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/system/user.json @@ -0,0 +1,21 @@ +{ + "search": { + "username": "用户名", + "phone": "手机号", + "status": "状态", + "placeholderUsername": "请输入用户名", + "placeholderPhone": "请输入手机号", + "searchSelectPlaceholder": "请选择" + }, + "table": { + "username": "用户名", + "phone": "手机号", + "dept": "部门", + "dashboard": "首页", + "loginTime": "上次登录", + "agentId": "代理ID", + "status": "状态", + "createTime": "创建时间", + "updateTime": "更新时间" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/tool/code.json b/saiadmin-artd/src/locales/langs/zh/tool/code.json new file mode 100644 index 0000000..e50e743 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/tool/code.json @@ -0,0 +1,20 @@ +{ + "search": { + "tableName": "表名称", + "placeholderTableName": "请输入数据表名称", + "placeholderDataSource": "请输入数据源名称" + }, + "table": { + "tableName": "表名称", + "tableDesc": "表描述", + "tableComment": "表注释", + "engine": "引擎", + "collation": "编码", + "template": "应用类型", + "namespace": "应用名称", + "stub": "模板类型", + "tplCategory": "生成类型", + "updateTime": "更新时间", + "createTime": "创建时间" + } +} diff --git a/saiadmin-artd/src/locales/langs/zh/tool/crontab.json b/saiadmin-artd/src/locales/langs/zh/tool/crontab.json new file mode 100644 index 0000000..ae21ea6 --- /dev/null +++ b/saiadmin-artd/src/locales/langs/zh/tool/crontab.json @@ -0,0 +1,21 @@ +{ + "search": { + "taskName": "任务名称", + "taskType": "任务类型", + "status": "状态", + "placeholderTaskName": "请输入任务名称", + "searchSelectPlaceholder": "请选择" + }, + "table": { + "no": "编号", + "taskName": "任务名称", + "taskType": "任务类型", + "rule": "定时规则", + "target": "调用目标", + "status": "状态", + "updateDate": "更新日期", + "executeTime": "执行时间", + "parameter": "任务参数", + "executeStatus": "执行状态" + } +} diff --git a/saiadmin-artd/src/locales/pageLocaleLoader.ts b/saiadmin-artd/src/locales/pageLocaleLoader.ts new file mode 100644 index 0000000..427f909 --- /dev/null +++ b/saiadmin-artd/src/locales/pageLocaleLoader.ts @@ -0,0 +1,84 @@ +/** + * 按路由加载页面级翻译到 page 命名空间 + * 路由 /dice/lottery_pool_config/index -> 加载 langs/{locale}/dice/lottery_pool_config.json + */ +import i18n from '@/locales' +import { LanguageEnum } from '@/enums/appEnum' + +/** 路由 path 到 locale 文件路径的映射(无前导斜杠、无 /index) */ +export function getPageLocalePath(routePath: string): string | null { + if (!routePath || routePath === '/') return null + const normalized = routePath.replace(/\?.*$/, '').replace(/#.*$/, '').replace(/\/$/, '') + const withoutIndex = normalized.replace(/\/index$/i, '') || '/' + const path = withoutIndex.replace(/^\//, '') || '' + if (!path) return null + return path +} + +type PageLocaleModule = { default: Record } + +const enModules = import.meta.glob('./langs/en/**/*.json') +const zhModules = import.meta.glob('./langs/zh/**/*.json') + +function getModuleKey(locale: string, path: string): string { + return `./langs/${locale}/${path}.json` +} + +let lastLoadedPath: string | null = null +let lastLoadedLocale: string | null = null + +/** + * 加载并合并页面翻译到 i18n 的 page 命名空间 + */ +export async function loadPageLocale(routePath: string): Promise { + const path = getPageLocalePath(routePath) + if (!path) { + clearPageLocale() + return + } + const locale = i18n.global.locale.value + const key = getModuleKey(locale, path) + const modules = locale === LanguageEnum.EN ? enModules : zhModules + const loader = modules[key] + if (!loader) { + clearPageLocale() + return + } + if (lastLoadedPath === path && lastLoadedLocale === locale) { + return + } + try { + const mod = await loader() + const message = mod?.default + if (message && typeof message === 'object') { + i18n.global.mergeLocaleMessage(locale, { page: message }) + lastLoadedPath = path + lastLoadedLocale = locale + } + } catch { + clearPageLocale() + } +} + +/** + * 清除 page 命名空间(进入无页面翻译的路由时调用) + */ +export function clearPageLocale(): void { + const locale = i18n.global.locale.value + const messages = i18n.global.getLocaleMessage(locale) as Record + if (messages && 'page' in messages) { + const next = { ...messages } + delete next.page + i18n.global.setLocaleMessage(locale, next) + } + lastLoadedPath = null + lastLoadedLocale = null +} + +/** + * 语言切换时清空缓存,下次进入页面会重新加载 + */ +export function invalidatePageLocaleCache(): void { + lastLoadedPath = null + lastLoadedLocale = null +} diff --git a/saiadmin-artd/src/router/guards/beforeEach.ts b/saiadmin-artd/src/router/guards/beforeEach.ts index 32971ac..cd07722 100644 --- a/saiadmin-artd/src/router/guards/beforeEach.ts +++ b/saiadmin-artd/src/router/guards/beforeEach.ts @@ -44,6 +44,7 @@ import { useMenuStore } from '@/store/modules/menu' import { useDictStore } from '@/store/modules/dict' import { setWorktab } from '@/utils/navigation' import { setPageTitle } from '@/utils/router' +import { loadPageLocale } from '@/locales/pageLocaleLoader' import { RoutesAlias } from '../routesAlias' import { staticRoutes } from '../routes/staticRoutes' import { loadingService } from '@/utils/ui' @@ -190,6 +191,7 @@ async function handleRouteGuard( if (to.matched.length > 0) { setWorktab(to) setPageTitle(to) + await loadPageLocale(to.path) next() return } diff --git a/saiadmin-artd/src/views/dashboard/console/modules/active-user.vue b/saiadmin-artd/src/views/dashboard/console/modules/active-user.vue index fcfa230..34c61a4 100644 --- a/saiadmin-artd/src/views/dashboard/console/modules/active-user.vue +++ b/saiadmin-artd/src/views/dashboard/console/modules/active-user.vue @@ -2,7 +2,7 @@
-

月度玩家充值汇总

+

{{ $t('console.activeUser.title') }}

- 玩家注册 + {{ $t('console.card.playerRegister') }}
- 较上周 + {{ $t('console.card.vsLastWeek') }}
- 玩家充值 + {{ $t('console.card.playerCharge') }}
- 较上周 + {{ $t('console.card.vsLastWeek') }}
- 玩家提现 + {{ $t('console.card.playerWithdraw') }}
- 较上周 + {{ $t('console.card.vsLastWeek') }}
- 玩家游玩次数 + {{ $t('console.card.playerPlayCount') }}
- 较上周 + {{ $t('console.card.vsLastWeek') }}
-

动态

-

新增+6

+

{{ $t('console.dynamic.title') }}

+

{{ $t('console.dynamic.newCount') }}+6

diff --git a/saiadmin-artd/src/views/dashboard/console/modules/new-player-list.vue b/saiadmin-artd/src/views/dashboard/console/modules/new-player-list.vue index 076da35..b835328 100644 --- a/saiadmin-artd/src/views/dashboard/console/modules/new-player-list.vue +++ b/saiadmin-artd/src/views/dashboard/console/modules/new-player-list.vue @@ -2,8 +2,8 @@
-

新增玩家

-

最新50条新增玩家记录

+

{{ $t('console.newPlayer.title') }}

+

{{ $t('console.newPlayer.subtitle') }}

diff --git a/saiadmin-artd/src/views/dashboard/console/modules/new-user.vue b/saiadmin-artd/src/views/dashboard/console/modules/new-user.vue index 9d39522..acb4832 100644 --- a/saiadmin-artd/src/views/dashboard/console/modules/new-user.vue +++ b/saiadmin-artd/src/views/dashboard/console/modules/new-user.vue @@ -2,13 +2,13 @@
-

新用户

-

这个月增长+20%

+

{{ $t('console.newUser.title') }}

+

{{ $t('console.newUser.growth') }}+20%

- - - + {{ $t('console.newUser.thisMonth') }} + {{ $t('console.newUser.lastMonth') }} + {{ $t('console.newUser.thisYear') }}