Compare commits
5 Commits
8e51ca8930
...
f6b4fb99f0
| Author | SHA1 | Date | |
|---|---|---|---|
| f6b4fb99f0 | |||
| 216d3ac8fe | |||
| c790f74905 | |||
| 4a7397ce04 | |||
| 861d5c49b3 |
@@ -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)
|
||||
}
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
</li>
|
||||
<li class="btn-item" @click="clearCache()">
|
||||
<ArtSvgIcon icon="ri:eraser-line" />
|
||||
<span>清除缓存</span>
|
||||
<span>{{ $t('topBar.user.clearCache') }}</span>
|
||||
</li>
|
||||
<li class="btn-item" @click="lockScreen()">
|
||||
<ArtSvgIcon icon="ri:lock-line" />
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
v-bind="{ ...$attrs, ...props, height, stripe, border, size, headerCellStyle }"
|
||||
@sort-change="handleSortChange"
|
||||
>
|
||||
<template v-for="col in columns" :key="col.prop || col.type">
|
||||
<template v-for="col in displayColumns" :key="col.prop || col.type">
|
||||
<!-- 渲染全局序号列 -->
|
||||
<ElTableColumn v-if="col.type === 'globalIndex'" v-bind="{ ...col }">
|
||||
<template #default="{ $index }">
|
||||
@@ -138,6 +138,7 @@
|
||||
import { useCommon } from '@/hooks/core/useCommon'
|
||||
import { useTableHeight } from '@/hooks/core/useTableHeight'
|
||||
import { useResizeObserver, useWindowSize } from '@vueuse/core'
|
||||
import i18n, { $t } from '@/locales'
|
||||
|
||||
defineOptions({ name: 'ArtTable' })
|
||||
|
||||
@@ -307,6 +308,18 @@
|
||||
// 是否显示分页器
|
||||
const showPagination = computed(() => props.pagination && !isEmpty.value)
|
||||
|
||||
/** 表头 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.') || label.startsWith('page.')) && i18n.global.te(label)) {
|
||||
return { ...col, label: $t(label) }
|
||||
}
|
||||
return col
|
||||
})
|
||||
})
|
||||
|
||||
// 清理列属性,移除插槽相关的自定义属性,确保它们不会被 ElTableColumn 错误解释
|
||||
const cleanColumnProps = (col: ColumnOption) => {
|
||||
const columnProps = { ...col }
|
||||
|
||||
42
saiadmin-artd/src/locales/langs/README.md
Normal file
42
saiadmin-artd/src/locales/langs/README.md
Normal file
@@ -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` 命名空间;切换语言会清空缓存,下次进入或刷新后加载新语言文件。
|
||||
@@ -22,6 +22,7 @@
|
||||
"userCenter": "User center",
|
||||
"docs": "Document",
|
||||
"github": "Github",
|
||||
"clearCache": "clear Cache",
|
||||
"lockScreen": "Lock screen",
|
||||
"logout": "Log out"
|
||||
},
|
||||
@@ -38,6 +39,14 @@
|
||||
"confirm": "Confirm",
|
||||
"logOutTips": "Do you want to log out?"
|
||||
},
|
||||
"form": {
|
||||
"placeholderInput": "Please enter",
|
||||
"placeholderSelect": "Please select",
|
||||
"labelRemark": "Remark",
|
||||
"labelStatus": "Status",
|
||||
"labelName": "Name",
|
||||
"close": "Close"
|
||||
},
|
||||
"search": {
|
||||
"placeholder": "Search page",
|
||||
"historyTitle": "Search history",
|
||||
@@ -230,6 +239,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"
|
||||
@@ -313,7 +372,54 @@
|
||||
"expand": "Expand",
|
||||
"collapse": "Collapse",
|
||||
"searchInputPlaceholder": "Please enter",
|
||||
"searchSelectPlaceholder": "Please select"
|
||||
"searchSelectPlaceholder": "Please select",
|
||||
"all": "All",
|
||||
"min": "Min",
|
||||
"max": "Max",
|
||||
"startTime": "Start Time",
|
||||
"endTime": "End Time",
|
||||
"placeholderUsername": "Username",
|
||||
"placeholderNickname": "Nickname",
|
||||
"placeholderPhone": "Phone",
|
||||
"placeholderPhoneFuzzy": "Phone (fuzzy)",
|
||||
"placeholderName": "Name",
|
||||
"placeholderGroup": "Group",
|
||||
"placeholderTitle": "Title",
|
||||
"placeholderConfigName": "Config Name",
|
||||
"placeholderTaskName": "Task Name",
|
||||
"placeholderTableName": "Table Name",
|
||||
"placeholderDataSource": "Data Source",
|
||||
"placeholderDeptName": "Dept Name",
|
||||
"placeholderDeptCode": "Dept Code",
|
||||
"placeholderRoleName": "Role Name",
|
||||
"placeholderRoleCode": "Role Code",
|
||||
"placeholderPostName": "Post Name",
|
||||
"placeholderPostCode": "Post Code",
|
||||
"placeholderMenuName": "Menu Name",
|
||||
"placeholderMenuRoute": "Menu Route",
|
||||
"placeholderOperator": "Operator",
|
||||
"placeholderOperRouter": "Route",
|
||||
"placeholderOperIp": "IP",
|
||||
"placeholderLoginUser": "Login User",
|
||||
"placeholderLoginIp": "Login IP",
|
||||
"placeholderLoginStatus": "Login Status",
|
||||
"labelFrom": "From",
|
||||
"labelTo": "To",
|
||||
"placeholderFrom": "From",
|
||||
"placeholderTo": "To",
|
||||
"placeholderSendStatus": "Send Status",
|
||||
"placeholderPoolType": "Pool Type",
|
||||
"usernameFuzzy": "Username (fuzzy)",
|
||||
"nameFuzzy": "Name (fuzzy)",
|
||||
"uiTextFuzzy": "UI Text (fuzzy)",
|
||||
"fuzzyQuery": "Fuzzy",
|
||||
"byUsername": "Search by username",
|
||||
"exactSearch": "Exact",
|
||||
"enable": "Enable",
|
||||
"disable": "Disable",
|
||||
"rangeSeparator": "To",
|
||||
"success": "Success",
|
||||
"failure": "Failure"
|
||||
},
|
||||
"selection": "Select",
|
||||
"sizeOptions": {
|
||||
@@ -326,6 +432,184 @@
|
||||
"expand": "Expand",
|
||||
"index": "Index"
|
||||
},
|
||||
"actions": {
|
||||
"add": "Add",
|
||||
"delete": "Delete",
|
||||
"edit": "Edit",
|
||||
"operation": "Operation",
|
||||
"refresh": "Refresh",
|
||||
"export": "Export",
|
||||
"import": "Import"
|
||||
},
|
||||
"columns": {
|
||||
"common": {
|
||||
"id": "ID",
|
||||
"status": "Status",
|
||||
"createTime": "Create Time",
|
||||
"updateTime": "Update Time",
|
||||
"operation": "Operation",
|
||||
"remark": "Remark",
|
||||
"sort": "Sort",
|
||||
"name": "Name",
|
||||
"no": "No.",
|
||||
"description": "Description",
|
||||
"select": "Select"
|
||||
},
|
||||
"system": {
|
||||
"username": "Username",
|
||||
"phone": "Phone",
|
||||
"dept": "Department",
|
||||
"dashboard": "Dashboard",
|
||||
"loginTime": "Last Login",
|
||||
"agentId": "Agent ID",
|
||||
"postName": "Post Name",
|
||||
"postCode": "Post Code",
|
||||
"deptName": "Dept Name",
|
||||
"deptCode": "Dept Code",
|
||||
"leader": "Leader",
|
||||
"roleName": "Role Name",
|
||||
"roleCode": "Role Code",
|
||||
"level": "Level",
|
||||
"roleRemark": "Role Description",
|
||||
"menuName": "Menu Name",
|
||||
"menuType": "Menu Type",
|
||||
"icon": "Icon",
|
||||
"component": "Component",
|
||||
"route": "Route",
|
||||
"auth": "Auth",
|
||||
"configKey": "Config Key",
|
||||
"configTitle": "Config Title",
|
||||
"inputType": "Input Type",
|
||||
"configName": "Config Name",
|
||||
"group": "Group",
|
||||
"title": "Title",
|
||||
"titleEn": "Title (EN)",
|
||||
"value": "Value",
|
||||
"valueEn": "Value (EN)",
|
||||
"noParentDept": "No Parent Dept",
|
||||
"noParentMenu": "No Parent Menu",
|
||||
"input": "Input",
|
||||
"textarea": "Textarea",
|
||||
"select": "Select",
|
||||
"radio": "Radio",
|
||||
"uploadImage": "Image Upload",
|
||||
"uploadFile": "File Upload",
|
||||
"wangEditor": "Rich Editor",
|
||||
"createDate": "Create Date",
|
||||
"updateDate": "Update Date"
|
||||
},
|
||||
"safeguard": {
|
||||
"operator": "Operator",
|
||||
"serviceName": "Service",
|
||||
"router": "Route",
|
||||
"operIp": "IP",
|
||||
"operLocation": "Location",
|
||||
"operTime": "Time",
|
||||
"loginUser": "Login User",
|
||||
"loginStatus": "Login Status",
|
||||
"loginIp": "Login IP",
|
||||
"loginLocation": "Location",
|
||||
"os": "OS",
|
||||
"browser": "Browser",
|
||||
"tableName": "Table Name",
|
||||
"tableComment": "Table Comment",
|
||||
"engine": "Engine",
|
||||
"tableEngine": "Table Engine",
|
||||
"totalRows": "Total Rows",
|
||||
"fragmentSize": "Fragment Size",
|
||||
"dataSize": "Data Size",
|
||||
"collation": "Collation",
|
||||
"dictName": "Dict Name",
|
||||
"dictCode": "Dict Code",
|
||||
"dictLabel": "Dict Label",
|
||||
"dictValue": "Dict Value",
|
||||
"color": "Color",
|
||||
"preview": "Preview",
|
||||
"fileName": "File Name",
|
||||
"storageMode": "Storage",
|
||||
"fileType": "File Type",
|
||||
"fileSize": "File Size",
|
||||
"uploadTime": "Upload Time",
|
||||
"deleteTime": "Delete Time",
|
||||
"dataDetail": "Data Detail",
|
||||
"executeTime": "Execute Time",
|
||||
"target": "Target",
|
||||
"parameter": "Parameter",
|
||||
"executeStatus": "Status",
|
||||
"loginMessage": "Login Message",
|
||||
"loginTime": "Login Time",
|
||||
"gateway": "Gateway",
|
||||
"emailFrom": "From",
|
||||
"emailTo": "To",
|
||||
"emailCode": "Code",
|
||||
"emailResponse": "Response",
|
||||
"sendTime": "Send Time",
|
||||
"sendStatus": "Send Status"
|
||||
},
|
||||
"tool": {
|
||||
"taskName": "Task Name",
|
||||
"taskType": "Task Type",
|
||||
"rule": "Rule",
|
||||
"updateDate": "Update Date",
|
||||
"tableDesc": "Table Desc",
|
||||
"template": "Template",
|
||||
"namespace": "Namespace",
|
||||
"stub": "Stub",
|
||||
"tplCategory": "Gen Type",
|
||||
"topMenu": "Top Menu"
|
||||
},
|
||||
"dice": {
|
||||
"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",
|
||||
"user": "User",
|
||||
"coinChange": "Coin Change",
|
||||
"type": "Type",
|
||||
"operator": "Operator",
|
||||
"walletBefore": "Wallet Before",
|
||||
"walletAfter": "Wallet After",
|
||||
"totalDrawCount": "Total Draw Count",
|
||||
"paidDrawCount": "Paid Draw Count",
|
||||
"freeDrawCount": "Free Draw Count",
|
||||
"paidDraw": "Paid Draw",
|
||||
"freeDraw": "Free Draw",
|
||||
"platformProfit": "Platform Profit",
|
||||
"createdBy": "Created By",
|
||||
"rewardTier": "Reward Tier",
|
||||
"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",
|
||||
"endIndex": "End Index",
|
||||
"tier": "Tier",
|
||||
"dicePoints": "Dice Points",
|
||||
"displayText": "Display Text",
|
||||
"realEv": "Real EV",
|
||||
"weight": "Weight",
|
||||
"nickname": "Nickname",
|
||||
"coin": "Coin",
|
||||
"t1Weight": "T1 Weight",
|
||||
"t2Weight": "T2 Weight",
|
||||
"t3Weight": "T3 Weight",
|
||||
"t4Weight": "T4 Weight",
|
||||
"t5Weight": "T5 Weight",
|
||||
"playerUsername": "Player Username",
|
||||
"useCoins": "Use Coins"
|
||||
}
|
||||
},
|
||||
"zebra": "Zebra",
|
||||
"border": "Border",
|
||||
"headerBackground": "Header BG"
|
||||
|
||||
41
saiadmin-artd/src/locales/langs/en/dice/config.json
Normal file
41
saiadmin-artd/src/locales/langs/en/dice/config.json
Normal file
@@ -0,0 +1,41 @@
|
||||
{
|
||||
"form": {
|
||||
"dialogTitleAdd": "Add Dice Config",
|
||||
"dialogTitleEdit": "Edit Dice Config",
|
||||
"group": "Group",
|
||||
"placeholderGroup": "Please enter group",
|
||||
"title": "Title",
|
||||
"placeholderTitleZh": "Please enter title (ZH)",
|
||||
"titleEn": "Title (EN)",
|
||||
"placeholderTitleEn": "Please enter title (EN)",
|
||||
"configName": "Config Name",
|
||||
"placeholderConfigName": "Please enter config name",
|
||||
"value": "Value",
|
||||
"placeholderValueZh": "Please enter value (ZH)",
|
||||
"valueEn": "Value (EN)",
|
||||
"placeholderValueEn": "Please enter value (EN)",
|
||||
"ruleGroupRequired": "Group is required",
|
||||
"ruleTitleRequired": "Title is required",
|
||||
"ruleTitleEnMax": "Title (EN) max 255 characters",
|
||||
"ruleConfigNameRequired": "Config name is required",
|
||||
"ruleValueRequired": "Value is required",
|
||||
"saveSuccess": "Added",
|
||||
"updateSuccess": "Updated"
|
||||
},
|
||||
"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)"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,71 @@
|
||||
{
|
||||
"name": "Name",
|
||||
"form": {
|
||||
"dialogTitleAdd": "Add Lottery Pool Config",
|
||||
"dialogTitleEdit": "Edit Lottery Pool Config",
|
||||
"placeholderName": "Please enter name",
|
||||
"placeholderRemark": "Please enter remark",
|
||||
"poolType": "Pool Type",
|
||||
"placeholderPoolType": "Please select pool type",
|
||||
"poolTypeNormal": "Normal",
|
||||
"poolTypeKill": "Kill",
|
||||
"poolTypeT1": "T1 High",
|
||||
"safetyLine": "Safety Line",
|
||||
"t1Weight": "T1 Pool Weight (%)",
|
||||
"t2Weight": "T2 Pool Weight (%)",
|
||||
"t3Weight": "T3 Pool Weight (%)",
|
||||
"t4Weight": "T4 Pool Weight (%)",
|
||||
"t5Weight": "T5 Pool Weight (%)",
|
||||
"weightsSumHint": "Total pool weights: ",
|
||||
"weightsSumUnit": "% / 100% (must equal 100%)",
|
||||
"weightsSumUnitCurrent": "% / 100%",
|
||||
"currentPoolTitle": "Current Lottery Pool",
|
||||
"loading": "Loading...",
|
||||
"poolName": "Pool Name",
|
||||
"playerProfit": "Player Total Profit (profit_amount):",
|
||||
"realtime": "Live",
|
||||
"profitCalcHint": "Sum of (win amount including BIGWIN minus 100 ticket cost) per round; refreshes every 2s while open.",
|
||||
"tierRuleTitle": "Tier Rule",
|
||||
"tierRuleContent": "When player profit in this pool is below safety line, use player T*_weight; when above or equal, use pool T*_weight (kill).",
|
||||
"killScoreWeights": "Kill weights (type=1 read-only)",
|
||||
"killWeightNote": "(Kill weights from pool config type=1; edit in list.)",
|
||||
"btnResetProfit": "Reset Player Total Profit",
|
||||
"btnSaveSafetyLine": "Save Safety Line",
|
||||
"ruleSafetyLineRequired": "Please enter safety line",
|
||||
"msgGetPoolFailed": "Failed to get lottery pool",
|
||||
"msgSaveSuccess": "Saved",
|
||||
"msgResetProfitSuccess": "Player total profit reset to 0",
|
||||
"msgResetFailed": "Reset failed",
|
||||
"ruleNameRequired": "Name is required",
|
||||
"rulePoolTypeRequired": "Please select pool type",
|
||||
"ruleT1Required": "T1 weight is required",
|
||||
"ruleT2Required": "T2 weight is required",
|
||||
"ruleT3Required": "T3 weight is required",
|
||||
"ruleT4Required": "T4 weight is required",
|
||||
"ruleT5Required": "T5 weight is required",
|
||||
"msgWeightsMust100": "Total pool weights must equal 100%",
|
||||
"msgAddSuccess": "Added",
|
||||
"msgUpdateSuccess": "Updated"
|
||||
},
|
||||
"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"
|
||||
}
|
||||
}
|
||||
74
saiadmin-artd/src/locales/langs/en/dice/play_record.json
Normal file
74
saiadmin-artd/src/locales/langs/en/dice/play_record.json
Normal file
@@ -0,0 +1,74 @@
|
||||
{
|
||||
"form": {
|
||||
"dialogTitleAdd": "Add Play Record",
|
||||
"dialogTitleEdit": "Edit Play Record",
|
||||
"player": "Player",
|
||||
"placeholderPlayer": "Select player (by username)",
|
||||
"lotteryPoolConfig": "Lottery Pool Config",
|
||||
"placeholderLotteryPool": "Select lottery pool config",
|
||||
"drawType": "Draw Type",
|
||||
"paid": "Paid",
|
||||
"free": "Free",
|
||||
"isBigWin": "Big Win",
|
||||
"noBigWin": "No",
|
||||
"bigWin": "Big Win",
|
||||
"winCoin": "Win Coin",
|
||||
"placeholderWinCoin": "= Super + Reward",
|
||||
"superWinCoin": "Super Win Coin",
|
||||
"placeholderSuperWinCoin": "On BIGWIN",
|
||||
"rewardWinCoin": "Reward Win Coin",
|
||||
"placeholderRewardWinCoin": "Dice reward",
|
||||
"direction": "Direction",
|
||||
"placeholderDirection": "Select direction",
|
||||
"clockwise": "Clockwise",
|
||||
"anticlockwise": "Anticlockwise",
|
||||
"startIndex": "Start Index",
|
||||
"placeholderStartIndex": "Start index",
|
||||
"targetIndex": "Target Index",
|
||||
"placeholderTargetIndex": "Target index",
|
||||
"rollArray": "Roll Array",
|
||||
"rollArrayHint": "5 numbers, each 1–6",
|
||||
"rollNumber": "Roll Sum",
|
||||
"placeholderRollNumber": "Sum of 5 dice (5–30)",
|
||||
"rewardConfig": "Reward Config",
|
||||
"placeholderRewardConfig": "Select reward config (by UI text)"
|
||||
},
|
||||
"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"
|
||||
}
|
||||
}
|
||||
@@ -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"
|
||||
}
|
||||
}
|
||||
79
saiadmin-artd/src/locales/langs/en/dice/player.json
Normal file
79
saiadmin-artd/src/locales/langs/en/dice/player.json
Normal file
@@ -0,0 +1,79 @@
|
||||
{
|
||||
"name": "Name",
|
||||
"form": {
|
||||
"dialogTitleAdd": "Add Dice Player",
|
||||
"dialogTitleEdit": "Edit Dice Player",
|
||||
"username": "Username",
|
||||
"placeholderUsername": "Please enter username",
|
||||
"nickname": "Nickname",
|
||||
"placeholderNickname": "Please enter nickname",
|
||||
"phone": "Phone",
|
||||
"placeholderPhone": "Please enter phone",
|
||||
"password": "Password",
|
||||
"placeholderPasswordEdit": "Leave blank to keep unchanged",
|
||||
"status": "Status",
|
||||
"adminId": "Admin",
|
||||
"placeholderAdmin": "Select admin (optional)",
|
||||
"coin": "Coin",
|
||||
"placeholderCoinAdd": "Default 0 on create, read-only",
|
||||
"lotteryPoolConfig": "Lottery Pool Config",
|
||||
"placeholderLotteryPool": "Leave empty for custom weights below, or select pool",
|
||||
"currentConfig": "Current Config",
|
||||
"configLabelName": "Name",
|
||||
"configLabelType": "Type",
|
||||
"configLabelWeights": "T1–T5 Weights",
|
||||
"configLabelRemark": "Remark",
|
||||
"t1Weight": "T1 Pool Weight (%)",
|
||||
"t2Weight": "T2 Pool Weight (%)",
|
||||
"t3Weight": "T3 Pool Weight (%)",
|
||||
"t4Weight": "T4 Pool Weight (%)",
|
||||
"t5Weight": "T5 Pool Weight (%)",
|
||||
"weightsSumHint": "Total pool weights: ",
|
||||
"weightsSumUnit": "% / 100% (must equal 100%)",
|
||||
"walletTitle": "Player Wallet Operation",
|
||||
"walletPlayer": "Player",
|
||||
"walletBalance": "Balance",
|
||||
"operationType": "Operation Type",
|
||||
"typeAdd": "Add",
|
||||
"typeSub": "Deduct",
|
||||
"coinChange": "Coin Change",
|
||||
"placeholderCoinChange": "Positive; deduct cannot exceed balance",
|
||||
"placeholderRemarkOptional": "Optional",
|
||||
"ruleSelectType": "Please select operation type",
|
||||
"ruleEnterCoin": "Please enter coin change",
|
||||
"ruleCoinPositive": "Coin change must be greater than 0",
|
||||
"ruleDeductExceed": "Deduct cannot exceed current balance",
|
||||
"operateSuccess": "Success"
|
||||
},
|
||||
"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"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
{
|
||||
"form": {
|
||||
"dialogTitleAdd": "Add Ticket Record",
|
||||
"dialogTitleEdit": "Edit Ticket Record",
|
||||
"player": "Player",
|
||||
"placeholderPlayer": "Select player (by username)",
|
||||
"useCoins": "Use Coins",
|
||||
"placeholderUseCoins": "Please enter use coins",
|
||||
"paidDrawCount": "Paid Draw Count",
|
||||
"placeholderPaidDrawCount": "Please enter paid draw count",
|
||||
"freeDrawCount": "Free Draw Count",
|
||||
"placeholderFreeDrawCount": "Please enter free draw count",
|
||||
"totalDrawCount": "Total Draw Count",
|
||||
"placeholderTotalDrawCount": "Auto sum",
|
||||
"placeholderRemark": "Remark (required)"
|
||||
},
|
||||
"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"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,49 @@
|
||||
{
|
||||
"form": {
|
||||
"dialogTitleAdd": "Add Wallet Record",
|
||||
"dialogTitleEdit": "Edit Wallet Record",
|
||||
"user": "User",
|
||||
"placeholderUser": "Select user (by username)",
|
||||
"type": "Type",
|
||||
"placeholderType": "Please select type",
|
||||
"typeRecharge": "Recharge",
|
||||
"typeWithdraw": "Withdraw",
|
||||
"typeBuyTicket": "Buy Tickets",
|
||||
"typeAdminAdd": "Admin Add",
|
||||
"typeAdminSub": "Admin Deduct",
|
||||
"coinChange": "Coin Change",
|
||||
"placeholderCoinChange": "Positive add, negative subtract",
|
||||
"walletBefore": "Before",
|
||||
"placeholderWalletBefore": "Auto from selected user",
|
||||
"walletAfter": "After",
|
||||
"placeholderWalletAfter": "Auto calculated",
|
||||
"placeholderRemark": "Optional"
|
||||
},
|
||||
"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"
|
||||
}
|
||||
}
|
||||
21
saiadmin-artd/src/locales/langs/en/dice/reward.json
Normal file
21
saiadmin-artd/src/locales/langs/en/dice/reward.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
23
saiadmin-artd/src/locales/langs/en/dice/reward_config.json
Normal file
23
saiadmin-artd/src/locales/langs/en/dice/reward_config.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
@@ -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"
|
||||
}
|
||||
}
|
||||
18
saiadmin-artd/src/locales/langs/en/safeguard/attachment.json
Normal file
18
saiadmin-artd/src/locales/langs/en/safeguard/attachment.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
19
saiadmin-artd/src/locales/langs/en/safeguard/database.json
Normal file
19
saiadmin-artd/src/locales/langs/en/safeguard/database.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
12
saiadmin-artd/src/locales/langs/en/safeguard/dict.json
Normal file
12
saiadmin-artd/src/locales/langs/en/safeguard/dict.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
22
saiadmin-artd/src/locales/langs/en/safeguard/login-log.json
Normal file
22
saiadmin-artd/src/locales/langs/en/safeguard/login-log.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
20
saiadmin-artd/src/locales/langs/en/safeguard/oper-log.json
Normal file
20
saiadmin-artd/src/locales/langs/en/safeguard/oper-log.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
15
saiadmin-artd/src/locales/langs/en/system/config.json
Normal file
15
saiadmin-artd/src/locales/langs/en/system/config.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
18
saiadmin-artd/src/locales/langs/en/system/dept.json
Normal file
18
saiadmin-artd/src/locales/langs/en/system/dept.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
21
saiadmin-artd/src/locales/langs/en/system/menu.json
Normal file
21
saiadmin-artd/src/locales/langs/en/system/menu.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
17
saiadmin-artd/src/locales/langs/en/system/post.json
Normal file
17
saiadmin-artd/src/locales/langs/en/system/post.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
18
saiadmin-artd/src/locales/langs/en/system/role.json
Normal file
18
saiadmin-artd/src/locales/langs/en/system/role.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
21
saiadmin-artd/src/locales/langs/en/system/user.json
Normal file
21
saiadmin-artd/src/locales/langs/en/system/user.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
20
saiadmin-artd/src/locales/langs/en/tool/code.json
Normal file
20
saiadmin-artd/src/locales/langs/en/tool/code.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
21
saiadmin-artd/src/locales/langs/en/tool/crontab.json
Normal file
21
saiadmin-artd/src/locales/langs/en/tool/crontab.json
Normal file
@@ -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"
|
||||
}
|
||||
}
|
||||
@@ -22,6 +22,7 @@
|
||||
"userCenter": "个人中心",
|
||||
"docs": "使用文档",
|
||||
"github": "Github",
|
||||
"clearCache": "清除缓存",
|
||||
"lockScreen": "锁定屏幕",
|
||||
"logout": "退出登录"
|
||||
},
|
||||
@@ -38,6 +39,14 @@
|
||||
"confirm": "确定",
|
||||
"logOutTips": "您是否要退出登录?"
|
||||
},
|
||||
"form": {
|
||||
"placeholderInput": "请输入",
|
||||
"placeholderSelect": "请选择",
|
||||
"labelRemark": "备注",
|
||||
"labelStatus": "状态",
|
||||
"labelName": "名称",
|
||||
"close": "关闭"
|
||||
},
|
||||
"search": {
|
||||
"placeholder": "搜索页面",
|
||||
"historyTitle": "搜索历史",
|
||||
@@ -230,6 +239,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 +322,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": {
|
||||
@@ -277,7 +368,54 @@
|
||||
"expand": "展开",
|
||||
"collapse": "收起",
|
||||
"searchInputPlaceholder": "请输入",
|
||||
"searchSelectPlaceholder": "请选择"
|
||||
"searchSelectPlaceholder": "请选择",
|
||||
"all": "全部",
|
||||
"min": "最小",
|
||||
"max": "最大",
|
||||
"startTime": "开始时间",
|
||||
"endTime": "结束时间",
|
||||
"placeholderUsername": "请输入用户名",
|
||||
"placeholderNickname": "请输入昵称",
|
||||
"placeholderPhone": "请输入手机号",
|
||||
"placeholderPhoneFuzzy": "手机号模糊查询",
|
||||
"placeholderName": "请输入名称",
|
||||
"placeholderGroup": "请输入分组",
|
||||
"placeholderTitle": "请输入标题",
|
||||
"placeholderConfigName": "请输入配置名称",
|
||||
"placeholderTaskName": "请输入任务名称",
|
||||
"placeholderTableName": "请输入数据表名称",
|
||||
"placeholderDataSource": "请输入数据源名称",
|
||||
"placeholderDeptName": "请输入部门名称",
|
||||
"placeholderDeptCode": "请输入部门编码",
|
||||
"placeholderRoleName": "请输入角色名称",
|
||||
"placeholderRoleCode": "请输入角色编码",
|
||||
"placeholderPostName": "请输入岗位名称",
|
||||
"placeholderPostCode": "请输入岗位编码",
|
||||
"placeholderMenuName": "请输入菜单名称",
|
||||
"placeholderMenuRoute": "请输入菜单路由",
|
||||
"placeholderOperator": "请输入操作用户",
|
||||
"placeholderOperRouter": "请输入操作路由",
|
||||
"placeholderOperIp": "请输入操作IP",
|
||||
"placeholderLoginUser": "请输入登录用户",
|
||||
"placeholderLoginIp": "请输入登录IP",
|
||||
"placeholderLoginStatus": "请选择登录状态",
|
||||
"labelFrom": "发件人",
|
||||
"labelTo": "收件人",
|
||||
"placeholderFrom": "请输入发件人",
|
||||
"placeholderTo": "请输入收件人",
|
||||
"placeholderSendStatus": "请选择发送状态",
|
||||
"placeholderPoolType": "请选择奖池类型",
|
||||
"usernameFuzzy": "用户名模糊",
|
||||
"nameFuzzy": "名称模糊",
|
||||
"uiTextFuzzy": "前端显示文本模糊",
|
||||
"fuzzyQuery": "模糊查询",
|
||||
"byUsername": "按用户名搜索",
|
||||
"exactSearch": "精确搜索",
|
||||
"enable": "启用",
|
||||
"disable": "禁用",
|
||||
"rangeSeparator": "至",
|
||||
"success": "成功",
|
||||
"failure": "失败"
|
||||
},
|
||||
"selection": "选择",
|
||||
"sizeOptions": {
|
||||
@@ -290,6 +428,184 @@
|
||||
"expand": "展开",
|
||||
"index": "序号"
|
||||
},
|
||||
"actions": {
|
||||
"add": "新增",
|
||||
"delete": "删除",
|
||||
"edit": "编辑",
|
||||
"operation": "操作",
|
||||
"refresh": "刷新",
|
||||
"export": "导出",
|
||||
"import": "导入"
|
||||
},
|
||||
"columns": {
|
||||
"common": {
|
||||
"id": "ID",
|
||||
"status": "状态",
|
||||
"createTime": "创建时间",
|
||||
"updateTime": "更新时间",
|
||||
"operation": "操作",
|
||||
"remark": "备注",
|
||||
"sort": "排序",
|
||||
"name": "名称",
|
||||
"no": "编号",
|
||||
"description": "描述",
|
||||
"select": "选中"
|
||||
},
|
||||
"system": {
|
||||
"username": "用户名",
|
||||
"phone": "手机号",
|
||||
"dept": "部门",
|
||||
"dashboard": "首页",
|
||||
"loginTime": "上次登录",
|
||||
"agentId": "代理ID",
|
||||
"postName": "岗位名称",
|
||||
"postCode": "岗位编码",
|
||||
"deptName": "部门名称",
|
||||
"deptCode": "部门编码",
|
||||
"leader": "部门领导",
|
||||
"roleName": "角色名称",
|
||||
"roleCode": "角色编码",
|
||||
"level": "角色级别",
|
||||
"roleRemark": "角色描述",
|
||||
"menuName": "菜单名称",
|
||||
"menuType": "菜单类型",
|
||||
"icon": "图标",
|
||||
"component": "组件名称",
|
||||
"route": "路由",
|
||||
"auth": "权限标识",
|
||||
"configKey": "配置标识",
|
||||
"configTitle": "配置标题",
|
||||
"inputType": "组件类型",
|
||||
"configName": "配置名称",
|
||||
"group": "分组",
|
||||
"title": "标题",
|
||||
"titleEn": "标题(英文)",
|
||||
"value": "值",
|
||||
"valueEn": "值(英文)",
|
||||
"noParentDept": "无上级部门",
|
||||
"noParentMenu": "无上级菜单",
|
||||
"input": "文本框",
|
||||
"textarea": "文本域",
|
||||
"select": "下拉选择框",
|
||||
"radio": "单选框",
|
||||
"uploadImage": "图片上传",
|
||||
"uploadFile": "文件上传",
|
||||
"wangEditor": "富文本编辑器",
|
||||
"createDate": "创建日期",
|
||||
"updateDate": "更新日期"
|
||||
},
|
||||
"safeguard": {
|
||||
"operator": "操作用户",
|
||||
"serviceName": "业务名称",
|
||||
"router": "路由",
|
||||
"operIp": "操作IP",
|
||||
"operLocation": "操作地点",
|
||||
"operTime": "操作时间",
|
||||
"loginUser": "登录用户",
|
||||
"loginStatus": "登录状态",
|
||||
"loginIp": "登录IP",
|
||||
"loginLocation": "登录地点",
|
||||
"os": "操作系统",
|
||||
"browser": "浏览器",
|
||||
"tableName": "表名称",
|
||||
"tableComment": "表注释",
|
||||
"engine": "引擎",
|
||||
"tableEngine": "表引擎",
|
||||
"totalRows": "总行数",
|
||||
"fragmentSize": "碎片大小",
|
||||
"dataSize": "数据大小",
|
||||
"collation": "编码",
|
||||
"dictName": "字典名称",
|
||||
"dictCode": "字典标识",
|
||||
"dictLabel": "字典标签",
|
||||
"dictValue": "字典键值",
|
||||
"color": "颜色",
|
||||
"preview": "预览",
|
||||
"fileName": "文件名称",
|
||||
"storageMode": "存储模式",
|
||||
"fileType": "文件类型",
|
||||
"fileSize": "文件大小",
|
||||
"uploadTime": "上传时间",
|
||||
"deleteTime": "删除时间",
|
||||
"dataDetail": "数据详情",
|
||||
"executeTime": "执行时间",
|
||||
"target": "调用目标",
|
||||
"parameter": "任务参数",
|
||||
"executeStatus": "执行状态",
|
||||
"loginMessage": "登录信息",
|
||||
"loginTime": "登录时间",
|
||||
"gateway": "服务Host",
|
||||
"emailFrom": "发件人",
|
||||
"emailTo": "收件人",
|
||||
"emailCode": "验证码",
|
||||
"emailResponse": "发送结果",
|
||||
"sendTime": "发送时间",
|
||||
"sendStatus": "发送状态"
|
||||
},
|
||||
"tool": {
|
||||
"taskName": "任务名称",
|
||||
"taskType": "任务类型",
|
||||
"rule": "定时规则",
|
||||
"updateDate": "更新日期",
|
||||
"tableDesc": "表描述",
|
||||
"template": "应用类型",
|
||||
"namespace": "应用名称",
|
||||
"stub": "模板类型",
|
||||
"tplCategory": "生成类型",
|
||||
"topMenu": "顶级菜单"
|
||||
},
|
||||
"dice": {
|
||||
"player": "玩家",
|
||||
"lotteryPoolConfig": "彩金池配置",
|
||||
"drawType": "抽奖类型",
|
||||
"isBigWin": "是否中大奖",
|
||||
"winCoin": "赢取平台币",
|
||||
"superWinCoin": "中大奖平台币",
|
||||
"rewardWinCoin": "摇色子中奖平台币",
|
||||
"direction": "方向",
|
||||
"startIndex": "起始索引",
|
||||
"targetIndex": "终点索引",
|
||||
"rollArray": "摇取点数",
|
||||
"rollNumber": "摇取点数和",
|
||||
"rewardConfig": "奖励配置",
|
||||
"user": "用户",
|
||||
"coinChange": "平台币变化",
|
||||
"type": "类型",
|
||||
"operator": "操作人",
|
||||
"walletBefore": "钱包操作前",
|
||||
"walletAfter": "钱包操作后",
|
||||
"totalDrawCount": "总抽奖次数",
|
||||
"paidDrawCount": "购买抽奖次数",
|
||||
"freeDrawCount": "赠送抽奖次数",
|
||||
"paidDraw": "付费抽取",
|
||||
"freeDraw": "免费抽取",
|
||||
"platformProfit": "平台赚取金额",
|
||||
"createdBy": "创建管理员",
|
||||
"rewardTier": "奖励档位",
|
||||
"poolType": "奖池类型",
|
||||
"safetyLine": "安全线",
|
||||
"t1PoolWeight": "T1池权重",
|
||||
"t2PoolWeight": "T2池权重",
|
||||
"t3PoolWeight": "T3池权重",
|
||||
"t4PoolWeight": "T4池权重",
|
||||
"t5PoolWeight": "T5池权重",
|
||||
"endIndex": "结束索引(end_index)",
|
||||
"tier": "档位",
|
||||
"dicePoints": "色子点数(摇取5-30)",
|
||||
"displayText": "显示文本",
|
||||
"realEv": "实际中奖金额",
|
||||
"weight": "权重(1-10000)",
|
||||
"nickname": "昵称",
|
||||
"coin": "平台币",
|
||||
"t1Weight": "T1权重",
|
||||
"t2Weight": "T2权重",
|
||||
"t3Weight": "T3权重",
|
||||
"t4Weight": "T4权重",
|
||||
"t5Weight": "T5权重",
|
||||
"playerUsername": "玩家用户名",
|
||||
"useCoins": "消耗硬币"
|
||||
}
|
||||
},
|
||||
"zebra": "斑马纹",
|
||||
"border": "边框",
|
||||
"headerBackground": "表头背景"
|
||||
|
||||
41
saiadmin-artd/src/locales/langs/zh/dice/config.json
Normal file
41
saiadmin-artd/src/locales/langs/zh/dice/config.json
Normal file
@@ -0,0 +1,41 @@
|
||||
{
|
||||
"form": {
|
||||
"dialogTitleAdd": "新增摇色子配置",
|
||||
"dialogTitleEdit": "编辑摇色子配置",
|
||||
"group": "分组",
|
||||
"placeholderGroup": "请输入分组",
|
||||
"title": "标题",
|
||||
"placeholderTitleZh": "请输入标题(中文)",
|
||||
"titleEn": "标题(英文)",
|
||||
"placeholderTitleEn": "请输入标题(英文)",
|
||||
"configName": "配置名称",
|
||||
"placeholderConfigName": "请输入配置名称",
|
||||
"value": "值",
|
||||
"placeholderValueZh": "请输入值(中文)",
|
||||
"valueEn": "值(英文)",
|
||||
"placeholderValueEn": "请输入值(英文)",
|
||||
"ruleGroupRequired": "分组必需填写",
|
||||
"ruleTitleRequired": "标题必需填写",
|
||||
"ruleTitleEnMax": "英文标题长度需小于 255 字符",
|
||||
"ruleConfigNameRequired": "配置名称必需填写",
|
||||
"ruleValueRequired": "值必需填写",
|
||||
"saveSuccess": "新增成功",
|
||||
"updateSuccess": "修改成功"
|
||||
},
|
||||
"search": {
|
||||
"group": "分组",
|
||||
"title": "标题",
|
||||
"configName": "配置名称",
|
||||
"placeholderGroup": "请输入分组",
|
||||
"placeholderTitle": "请输入标题",
|
||||
"placeholderConfigName": "请输入配置名称"
|
||||
},
|
||||
"table": {
|
||||
"group": "分组",
|
||||
"title": "标题",
|
||||
"titleEn": "标题(英文)",
|
||||
"configName": "配置名称",
|
||||
"value": "值",
|
||||
"valueEn": "值(英文)"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,71 @@
|
||||
{
|
||||
"name": "名称",
|
||||
"form": {
|
||||
"dialogTitleAdd": "新增色子奖池配置",
|
||||
"dialogTitleEdit": "编辑色子奖池配置",
|
||||
"placeholderName": "请输入名称",
|
||||
"placeholderRemark": "请输入备注",
|
||||
"poolType": "奖池类型",
|
||||
"placeholderPoolType": "请选择奖池类型",
|
||||
"poolTypeNormal": "正常",
|
||||
"poolTypeKill": "强制杀猪",
|
||||
"poolTypeT1": "T1高倍率",
|
||||
"safetyLine": "安全线",
|
||||
"t1Weight": "T1池权重(%)",
|
||||
"t2Weight": "T2池权重(%)",
|
||||
"t3Weight": "T3池权重(%)",
|
||||
"t4Weight": "T4池权重(%)",
|
||||
"t5Weight": "T5池权重(%)",
|
||||
"weightsSumHint": "五个池权重总和:",
|
||||
"weightsSumUnit": "% / 100%(必须为100%)",
|
||||
"weightsSumUnitCurrent": "% / 100%(须为100%)",
|
||||
"currentPoolTitle": "当前彩金池",
|
||||
"loading": "加载中...",
|
||||
"poolName": "池子名称",
|
||||
"playerProfit": "玩家累计盈利(profit_amount):",
|
||||
"realtime": "实时",
|
||||
"profitCalcHint": "计算方式:每局按“当前中奖金额(含超级大奖 BIGWIN)减去抽奖券费用 100”累加,弹窗打开期间每 2 秒自动刷新",
|
||||
"tierRuleTitle": "抽奖档位规则",
|
||||
"tierRuleContent": "当玩家在当前彩金池的累计盈利 低于安全线 时,按 玩家 的 T*_weight 权重抽取档位;当累计盈利 高于或等于安全线 时,按 当前彩金池 的 T*_weight 权重抽取档位(杀分)。",
|
||||
"killScoreWeights": "杀分权重(type=1 只读)",
|
||||
"killWeightNote": "(杀分权重来自奖池配置 type=1,请在列表中编辑对应记录)",
|
||||
"btnResetProfit": "重置玩家累计盈利",
|
||||
"btnSaveSafetyLine": "保存安全线",
|
||||
"ruleSafetyLineRequired": "请输入安全线",
|
||||
"msgGetPoolFailed": "获取彩金池失败",
|
||||
"msgSaveSuccess": "保存成功",
|
||||
"msgResetProfitSuccess": "玩家累计盈利已重置为 0",
|
||||
"msgResetFailed": "重置失败",
|
||||
"ruleNameRequired": "名称必需填写",
|
||||
"rulePoolTypeRequired": "请选择奖池类型",
|
||||
"ruleT1Required": "T1池权重必需填写",
|
||||
"ruleT2Required": "T2池权重必需填写",
|
||||
"ruleT3Required": "T3池权重必需填写",
|
||||
"ruleT4Required": "T4池权重必需填写",
|
||||
"ruleT5Required": "T5池权重必需填写",
|
||||
"msgWeightsMust100": "五个池权重总和必须为100%",
|
||||
"msgAddSuccess": "新增成功",
|
||||
"msgUpdateSuccess": "修改成功"
|
||||
},
|
||||
"toolbar": {
|
||||
"viewCurrentPool": "查看当前彩金池"
|
||||
},
|
||||
"search": {
|
||||
"poolType": "奖池类型",
|
||||
"placeholderName": "请输入名称",
|
||||
"placeholderPoolType": "请选择奖池类型",
|
||||
"poolTypeNormal": "正常",
|
||||
"poolTypeKill": "强制杀猪",
|
||||
"poolTypeT1": "T1高倍率"
|
||||
},
|
||||
"table": {
|
||||
"name": "名称",
|
||||
"poolType": "奖池类型",
|
||||
"safetyLine": "安全线",
|
||||
"t1PoolWeight": "T1池权重",
|
||||
"t2PoolWeight": "T2池权重",
|
||||
"t3PoolWeight": "T3池权重",
|
||||
"t4PoolWeight": "T4池权重",
|
||||
"t5PoolWeight": "T5池权重"
|
||||
}
|
||||
}
|
||||
74
saiadmin-artd/src/locales/langs/zh/dice/play_record.json
Normal file
74
saiadmin-artd/src/locales/langs/zh/dice/play_record.json
Normal file
@@ -0,0 +1,74 @@
|
||||
{
|
||||
"form": {
|
||||
"dialogTitleAdd": "新增玩家抽奖记录",
|
||||
"dialogTitleEdit": "编辑玩家抽奖记录",
|
||||
"player": "玩家",
|
||||
"placeholderPlayer": "请选择玩家(显示用户名)",
|
||||
"lotteryPoolConfig": "彩金池配置",
|
||||
"placeholderLotteryPool": "请选择彩金池配置",
|
||||
"drawType": "抽奖类型",
|
||||
"paid": "付费",
|
||||
"free": "赠送",
|
||||
"isBigWin": "是否中大奖",
|
||||
"noBigWin": "无",
|
||||
"bigWin": "中大奖",
|
||||
"winCoin": "赢取平台币",
|
||||
"placeholderWinCoin": "= 中大奖 + 摇色子中奖",
|
||||
"superWinCoin": "中大奖平台币",
|
||||
"placeholderSuperWinCoin": "豹子时发放",
|
||||
"rewardWinCoin": "摇色子中奖平台币",
|
||||
"placeholderRewardWinCoin": "摇色子中奖",
|
||||
"direction": "方向",
|
||||
"placeholderDirection": "请选择方向",
|
||||
"clockwise": "顺时针",
|
||||
"anticlockwise": "逆时针",
|
||||
"startIndex": "起始索引",
|
||||
"placeholderStartIndex": "起始索引",
|
||||
"targetIndex": "终点索引",
|
||||
"placeholderTargetIndex": "终点索引",
|
||||
"rollArray": "摇取点数",
|
||||
"rollArrayHint": "固定 5 个数,每个 1~6",
|
||||
"rollNumber": "摇取点数和",
|
||||
"placeholderRollNumber": "5 个色子点数之和(5~30)",
|
||||
"rewardConfig": "奖励配置",
|
||||
"placeholderRewardConfig": "请选择奖励配置(显示前端文本)"
|
||||
},
|
||||
"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": "更新时间"
|
||||
}
|
||||
}
|
||||
@@ -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": "创建时间"
|
||||
}
|
||||
}
|
||||
79
saiadmin-artd/src/locales/langs/zh/dice/player.json
Normal file
79
saiadmin-artd/src/locales/langs/zh/dice/player.json
Normal file
@@ -0,0 +1,79 @@
|
||||
{
|
||||
"name": "名称",
|
||||
"form": {
|
||||
"dialogTitleAdd": "新增大富翁-玩家",
|
||||
"dialogTitleEdit": "编辑大富翁-玩家",
|
||||
"username": "用户名",
|
||||
"placeholderUsername": "请输入用户名",
|
||||
"nickname": "昵称",
|
||||
"placeholderNickname": "请输入昵称",
|
||||
"phone": "手机号",
|
||||
"placeholderPhone": "请输入手机号",
|
||||
"password": "密码",
|
||||
"placeholderPasswordEdit": "编辑留空则不修改",
|
||||
"status": "状态",
|
||||
"adminId": "所属管理员",
|
||||
"placeholderAdmin": "选择后台管理员(可选)",
|
||||
"coin": "平台币",
|
||||
"placeholderCoinAdd": "创建时默认0,不可改",
|
||||
"lotteryPoolConfig": "彩金池配置",
|
||||
"placeholderLotteryPool": "留空则使用下方自定义权重,或选择彩金池",
|
||||
"currentConfig": "当前配置",
|
||||
"configLabelName": "名称",
|
||||
"configLabelType": "类型",
|
||||
"configLabelWeights": "T1~T5 权重",
|
||||
"configLabelRemark": "备注",
|
||||
"t1Weight": "T1池权重(%)",
|
||||
"t2Weight": "T2池权重(%)",
|
||||
"t3Weight": "T3池权重(%)",
|
||||
"t4Weight": "T4池权重(%)",
|
||||
"t5Weight": "T5池权重(%)",
|
||||
"weightsSumHint": "五个池权重总和:",
|
||||
"weightsSumUnit": "% / 100%(必须为100%)",
|
||||
"walletTitle": "玩家钱包操作",
|
||||
"walletPlayer": "玩家",
|
||||
"walletBalance": "钱包余额",
|
||||
"operationType": "操作类型",
|
||||
"typeAdd": "加点",
|
||||
"typeSub": "扣点",
|
||||
"coinChange": "平台币变动",
|
||||
"placeholderCoinChange": "正数,扣点时不能超过余额",
|
||||
"placeholderRemarkOptional": "选填,不填则按类型自动填写",
|
||||
"ruleSelectType": "请选择操作类型",
|
||||
"ruleEnterCoin": "请输入平台币变动",
|
||||
"ruleCoinPositive": "平台币变动必须大于 0",
|
||||
"ruleDeductExceed": "扣点不能超过当前余额",
|
||||
"operateSuccess": "操作成功"
|
||||
},
|
||||
"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": "更新时间"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,36 @@
|
||||
{
|
||||
"form": {
|
||||
"dialogTitleAdd": "新增抽奖券获取记录",
|
||||
"dialogTitleEdit": "编辑抽奖券获取记录",
|
||||
"player": "玩家",
|
||||
"placeholderPlayer": "请选择玩家(显示用户名)",
|
||||
"useCoins": "消耗硬币",
|
||||
"placeholderUseCoins": "请输入消耗硬币",
|
||||
"paidDrawCount": "购买抽奖次数",
|
||||
"placeholderPaidDrawCount": "请输入购买抽奖次数",
|
||||
"freeDrawCount": "赠送抽奖次数",
|
||||
"placeholderFreeDrawCount": "请输入赠送抽奖次数",
|
||||
"totalDrawCount": "总抽奖次数",
|
||||
"placeholderTotalDrawCount": "自动求和",
|
||||
"placeholderRemark": "请输入备注(必填)"
|
||||
},
|
||||
"search": {
|
||||
"player": "玩家",
|
||||
"useCoins": "消耗硬币",
|
||||
"totalDrawCount": "总抽奖次数",
|
||||
"paidDrawCount": "购买抽奖次数",
|
||||
"freeDrawCount": "赠送抽奖次数",
|
||||
"createTime": "创建时间",
|
||||
"byUsername": "按用户名搜索"
|
||||
},
|
||||
"table": {
|
||||
"id": "ID",
|
||||
"playerUsername": "玩家用户名",
|
||||
"useCoins": "消耗硬币",
|
||||
"totalDrawCount": "总抽奖次数",
|
||||
"paidDrawCount": "购买抽奖次数",
|
||||
"freeDrawCount": "赠送抽奖次数",
|
||||
"remark": "备注",
|
||||
"createTime": "创建时间"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,49 @@
|
||||
{
|
||||
"form": {
|
||||
"dialogTitleAdd": "新增玩家钱包流水",
|
||||
"dialogTitleEdit": "编辑玩家钱包流水",
|
||||
"user": "用户",
|
||||
"placeholderUser": "请选择用户(显示用户名)",
|
||||
"type": "类型",
|
||||
"placeholderType": "请选择类型",
|
||||
"typeRecharge": "充值",
|
||||
"typeWithdraw": "提现",
|
||||
"typeBuyTicket": "购买抽奖次数",
|
||||
"typeAdminAdd": "管理员加点",
|
||||
"typeAdminSub": "管理员扣点",
|
||||
"coinChange": "平台币变化",
|
||||
"placeholderCoinChange": "正数增加、负数减少",
|
||||
"walletBefore": "钱包操作前",
|
||||
"placeholderWalletBefore": "选择用户后自动带出当前平台币",
|
||||
"walletAfter": "钱包操作后",
|
||||
"placeholderWalletAfter": "根据平台币变化自动计算",
|
||||
"placeholderRemark": "选填"
|
||||
},
|
||||
"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": "抽奖"
|
||||
}
|
||||
}
|
||||
21
saiadmin-artd/src/locales/langs/zh/dice/reward.json
Normal file
21
saiadmin-artd/src/locales/langs/zh/dice/reward.json
Normal file
@@ -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)"
|
||||
}
|
||||
}
|
||||
23
saiadmin-artd/src/locales/langs/zh/dice/reward_config.json
Normal file
23
saiadmin-artd/src/locales/langs/zh/dice/reward_config.json
Normal file
@@ -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)"
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"toolbar": {
|
||||
"viewDetail": "查看详情"
|
||||
},
|
||||
"table": {
|
||||
"id": "ID",
|
||||
"status": "状态",
|
||||
"paidDraw": "付费抽取",
|
||||
"freeDraw": "免费抽取",
|
||||
"platformProfit": "平台赚取金额",
|
||||
"totalDrawCount": "总抽奖次数",
|
||||
"createdBy": "创建管理员",
|
||||
"createTime": "创建时间",
|
||||
"statusFail": "失败",
|
||||
"statusDone": "完成",
|
||||
"statusTesting": "测试中"
|
||||
}
|
||||
}
|
||||
18
saiadmin-artd/src/locales/langs/zh/safeguard/attachment.json
Normal file
18
saiadmin-artd/src/locales/langs/zh/safeguard/attachment.json
Normal file
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"search": {
|
||||
"username": "用户名",
|
||||
"phone": "手机号",
|
||||
"status": "状态",
|
||||
"placeholderUsername": "请输入用户名",
|
||||
"placeholderPhone": "请输入手机号",
|
||||
"searchSelectPlaceholder": "请选择"
|
||||
},
|
||||
"table": {
|
||||
"preview": "预览",
|
||||
"fileName": "文件名称",
|
||||
"storageMode": "存储模式",
|
||||
"fileType": "文件类型",
|
||||
"fileSize": "文件大小",
|
||||
"uploadTime": "上传时间"
|
||||
}
|
||||
}
|
||||
19
saiadmin-artd/src/locales/langs/zh/safeguard/database.json
Normal file
19
saiadmin-artd/src/locales/langs/zh/safeguard/database.json
Normal file
@@ -0,0 +1,19 @@
|
||||
{
|
||||
"search": {
|
||||
"tableName": "表名称",
|
||||
"placeholderTableName": "请输入数据表名称"
|
||||
},
|
||||
"table": {
|
||||
"tableName": "表名称",
|
||||
"tableComment": "表注释",
|
||||
"tableEngine": "表引擎",
|
||||
"updateTime": "更新时间",
|
||||
"totalRows": "总行数",
|
||||
"fragmentSize": "碎片大小",
|
||||
"dataSize": "数据大小",
|
||||
"collation": "编码",
|
||||
"createTime": "创建时间",
|
||||
"deleteTime": "删除时间",
|
||||
"dataDetail": "数据详情"
|
||||
}
|
||||
}
|
||||
12
saiadmin-artd/src/locales/langs/zh/safeguard/dict.json
Normal file
12
saiadmin-artd/src/locales/langs/zh/safeguard/dict.json
Normal file
@@ -0,0 +1,12 @@
|
||||
{
|
||||
"table": {
|
||||
"select": "选中",
|
||||
"dictName": "字典名称",
|
||||
"dictCode": "字典标识",
|
||||
"dictLabel": "字典标签",
|
||||
"dictValue": "字典键值",
|
||||
"color": "颜色",
|
||||
"sort": "排序",
|
||||
"status": "状态"
|
||||
}
|
||||
}
|
||||
20
saiadmin-artd/src/locales/langs/zh/safeguard/email-log.json
Normal file
20
saiadmin-artd/src/locales/langs/zh/safeguard/email-log.json
Normal file
@@ -0,0 +1,20 @@
|
||||
{
|
||||
"search": {
|
||||
"labelFrom": "发件人",
|
||||
"labelTo": "收件人",
|
||||
"placeholderSendStatus": "请选择发送状态",
|
||||
"placeholderFrom": "请输入发件人",
|
||||
"placeholderTo": "请输入收件人",
|
||||
"operTime": "发送时间"
|
||||
},
|
||||
"table": {
|
||||
"no": "编号",
|
||||
"gateway": "服务Host",
|
||||
"emailFrom": "发件人",
|
||||
"emailTo": "收件人",
|
||||
"emailCode": "验证码",
|
||||
"sendStatus": "发送状态",
|
||||
"emailResponse": "发送结果",
|
||||
"sendTime": "发送时间"
|
||||
}
|
||||
}
|
||||
22
saiadmin-artd/src/locales/langs/zh/safeguard/login-log.json
Normal file
22
saiadmin-artd/src/locales/langs/zh/safeguard/login-log.json
Normal file
@@ -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": "登录时间"
|
||||
}
|
||||
}
|
||||
20
saiadmin-artd/src/locales/langs/zh/safeguard/oper-log.json
Normal file
20
saiadmin-artd/src/locales/langs/zh/safeguard/oper-log.json
Normal file
@@ -0,0 +1,20 @@
|
||||
{
|
||||
"search": {
|
||||
"operator": "操作用户",
|
||||
"router": "路由",
|
||||
"operIp": "操作IP",
|
||||
"operTime": "操作时间",
|
||||
"placeholderOperator": "请输入操作用户",
|
||||
"placeholderOperRouter": "请输入操作路由",
|
||||
"placeholderOperIp": "请输入操作IP"
|
||||
},
|
||||
"table": {
|
||||
"no": "编号",
|
||||
"operator": "操作用户",
|
||||
"serviceName": "业务名称",
|
||||
"router": "路由",
|
||||
"operIp": "操作IP",
|
||||
"operLocation": "操作地点",
|
||||
"operTime": "操作时间"
|
||||
}
|
||||
}
|
||||
15
saiadmin-artd/src/locales/langs/zh/system/config.json
Normal file
15
saiadmin-artd/src/locales/langs/zh/system/config.json
Normal file
@@ -0,0 +1,15 @@
|
||||
{
|
||||
"search": {
|
||||
"group": "分组",
|
||||
"title": "标题",
|
||||
"configName": "配置名称",
|
||||
"placeholderGroup": "请输入分组",
|
||||
"placeholderTitle": "请输入标题",
|
||||
"placeholderConfigName": "请输入配置名称"
|
||||
},
|
||||
"table": {
|
||||
"select": "选中",
|
||||
"configName": "配置名称",
|
||||
"configKey": "配置标识"
|
||||
}
|
||||
}
|
||||
18
saiadmin-artd/src/locales/langs/zh/system/dept.json
Normal file
18
saiadmin-artd/src/locales/langs/zh/system/dept.json
Normal file
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"search": {
|
||||
"deptName": "部门名称",
|
||||
"deptCode": "部门编码",
|
||||
"status": "状态",
|
||||
"placeholderDeptName": "请输入部门名称",
|
||||
"placeholderDeptCode": "请输入部门编码",
|
||||
"searchSelectPlaceholder": "请选择"
|
||||
},
|
||||
"table": {
|
||||
"deptName": "部门名称",
|
||||
"deptCode": "部门编码",
|
||||
"leader": "部门领导",
|
||||
"sort": "排序",
|
||||
"status": "状态",
|
||||
"createTime": "创建时间"
|
||||
}
|
||||
}
|
||||
21
saiadmin-artd/src/locales/langs/zh/system/menu.json
Normal file
21
saiadmin-artd/src/locales/langs/zh/system/menu.json
Normal file
@@ -0,0 +1,21 @@
|
||||
{
|
||||
"search": {
|
||||
"menuName": "菜单名称",
|
||||
"route": "路由",
|
||||
"status": "状态",
|
||||
"placeholderMenuName": "请输入菜单名称",
|
||||
"placeholderMenuRoute": "请输入菜单路由",
|
||||
"searchSelectPlaceholder": "请选择"
|
||||
},
|
||||
"table": {
|
||||
"menuName": "菜单名称",
|
||||
"menuType": "菜单类型",
|
||||
"icon": "图标",
|
||||
"route": "路由",
|
||||
"component": "组件名称",
|
||||
"auth": "权限标识",
|
||||
"sort": "排序",
|
||||
"status": "状态",
|
||||
"createTime": "创建时间"
|
||||
}
|
||||
}
|
||||
17
saiadmin-artd/src/locales/langs/zh/system/post.json
Normal file
17
saiadmin-artd/src/locales/langs/zh/system/post.json
Normal file
@@ -0,0 +1,17 @@
|
||||
{
|
||||
"search": {
|
||||
"postName": "岗位名称",
|
||||
"postCode": "岗位编码",
|
||||
"status": "状态",
|
||||
"placeholderPostName": "请输入岗位名称",
|
||||
"placeholderPostCode": "请输入岗位编码",
|
||||
"searchSelectPlaceholder": "请选择"
|
||||
},
|
||||
"table": {
|
||||
"postName": "岗位名称",
|
||||
"postCode": "岗位编码",
|
||||
"sort": "排序",
|
||||
"status": "状态",
|
||||
"createTime": "创建时间"
|
||||
}
|
||||
}
|
||||
18
saiadmin-artd/src/locales/langs/zh/system/role.json
Normal file
18
saiadmin-artd/src/locales/langs/zh/system/role.json
Normal file
@@ -0,0 +1,18 @@
|
||||
{
|
||||
"search": {
|
||||
"roleName": "角色名称",
|
||||
"roleCode": "角色编码",
|
||||
"status": "状态",
|
||||
"placeholderRoleName": "请输入角色名称",
|
||||
"placeholderRoleCode": "请输入角色编码",
|
||||
"searchSelectPlaceholder": "请选择"
|
||||
},
|
||||
"table": {
|
||||
"roleName": "角色名称",
|
||||
"roleCode": "角色编码",
|
||||
"level": "角色级别",
|
||||
"roleRemark": "角色描述",
|
||||
"status": "状态",
|
||||
"createTime": "创建时间"
|
||||
}
|
||||
}
|
||||
21
saiadmin-artd/src/locales/langs/zh/system/user.json
Normal file
21
saiadmin-artd/src/locales/langs/zh/system/user.json
Normal file
@@ -0,0 +1,21 @@
|
||||
{
|
||||
"search": {
|
||||
"username": "用户名",
|
||||
"phone": "手机号",
|
||||
"status": "状态",
|
||||
"placeholderUsername": "请输入用户名",
|
||||
"placeholderPhone": "请输入手机号",
|
||||
"searchSelectPlaceholder": "请选择"
|
||||
},
|
||||
"table": {
|
||||
"username": "用户名",
|
||||
"phone": "手机号",
|
||||
"dept": "部门",
|
||||
"dashboard": "首页",
|
||||
"loginTime": "上次登录",
|
||||
"agentId": "代理ID",
|
||||
"status": "状态",
|
||||
"createTime": "创建时间",
|
||||
"updateTime": "更新时间"
|
||||
}
|
||||
}
|
||||
20
saiadmin-artd/src/locales/langs/zh/tool/code.json
Normal file
20
saiadmin-artd/src/locales/langs/zh/tool/code.json
Normal file
@@ -0,0 +1,20 @@
|
||||
{
|
||||
"search": {
|
||||
"tableName": "表名称",
|
||||
"placeholderTableName": "请输入数据表名称",
|
||||
"placeholderDataSource": "请输入数据源名称"
|
||||
},
|
||||
"table": {
|
||||
"tableName": "表名称",
|
||||
"tableDesc": "表描述",
|
||||
"tableComment": "表注释",
|
||||
"engine": "引擎",
|
||||
"collation": "编码",
|
||||
"template": "应用类型",
|
||||
"namespace": "应用名称",
|
||||
"stub": "模板类型",
|
||||
"tplCategory": "生成类型",
|
||||
"updateTime": "更新时间",
|
||||
"createTime": "创建时间"
|
||||
}
|
||||
}
|
||||
21
saiadmin-artd/src/locales/langs/zh/tool/crontab.json
Normal file
21
saiadmin-artd/src/locales/langs/zh/tool/crontab.json
Normal file
@@ -0,0 +1,21 @@
|
||||
{
|
||||
"search": {
|
||||
"taskName": "任务名称",
|
||||
"taskType": "任务类型",
|
||||
"status": "状态",
|
||||
"placeholderTaskName": "请输入任务名称",
|
||||
"searchSelectPlaceholder": "请选择"
|
||||
},
|
||||
"table": {
|
||||
"no": "编号",
|
||||
"taskName": "任务名称",
|
||||
"taskType": "任务类型",
|
||||
"rule": "定时规则",
|
||||
"target": "调用目标",
|
||||
"status": "状态",
|
||||
"updateDate": "更新日期",
|
||||
"executeTime": "执行时间",
|
||||
"parameter": "任务参数",
|
||||
"executeStatus": "执行状态"
|
||||
}
|
||||
}
|
||||
84
saiadmin-artd/src/locales/pageLocaleLoader.ts
Normal file
84
saiadmin-artd/src/locales/pageLocaleLoader.ts
Normal file
@@ -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<string, unknown> }
|
||||
|
||||
const enModules = import.meta.glob<PageLocaleModule>('./langs/en/**/*.json')
|
||||
const zhModules = import.meta.glob<PageLocaleModule>('./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<void> {
|
||||
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<string, unknown>
|
||||
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
|
||||
}
|
||||
@@ -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
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<div class="art-card h-105 p-4 box-border mb-5 max-sm:mb-4">
|
||||
<div class="art-card-header">
|
||||
<div class="title">
|
||||
<h4>月度玩家充值汇总</h4>
|
||||
<h4>{{ $t('console.activeUser.title') }}</h4>
|
||||
</div>
|
||||
</div>
|
||||
<ArtBarChart
|
||||
|
||||
@@ -2,10 +2,10 @@
|
||||
<ElRow :gutter="20" class="flex">
|
||||
<ElCol :sm="12" :md="6" :lg="6">
|
||||
<div class="art-card relative flex flex-col justify-center h-35 px-5 mb-5 max-sm:mb-4">
|
||||
<span class="text-g-700 text-sm">玩家注册</span>
|
||||
<span class="text-g-700 text-sm">{{ $t('console.card.playerRegister') }}</span>
|
||||
<ArtCountTo class="text-[26px] font-medium mt-2" :target="statData.player_count" :duration="1300" />
|
||||
<div class="flex-c mt-1">
|
||||
<span class="text-xs text-g-600">较上周</span>
|
||||
<span class="text-xs text-g-600">{{ $t('console.card.vsLastWeek') }}</span>
|
||||
<span
|
||||
class="ml-1 text-xs font-semibold"
|
||||
:class="changeClass(statData.player_count_change)"
|
||||
@@ -22,7 +22,7 @@
|
||||
</ElCol>
|
||||
<ElCol :sm="12" :md="6" :lg="6">
|
||||
<div class="art-card relative flex flex-col justify-center h-35 px-5 mb-5 max-sm:mb-4">
|
||||
<span class="text-g-700 text-sm">玩家充值</span>
|
||||
<span class="text-g-700 text-sm">{{ $t('console.card.playerCharge') }}</span>
|
||||
<ArtCountTo
|
||||
class="text-[26px] font-medium mt-2"
|
||||
:target="statData.charge_amount"
|
||||
@@ -30,7 +30,7 @@
|
||||
:decimals="2"
|
||||
/>
|
||||
<div class="flex-c mt-1">
|
||||
<span class="text-xs text-g-600">较上周</span>
|
||||
<span class="text-xs text-g-600">{{ $t('console.card.vsLastWeek') }}</span>
|
||||
<span
|
||||
class="ml-1 text-xs font-semibold"
|
||||
:class="changeClass(statData.charge_amount_change)"
|
||||
@@ -47,7 +47,7 @@
|
||||
</ElCol>
|
||||
<ElCol :sm="12" :md="6" :lg="6">
|
||||
<div class="art-card relative flex flex-col justify-center h-35 px-5 mb-5 max-sm:mb-4">
|
||||
<span class="text-g-700 text-sm">玩家提现</span>
|
||||
<span class="text-g-700 text-sm">{{ $t('console.card.playerWithdraw') }}</span>
|
||||
<ArtCountTo
|
||||
class="text-[26px] font-medium mt-2"
|
||||
:target="statData.withdraw_amount"
|
||||
@@ -55,7 +55,7 @@
|
||||
:decimals="2"
|
||||
/>
|
||||
<div class="flex-c mt-1">
|
||||
<span class="text-xs text-g-600">较上周</span>
|
||||
<span class="text-xs text-g-600">{{ $t('console.card.vsLastWeek') }}</span>
|
||||
<span
|
||||
class="ml-1 text-xs font-semibold"
|
||||
:class="changeClass(statData.withdraw_amount_change)"
|
||||
@@ -72,14 +72,14 @@
|
||||
</ElCol>
|
||||
<ElCol :sm="12" :md="6" :lg="6">
|
||||
<div class="art-card relative flex flex-col justify-center h-35 px-5 mb-5 max-sm:mb-4">
|
||||
<span class="text-g-700 text-sm">玩家游玩次数</span>
|
||||
<span class="text-g-700 text-sm">{{ $t('console.card.playerPlayCount') }}</span>
|
||||
<ArtCountTo
|
||||
class="text-[26px] font-medium mt-2"
|
||||
:target="statData.play_count"
|
||||
:duration="1300"
|
||||
/>
|
||||
<div class="flex-c mt-1">
|
||||
<span class="text-xs text-g-600">较上周</span>
|
||||
<span class="text-xs text-g-600">{{ $t('console.card.vsLastWeek') }}</span>
|
||||
<span
|
||||
class="ml-1 text-xs font-semibold"
|
||||
:class="changeClass(statData.play_count_change)"
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
<div class="art-card h-128 p-5 mb-5 max-sm:mb-4">
|
||||
<div class="art-card-header">
|
||||
<div class="title">
|
||||
<h4>动态</h4>
|
||||
<p>新增<span class="text-success">+6</span></p>
|
||||
<h4>{{ $t('console.dynamic.title') }}</h4>
|
||||
<p>{{ $t('console.dynamic.newCount') }}<span class="text-success">+6</span></p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
<div class="art-card p-5 overflow-hidden mb-5 max-sm:mb-4">
|
||||
<div class="art-card-header mb-4">
|
||||
<div class="title">
|
||||
<h4>新增玩家</h4>
|
||||
<p class="text-g-600 text-sm mt-1">最新50条新增玩家记录</p>
|
||||
<h4>{{ $t('console.newPlayer.title') }}</h4>
|
||||
<p class="text-g-600 text-sm mt-1">{{ $t('console.newPlayer.subtitle') }}</p>
|
||||
</div>
|
||||
</div>
|
||||
<ArtTable
|
||||
@@ -16,13 +16,13 @@
|
||||
:header-cell-style="{ background: 'transparent' }"
|
||||
>
|
||||
<template #default>
|
||||
<ElTableColumn label="玩家" prop="name" min-width="120" />
|
||||
<ElTableColumn label="余额" prop="coin" min-width="120" align="right">
|
||||
<ElTableColumn :label="$t('console.newPlayer.player')" prop="name" min-width="120" align="center" />
|
||||
<ElTableColumn :label="$t('console.newPlayer.balance')" prop="coin" min-width="120" align="center">
|
||||
<template #default="scope">
|
||||
{{ formatCoin(scope.row.coin) }}
|
||||
</template>
|
||||
</ElTableColumn>
|
||||
<ElTableColumn label="抽奖券" prop="total_ticket_count" min-width="100" align="right" />
|
||||
<ElTableColumn :label="$t('console.newPlayer.ticket')" prop="total_ticket_count" min-width="100" align="center" />
|
||||
</template>
|
||||
</ArtTable>
|
||||
</div>
|
||||
|
||||
@@ -2,13 +2,13 @@
|
||||
<div class="art-card p-5 h-128 overflow-hidden mb-5 max-sm:mb-4">
|
||||
<div class="art-card-header">
|
||||
<div class="title">
|
||||
<h4>新用户</h4>
|
||||
<p>这个月增长<span class="text-success">+20%</span></p>
|
||||
<h4>{{ $t('console.newUser.title') }}</h4>
|
||||
<p>{{ $t('console.newUser.growth') }}<span class="text-success">+20%</span></p>
|
||||
</div>
|
||||
<ElRadioGroup v-model="radio2">
|
||||
<ElRadioButton value="本月" label="本月"></ElRadioButton>
|
||||
<ElRadioButton value="上月" label="上月"></ElRadioButton>
|
||||
<ElRadioButton value="今年" label="今年"></ElRadioButton>
|
||||
<ElRadioButton label="thisMonth">{{ $t('console.newUser.thisMonth') }}</ElRadioButton>
|
||||
<ElRadioButton label="lastMonth">{{ $t('console.newUser.lastMonth') }}</ElRadioButton>
|
||||
<ElRadioButton label="thisYear">{{ $t('console.newUser.thisYear') }}</ElRadioButton>
|
||||
</ElRadioGroup>
|
||||
</div>
|
||||
<ArtTable
|
||||
@@ -21,7 +21,7 @@
|
||||
:header-cell-style="{ background: 'transparent' }"
|
||||
>
|
||||
<template #default>
|
||||
<ElTableColumn label="头像" prop="avatar" width="150px">
|
||||
<ElTableColumn :label="$t('console.newUser.avatar')" prop="avatar" width="150px">
|
||||
<template #default="scope">
|
||||
<div style="display: flex; align-items: center">
|
||||
<img class="size-9 rounded-lg" :src="scope.row.avatar" alt="avatar" />
|
||||
@@ -29,15 +29,15 @@
|
||||
</div>
|
||||
</template>
|
||||
</ElTableColumn>
|
||||
<ElTableColumn label="地区" prop="province" />
|
||||
<ElTableColumn label="性别" prop="avatar">
|
||||
<ElTableColumn :label="$t('console.newUser.region')" prop="province" />
|
||||
<ElTableColumn :label="$t('console.newUser.gender')" prop="avatar">
|
||||
<template #default="scope">
|
||||
<div style="display: flex; align-items: center">
|
||||
<span style="margin-left: 10px">{{ scope.row.sex === 1 ? '男' : '女' }}</span>
|
||||
<span style="margin-left: 10px">{{ scope.row.sex === 1 ? $t('console.newUser.male') : $t('console.newUser.female') }}</span>
|
||||
</div>
|
||||
</template>
|
||||
</ElTableColumn>
|
||||
<ElTableColumn label="进度" width="240">
|
||||
<ElTableColumn :label="$t('console.newUser.progress')" width="240">
|
||||
<template #default="scope">
|
||||
<ElProgress
|
||||
:percentage="scope.row.pro"
|
||||
@@ -73,7 +73,7 @@
|
||||
|
||||
const ANIMATION_DELAY = 100
|
||||
|
||||
const radio2 = ref('本月')
|
||||
const radio2 = ref('thisMonth')
|
||||
|
||||
/**
|
||||
* 新用户表格数据
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<div class="art-card h-105 p-5 mb-5 max-sm:mb-4">
|
||||
<div class="art-card-header">
|
||||
<div class="title">
|
||||
<h4>近期玩家充值统计</h4>
|
||||
<h4>{{ $t('console.salesOverview.title') }}</h4>
|
||||
</div>
|
||||
</div>
|
||||
<ArtLineChart
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
<div class="art-card h-128 p-5 mb-5 max-sm:mb-4">
|
||||
<div class="art-card-header">
|
||||
<div class="title">
|
||||
<h4>代办事项</h4>
|
||||
<p>待处理<span class="text-danger">3</span></p>
|
||||
<h4>{{ $t('console.todo.title') }}</h4>
|
||||
<p>{{ $t('console.todo.pending') }}<span class="text-danger">3</span></p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
<div class="art-card p-5 overflow-hidden mb-5 max-sm:mb-4">
|
||||
<div class="art-card-header mb-4">
|
||||
<div class="title">
|
||||
<h4>玩家充值记录</h4>
|
||||
<p class="text-g-600 text-sm mt-1">最新50条充值记录</p>
|
||||
<h4>{{ $t('console.walletRecord.title') }}</h4>
|
||||
<p class="text-g-600 text-sm mt-1">{{ $t('console.walletRecord.subtitle') }}</p>
|
||||
</div>
|
||||
</div>
|
||||
<ArtTable
|
||||
@@ -16,13 +16,13 @@
|
||||
:header-cell-style="{ background: 'transparent' }"
|
||||
>
|
||||
<template #default>
|
||||
<ElTableColumn label="玩家" prop="player_name" min-width="120" />
|
||||
<ElTableColumn label="充值金额" prop="coin" min-width="120" align="right">
|
||||
<ElTableColumn :label="$t('console.walletRecord.player')" prop="player_name" min-width="120" align="center" />
|
||||
<ElTableColumn :label="$t('console.walletRecord.chargeAmount')" prop="coin" min-width="120" align="center">
|
||||
<template #default="scope">
|
||||
{{ formatCoin(scope.row.coin) }}
|
||||
</template>
|
||||
</ElTableColumn>
|
||||
<ElTableColumn label="充值时间" prop="create_time" min-width="170" />
|
||||
<ElTableColumn :label="$t('console.walletRecord.chargeTime')" prop="create_time" min-width="170" align="center" />
|
||||
</template>
|
||||
</ArtTable>
|
||||
</div>
|
||||
|
||||
@@ -109,15 +109,15 @@
|
||||
apiFn: api.list,
|
||||
columnsFactory: () => [
|
||||
// { type: 'selection' },
|
||||
{ prop: 'group', label: '分组', minWidth: 140, align: 'center' },
|
||||
{ prop: 'title', label: '标题', minWidth: 160, align: 'center' },
|
||||
{ prop: 'title_en', label: '标题(英文)', minWidth: 160, align: 'center' },
|
||||
{ prop: 'name', label: '配置名称', align: 'center' },
|
||||
{ prop: 'value', label: '值', minWidth: 240, align: 'center' },
|
||||
{ prop: 'value_en', label: '值(英文)', minWidth: 240, align: 'center' },
|
||||
{ prop: 'group', label: 'page.table.group', minWidth: 140, align: 'center' },
|
||||
{ prop: 'title', label: 'page.table.title', minWidth: 160, align: 'center' },
|
||||
{ prop: 'title_en', label: 'page.table.titleEn', minWidth: 160, align: 'center' },
|
||||
{ prop: 'name', label: 'page.table.configName', align: 'center' },
|
||||
{ prop: 'value', label: 'page.table.value', minWidth: 240, align: 'center' },
|
||||
{ prop: 'value_en', label: 'page.table.valueEn', minWidth: 240, align: 'center' },
|
||||
{
|
||||
prop: 'operation',
|
||||
label: '操作',
|
||||
label: 'table.actions.operation',
|
||||
width: 60,
|
||||
align: 'center',
|
||||
fixed: 'right',
|
||||
|
||||
@@ -1,43 +1,43 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
v-model="visible"
|
||||
:title="dialogType === 'add' ? '新增摇色子配置' : '编辑摇色子配置'"
|
||||
:title="dialogType === 'add' ? $t('page.form.dialogTitleAdd') : $t('page.form.dialogTitleEdit')"
|
||||
width="600px"
|
||||
align-center
|
||||
:close-on-click-modal="false"
|
||||
@close="handleClose"
|
||||
>
|
||||
<el-form ref="formRef" :model="formData" :rules="rules" label-width="120px">
|
||||
<el-form-item label="分组" prop="group">
|
||||
<el-form-item :label="$t('page.form.group')" prop="group">
|
||||
<el-input
|
||||
v-model="formData.group"
|
||||
placeholder="请输入分组"
|
||||
:placeholder="$t('page.form.placeholderGroup')"
|
||||
:disabled="dialogType === 'edit'"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="标题" prop="title">
|
||||
<el-input v-model="formData.title" placeholder="请输入标题(中文)" />
|
||||
<el-form-item :label="$t('page.form.title')" prop="title">
|
||||
<el-input v-model="formData.title" :placeholder="$t('page.form.placeholderTitleZh')" />
|
||||
</el-form-item>
|
||||
<el-form-item label="标题(英文)" prop="title_en">
|
||||
<el-input v-model="formData.title_en" placeholder="请输入标题(英文)" />
|
||||
<el-form-item :label="$t('page.form.titleEn')" prop="title_en">
|
||||
<el-input v-model="formData.title_en" :placeholder="$t('page.form.placeholderTitleEn')" />
|
||||
</el-form-item>
|
||||
<el-form-item label="配置名称" prop="name">
|
||||
<el-form-item :label="$t('page.form.configName')" prop="name">
|
||||
<el-input
|
||||
v-model="formData.name"
|
||||
placeholder="请输入配置名称"
|
||||
:placeholder="$t('page.form.placeholderConfigName')"
|
||||
:disabled="dialogType === 'edit'"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="值" prop="value">
|
||||
<el-input v-model="formData.value" type="textarea" :rows="5" placeholder="请输入值(中文)" />
|
||||
<el-form-item :label="$t('page.form.value')" prop="value">
|
||||
<el-input v-model="formData.value" type="textarea" :rows="5" :placeholder="$t('page.form.placeholderValueZh')" />
|
||||
</el-form-item>
|
||||
<el-form-item label="值(英文)" prop="value_en">
|
||||
<el-input v-model="formData.value_en" type="textarea" :rows="5" placeholder="请输入值(英文)" />
|
||||
<el-form-item :label="$t('page.form.valueEn')" prop="value_en">
|
||||
<el-input v-model="formData.value_en" type="textarea" :rows="5" :placeholder="$t('page.form.placeholderValueEn')" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<template #footer>
|
||||
<el-button @click="handleClose">取消</el-button>
|
||||
<el-button type="primary" @click="handleSubmit">提交</el-button>
|
||||
<el-button @click="handleClose">{{ $t('common.cancel') }}</el-button>
|
||||
<el-button type="primary" @click="handleSubmit">{{ $t('table.form.submit') }}</el-button>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
@@ -46,6 +46,9 @@
|
||||
import api from '../../../api/config/index'
|
||||
import { ElMessage } from 'element-plus'
|
||||
import type { FormInstance, FormRules } from 'element-plus'
|
||||
import { useI18n } from 'vue-i18n'
|
||||
|
||||
const { t } = useI18n()
|
||||
|
||||
interface Props {
|
||||
modelValue: boolean
|
||||
@@ -79,13 +82,13 @@
|
||||
/**
|
||||
* 表单验证规则
|
||||
*/
|
||||
const rules = reactive<FormRules>({
|
||||
group: [{ required: true, message: '分组必需填写', trigger: 'blur' }],
|
||||
title: [{ required: true, message: '标题必需填写', trigger: 'blur' }],
|
||||
title_en: [{ max: 255, message: '英文标题长度需小于 255 字符', trigger: 'blur' }],
|
||||
name: [{ required: true, message: '配置名称必需填写', trigger: 'blur' }],
|
||||
value: [{ required: true, message: '值必需填写', trigger: 'blur' }]
|
||||
})
|
||||
const rules = computed<FormRules>(() => ({
|
||||
group: [{ required: true, message: t('page.form.ruleGroupRequired'), trigger: 'blur' }],
|
||||
title: [{ required: true, message: t('page.form.ruleTitleRequired'), trigger: 'blur' }],
|
||||
title_en: [{ max: 255, message: t('page.form.ruleTitleEnMax'), trigger: 'blur' }],
|
||||
name: [{ required: true, message: t('page.form.ruleConfigNameRequired'), trigger: 'blur' }],
|
||||
value: [{ required: true, message: t('page.form.ruleValueRequired'), trigger: 'blur' }]
|
||||
}))
|
||||
|
||||
/**
|
||||
* 初始数据
|
||||
@@ -160,10 +163,10 @@
|
||||
await formRef.value.validate()
|
||||
if (props.dialogType === 'add') {
|
||||
await api.save(formData)
|
||||
ElMessage.success('新增成功')
|
||||
ElMessage.success(t('page.form.saveSuccess'))
|
||||
} else {
|
||||
await api.update(formData)
|
||||
ElMessage.success('修改成功')
|
||||
ElMessage.success(t('page.form.updateSuccess'))
|
||||
}
|
||||
emit('success')
|
||||
handleClose()
|
||||
|
||||
@@ -9,18 +9,18 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="分组" prop="group">
|
||||
<el-input v-model="formData.group" placeholder="请输入分组" clearable />
|
||||
<el-form-item :label="$t('page.search.group')" prop="group">
|
||||
<el-input v-model="formData.group" :placeholder="$t('page.search.placeholderGroup')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="标题" prop="title">
|
||||
<el-input v-model="formData.title" placeholder="请输入标题" clearable />
|
||||
<el-form-item :label="$t('page.search.title')" prop="title">
|
||||
<el-input v-model="formData.title" :placeholder="$t('page.search.placeholderTitle')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="配置名称" prop="name">
|
||||
<el-input v-model="formData.name" placeholder="请输入配置名称" clearable />
|
||||
<el-form-item :label="$t('page.search.configName')" prop="name">
|
||||
<el-input v-model="formData.name" :placeholder="$t('page.search.placeholderConfigName')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</sa-search-bar>
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
type="primary"
|
||||
@click="showCurrentPoolDialog"
|
||||
>
|
||||
查看当前彩金池
|
||||
{{ $t('page.toolbar.viewCurrentPool') }}
|
||||
</ElButton>
|
||||
</template>
|
||||
</ArtTableHeader>
|
||||
@@ -61,12 +61,14 @@
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { useI18n } from 'vue-i18n'
|
||||
import { useTable } from '@/hooks/core/useTable'
|
||||
import { useSaiAdmin } from '@/composables/useSaiAdmin'
|
||||
import api from '../../api/lottery_pool_config/index'
|
||||
import TableSearch from './modules/table-search.vue'
|
||||
import EditDialog from './modules/edit-dialog.vue'
|
||||
import CurrentPoolDialog from './modules/current-pool-dialog.vue'
|
||||
const { t } = useI18n()
|
||||
|
||||
// 搜索表单
|
||||
const searchForm = ref({
|
||||
@@ -82,7 +84,7 @@
|
||||
|
||||
// 奖池类型展示:0=正常 1=强制杀猪 2=T1高倍率
|
||||
const typeFormatter = (row: Record<string, unknown>) =>
|
||||
row.type === 0 ? '正常' : row.type === 1 ? '强制杀猪' : row.type === 2 ? 'T1高倍率' : '-'
|
||||
row.type === 0 ? t('page.search.poolTypeNormal') : row.type === 1 ? t('page.search.poolTypeKill') : row.type === 2 ? t('page.search.poolTypeT1') : '-'
|
||||
|
||||
// 权重列带 %
|
||||
const weightFormatter = (prop: string) => (row: Record<string, unknown>) => {
|
||||
@@ -108,47 +110,47 @@
|
||||
core: {
|
||||
apiFn: api.list,
|
||||
columnsFactory: () => [
|
||||
{ prop: 'name', label: '名称', align: 'center' },
|
||||
{ prop: 'type', label: '奖池类型', width: 100, align: 'center', formatter: typeFormatter },
|
||||
{ prop: 'safety_line', label: '安全线', align: 'center' },
|
||||
{ prop: 'name', label: 'page.table.name', align: 'center' },
|
||||
{ prop: 'type', label: 'page.table.poolType', width: 100, align: 'center', formatter: typeFormatter },
|
||||
{ prop: 'safety_line', label: 'page.table.safetyLine', align: 'center' },
|
||||
{
|
||||
prop: 't1_weight',
|
||||
label: 'T1池权重',
|
||||
label: 'page.table.t1PoolWeight',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
formatter: weightFormatter('t1_weight')
|
||||
},
|
||||
{
|
||||
prop: 't2_weight',
|
||||
label: 'T2池权重',
|
||||
label: 'page.table.t2PoolWeight',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
formatter: weightFormatter('t2_weight')
|
||||
},
|
||||
{
|
||||
prop: 't3_weight',
|
||||
label: 'T3池权重',
|
||||
label: 'page.table.t3PoolWeight',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
formatter: weightFormatter('t3_weight')
|
||||
},
|
||||
{
|
||||
prop: 't4_weight',
|
||||
label: 'T4池权重',
|
||||
label: 'page.table.t4PoolWeight',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
formatter: weightFormatter('t4_weight')
|
||||
},
|
||||
{
|
||||
prop: 't5_weight',
|
||||
label: 'T5池权重',
|
||||
label: 'page.table.t5PoolWeight',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
formatter: weightFormatter('t5_weight')
|
||||
},
|
||||
{
|
||||
prop: 'operation',
|
||||
label: '操作',
|
||||
label: 'table.actions.operation',
|
||||
width: 60,
|
||||
align: 'center',
|
||||
fixed: 'right',
|
||||
|
||||
@@ -1,41 +1,40 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
v-model="visible"
|
||||
title="当前彩金池"
|
||||
:title="$t('page.form.currentPoolTitle')"
|
||||
width="560px"
|
||||
align-center
|
||||
:close-on-click-modal="false"
|
||||
@close="handleClose"
|
||||
>
|
||||
<div v-if="loading && !pool" class="flex justify-center py-8">加载中...</div>
|
||||
<div v-if="loading && !pool" class="flex justify-center py-8">{{ $t('page.form.loading') }}</div>
|
||||
<template v-else-if="pool">
|
||||
<div class="pool-info mb-4">
|
||||
<div class="flex items-center gap-2 mb-3">
|
||||
<span class="text-gray-500">池子名称:</span>
|
||||
<span class="text-gray-500">{{ $t('page.form.poolName') }}:</span>
|
||||
<span>{{ pool.name }}</span>
|
||||
</div>
|
||||
<div class="profit-row mb-3">
|
||||
<div class="flex items-center gap-2">
|
||||
<span class="text-gray-500">玩家累计盈利(profit_amount):</span>
|
||||
<span class="text-gray-500">{{ $t('page.form.playerProfit') }}</span>
|
||||
<span class="font-mono text-lg" :class="profitAmountClass">{{
|
||||
displayProfitAmount
|
||||
}}</span>
|
||||
<span class="realtime-badge">实时</span>
|
||||
<span class="realtime-badge">{{ $t('page.form.realtime') }}</span>
|
||||
</div>
|
||||
<div class="profit-calc-hint">
|
||||
计算方式:每局按“当前中奖金额(含超级大奖 BIGWIN)减去抽奖券费用 100”累加,弹窗打开期间每 2 秒自动刷新
|
||||
{{ $t('page.form.profitCalcHint') }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="tip-block">
|
||||
<div class="tip-title">抽奖档位规则</div>
|
||||
<div class="tip-title">{{ $t('page.form.tierRuleTitle') }}</div>
|
||||
<div class="tip-content">
|
||||
当玩家在当前彩金池的累计盈利 <strong>低于安全线</strong> 时,按<strong>玩家</strong>的 T*_weight 权重抽取档位;
|
||||
当累计盈利 <strong>高于或等于安全线</strong> 时,按<strong>当前彩金池</strong>的 T*_weight 权重抽取档位(杀分)。
|
||||
{{ $t('page.form.tierRuleContent') }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<el-form ref="formRef" :model="formData" :rules="rules" label-width="120px">
|
||||
<el-form-item label="安全线" prop="safety_line">
|
||||
<el-form-item :label="$t('page.form.safetyLine')" prop="safety_line">
|
||||
<el-input-number
|
||||
v-model="formData.safety_line"
|
||||
:min="0"
|
||||
@@ -43,38 +42,28 @@
|
||||
style="width: 100%"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="T1池权重(%)" prop="t1_weight">
|
||||
<el-slider v-model="formData.t1_weight" :min="0" :max="100" :step="1" show-input />
|
||||
</el-form-item>
|
||||
<el-form-item label="T2池权重(%)" prop="t2_weight">
|
||||
<el-slider v-model="formData.t2_weight" :min="0" :max="100" :step="1" show-input />
|
||||
</el-form-item>
|
||||
<el-form-item label="T3池权重(%)" prop="t3_weight">
|
||||
<el-slider v-model="formData.t3_weight" :min="0" :max="100" :step="1" show-input />
|
||||
</el-form-item>
|
||||
<el-form-item label="T4池权重(%)" prop="t4_weight">
|
||||
<el-slider v-model="formData.t4_weight" :min="0" :max="100" :step="1" show-input />
|
||||
</el-form-item>
|
||||
<el-form-item label="T5池权重(%)" prop="t5_weight">
|
||||
<el-slider v-model="formData.t5_weight" :min="0" :max="100" :step="1" show-input />
|
||||
<el-form-item :label="$t('page.form.killScoreWeights')">
|
||||
<div class="text-gray-500 text-sm">
|
||||
T1: {{ pool.t1_weight }}% / T2: {{ pool.t2_weight }}% / T3: {{ pool.t3_weight }}% / T4: {{ pool.t4_weight }}% / T5: {{ pool.t5_weight }}%
|
||||
</div>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<div class="text-gray-500 text-sm">
|
||||
五个池权重总和:<span :class="weightsSum !== 100 ? 'text-red-500' : ''">{{
|
||||
{{ $t('page.form.weightsSumHint') }}<span :class="weightsSum !== 100 ? 'text-red-500' : ''">{{
|
||||
weightsSum
|
||||
}}</span
|
||||
>% / 100%(须为100%)
|
||||
>{{ $t('page.form.weightsSumUnitCurrent') }} {{ $t('page.form.killWeightNote') }}
|
||||
</div>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</template>
|
||||
<template #footer>
|
||||
<el-button @click="handleClose">关闭</el-button>
|
||||
<el-button @click="handleClose">{{ $t('form.close') }}</el-button>
|
||||
<el-button :loading="resetting" :disabled="!pool" @click="handleResetProfit">
|
||||
重置玩家累计盈利
|
||||
{{ $t('page.form.btnResetProfit') }}
|
||||
</el-button>
|
||||
<el-button type="primary" :loading="saving" :disabled="!pool" @click="handleSubmit">
|
||||
保存权重与安全线
|
||||
{{ $t('page.form.btnSaveSafetyLine') }}
|
||||
</el-button>
|
||||
</template>
|
||||
</el-dialog>
|
||||
@@ -84,6 +73,9 @@
|
||||
import api from '../../../api/lottery_pool_config/index'
|
||||
import { ElMessage } from 'element-plus'
|
||||
import type { FormInstance, FormRules } from 'element-plus'
|
||||
import { useI18n } from 'vue-i18n'
|
||||
|
||||
const { t } = useI18n()
|
||||
|
||||
interface PoolData {
|
||||
id: number
|
||||
@@ -112,31 +104,18 @@
|
||||
const formRef = ref<FormInstance>()
|
||||
|
||||
const formData = reactive({
|
||||
safety_line: 0,
|
||||
t1_weight: 0,
|
||||
t2_weight: 0,
|
||||
t3_weight: 0,
|
||||
t4_weight: 0,
|
||||
t5_weight: 0
|
||||
safety_line: 0
|
||||
})
|
||||
|
||||
const rules: FormRules = {
|
||||
safety_line: [{ required: true, message: '请输入安全线', trigger: 'blur' }],
|
||||
t1_weight: [{ required: true, message: '请输入T1权重', trigger: 'blur' }],
|
||||
t2_weight: [{ required: true, message: '请输入T2权重', trigger: 'blur' }],
|
||||
t3_weight: [{ required: true, message: '请输入T3权重', trigger: 'blur' }],
|
||||
t4_weight: [{ required: true, message: '请输入T4权重', trigger: 'blur' }],
|
||||
t5_weight: [{ required: true, message: '请输入T5权重', trigger: 'blur' }]
|
||||
}
|
||||
const rules = computed<FormRules>(() => ({
|
||||
safety_line: [{ required: true, message: t('page.form.ruleSafetyLineRequired'), trigger: 'blur' }]
|
||||
}))
|
||||
|
||||
const weightsSum = computed(
|
||||
() =>
|
||||
formData.t1_weight +
|
||||
formData.t2_weight +
|
||||
formData.t3_weight +
|
||||
formData.t4_weight +
|
||||
formData.t5_weight
|
||||
)
|
||||
const weightsSum = computed(() => {
|
||||
const p = pool.value
|
||||
if (!p) return 0
|
||||
return (p.t1_weight ?? 0) + (p.t2_weight ?? 0) + (p.t3_weight ?? 0) + (p.t4_weight ?? 0) + (p.t5_weight ?? 0)
|
||||
})
|
||||
|
||||
const displayProfitAmount = computed(() => {
|
||||
const v = pool.value?.profit_amount
|
||||
@@ -164,14 +143,9 @@
|
||||
if (data && typeof data === 'object') {
|
||||
pool.value = data
|
||||
formData.safety_line = data.safety_line ?? 0
|
||||
formData.t1_weight = data.t1_weight ?? 0
|
||||
formData.t2_weight = data.t2_weight ?? 0
|
||||
formData.t3_weight = data.t3_weight ?? 0
|
||||
formData.t4_weight = data.t4_weight ?? 0
|
||||
formData.t5_weight = data.t5_weight ?? 0
|
||||
}
|
||||
} catch (e: any) {
|
||||
ElMessage.error(e?.message ?? '获取彩金池失败')
|
||||
ElMessage.error(e?.message ?? t('page.form.msgGetPoolFailed'))
|
||||
} finally {
|
||||
loading.value = false
|
||||
}
|
||||
@@ -201,23 +175,14 @@
|
||||
}
|
||||
|
||||
async function handleSubmit() {
|
||||
if (!formRef.value || !pool.value) return
|
||||
if (weightsSum.value !== 100) {
|
||||
ElMessage.warning('T1~T5 权重合计须为 100%')
|
||||
return
|
||||
}
|
||||
if (!pool.value) return
|
||||
try {
|
||||
await formRef.value.validate()
|
||||
await formRef.value?.validate?.()
|
||||
saving.value = true
|
||||
await api.updateCurrentPool({
|
||||
safety_line: formData.safety_line,
|
||||
t1_weight: formData.t1_weight,
|
||||
t2_weight: formData.t2_weight,
|
||||
t3_weight: formData.t3_weight,
|
||||
t4_weight: formData.t4_weight,
|
||||
t5_weight: formData.t5_weight
|
||||
safety_line: formData.safety_line
|
||||
})
|
||||
ElMessage.success('保存成功')
|
||||
ElMessage.success(t('page.form.msgSaveSuccess'))
|
||||
await loadPool()
|
||||
emit('success')
|
||||
} catch (e: any) {
|
||||
@@ -232,11 +197,11 @@
|
||||
try {
|
||||
resetting.value = true
|
||||
await api.resetProfitAmount()
|
||||
ElMessage.success('玩家累计盈利已重置为 0')
|
||||
ElMessage.success(t('page.form.msgResetProfitSuccess'))
|
||||
await loadPool()
|
||||
emit('success')
|
||||
} catch (e: any) {
|
||||
ElMessage.error(e?.message ?? '重置失败')
|
||||
ElMessage.error(e?.message ?? t('page.form.msgResetFailed'))
|
||||
} finally {
|
||||
resetting.value = false
|
||||
}
|
||||
|
||||
@@ -1,44 +1,44 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
v-model="visible"
|
||||
:title="dialogType === 'add' ? '新增色子奖池配置' : '编辑色子奖池配置'"
|
||||
:title="dialogType === 'add' ? $t('page.form.dialogTitleAdd') : $t('page.form.dialogTitleEdit')"
|
||||
width="600px"
|
||||
align-center
|
||||
:close-on-click-modal="false"
|
||||
@close="handleClose"
|
||||
>
|
||||
<el-form ref="formRef" :model="formData" :rules="rules" label-width="120px">
|
||||
<el-form-item label="名称" prop="name">
|
||||
<el-form-item :label="$t('form.labelName')" prop="name">
|
||||
<el-input
|
||||
v-model="formData.name"
|
||||
placeholder="请输入名称"
|
||||
:placeholder="$t('page.form.placeholderName')"
|
||||
:disabled="dialogType === 'edit'"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<el-form-item :label="$t('form.labelRemark')" prop="remark">
|
||||
<el-input
|
||||
v-model="formData.remark"
|
||||
type="textarea"
|
||||
:rows="3"
|
||||
placeholder="请输入备注"
|
||||
:placeholder="$t('page.form.placeholderRemark')"
|
||||
maxlength="500"
|
||||
show-word-limit
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="奖池类型" prop="type">
|
||||
<el-form-item :label="$t('page.form.poolType')" prop="type">
|
||||
<el-select
|
||||
v-model="formData.type"
|
||||
placeholder="请选择奖池类型"
|
||||
:placeholder="$t('page.form.placeholderPoolType')"
|
||||
clearable
|
||||
style="width: 100%"
|
||||
:disabled="dialogType === 'edit'"
|
||||
>
|
||||
<el-option label="正常" :value="0" />
|
||||
<el-option label="强制杀猪" :value="1" />
|
||||
<el-option label="T1高倍率" :value="2" />
|
||||
<el-option :label="$t('page.form.poolTypeNormal')" :value="0" />
|
||||
<el-option :label="$t('page.form.poolTypeKill')" :value="1" />
|
||||
<el-option :label="$t('page.form.poolTypeT1')" :value="2" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="安全线" prop="safety_line">
|
||||
<el-form-item :label="$t('page.form.safetyLine')" prop="safety_line">
|
||||
<el-input-number
|
||||
v-model="formData.safety_line"
|
||||
:min="0"
|
||||
@@ -46,33 +46,33 @@
|
||||
style="width: 100%"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="T1池权重(%)" prop="t1_weight">
|
||||
<el-form-item :label="$t('page.form.t1Weight')" prop="t1_weight">
|
||||
<el-slider v-model="formData.t1_weight" :min="0" :max="100" :step="0.01" show-input />
|
||||
</el-form-item>
|
||||
<el-form-item label="T2池权重(%)" prop="t2_weight">
|
||||
<el-form-item :label="$t('page.form.t2Weight')" prop="t2_weight">
|
||||
<el-slider v-model="formData.t2_weight" :min="0" :max="100" :step="0.01" show-input />
|
||||
</el-form-item>
|
||||
<el-form-item label="T3池权重(%)" prop="t3_weight">
|
||||
<el-form-item :label="$t('page.form.t3Weight')" prop="t3_weight">
|
||||
<el-slider v-model="formData.t3_weight" :min="0" :max="100" :step="0.01" show-input />
|
||||
</el-form-item>
|
||||
<el-form-item label="T4池权重(%)" prop="t4_weight">
|
||||
<el-form-item :label="$t('page.form.t4Weight')" prop="t4_weight">
|
||||
<el-slider v-model="formData.t4_weight" :min="0" :max="100" :step="0.01" show-input />
|
||||
</el-form-item>
|
||||
<el-form-item label="T5池权重(%)" prop="t5_weight">
|
||||
<el-form-item :label="$t('page.form.t5Weight')" prop="t5_weight">
|
||||
<el-slider v-model="formData.t5_weight" :min="0" :max="100" :step="0.01" show-input />
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<div class="text-gray-500 text-sm">
|
||||
五个池权重总和:<span :class="Math.abs(weightsSum - 100) > 0.01 ? 'text-red-500' : ''">{{
|
||||
{{ $t('page.form.weightsSumHint') }}<span :class="Math.abs(weightsSum - 100) > 0.01 ? 'text-red-500' : ''">{{
|
||||
weightsSum
|
||||
}}</span
|
||||
>% / 100%(必须为100%)
|
||||
>{{ $t('page.form.weightsSumUnit') }}
|
||||
</div>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<template #footer>
|
||||
<el-button @click="handleClose">取消</el-button>
|
||||
<el-button type="primary" @click="handleSubmit">提交</el-button>
|
||||
<el-button @click="handleClose">{{ $t('common.cancel') }}</el-button>
|
||||
<el-button type="primary" @click="handleSubmit">{{ $t('table.form.submit') }}</el-button>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
@@ -81,6 +81,9 @@
|
||||
import api from '../../../api/lottery_pool_config/index'
|
||||
import { ElMessage } from 'element-plus'
|
||||
import type { FormInstance, FormRules } from 'element-plus'
|
||||
import { useI18n } from 'vue-i18n'
|
||||
|
||||
const { t } = useI18n()
|
||||
|
||||
interface Props {
|
||||
modelValue: boolean
|
||||
@@ -122,15 +125,15 @@
|
||||
/**
|
||||
* 表单验证规则
|
||||
*/
|
||||
const rules = reactive<FormRules>({
|
||||
name: [{ required: true, message: '名称必需填写', trigger: 'blur' }],
|
||||
type: [{ required: true, message: '请选择奖池类型', trigger: 'change' }],
|
||||
t1_weight: [{ required: true, message: 'T1池权重必需填写', trigger: 'blur' }],
|
||||
t2_weight: [{ required: true, message: 'T2池权重必需填写', trigger: 'blur' }],
|
||||
t3_weight: [{ required: true, message: 'T3池权重必需填写', trigger: 'blur' }],
|
||||
t4_weight: [{ required: true, message: 'T4池权重必需填写', trigger: 'blur' }],
|
||||
t5_weight: [{ required: true, message: 'T5池权重必需填写', trigger: 'blur' }]
|
||||
})
|
||||
const rules = computed<FormRules>(() => ({
|
||||
name: [{ required: true, message: t('page.form.ruleNameRequired'), trigger: 'blur' }],
|
||||
type: [{ required: true, message: t('page.form.rulePoolTypeRequired'), trigger: 'change' }],
|
||||
t1_weight: [{ required: true, message: t('page.form.ruleT1Required'), trigger: 'blur' }],
|
||||
t2_weight: [{ required: true, message: t('page.form.ruleT2Required'), trigger: 'blur' }],
|
||||
t3_weight: [{ required: true, message: t('page.form.ruleT3Required'), trigger: 'blur' }],
|
||||
t4_weight: [{ required: true, message: t('page.form.ruleT4Required'), trigger: 'blur' }],
|
||||
t5_weight: [{ required: true, message: t('page.form.ruleT5Required'), trigger: 'blur' }]
|
||||
}))
|
||||
|
||||
/**
|
||||
* 初始数据(权重为数字便于输入与校验)
|
||||
@@ -221,15 +224,15 @@
|
||||
try {
|
||||
await formRef.value.validate()
|
||||
if (Math.abs(weightsSum.value - 100) > 0.01) {
|
||||
ElMessage.warning('五个池权重总和必须为100%')
|
||||
ElMessage.warning(t('page.form.msgWeightsMust100'))
|
||||
return
|
||||
}
|
||||
if (props.dialogType === 'add') {
|
||||
await api.save(formData)
|
||||
ElMessage.success('新增成功')
|
||||
ElMessage.success(t('page.form.msgAddSuccess'))
|
||||
} else {
|
||||
await api.update(formData)
|
||||
ElMessage.success('修改成功')
|
||||
ElMessage.success(t('page.form.msgUpdateSuccess'))
|
||||
}
|
||||
emit('success')
|
||||
handleClose()
|
||||
|
||||
@@ -9,16 +9,16 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="名称" prop="name">
|
||||
<el-input v-model="formData.name" placeholder="请输入名称" clearable />
|
||||
<el-form-item :label="$t('page.name')" prop="name">
|
||||
<el-input v-model="formData.name" :placeholder="$t('page.search.placeholderName')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="奖池类型" prop="type">
|
||||
<el-form-item :label="$t('page.search.poolType')" prop="type">
|
||||
<el-select
|
||||
v-model="formData.type"
|
||||
:options="typeOptions"
|
||||
placeholder="请选择奖池类型"
|
||||
:placeholder="$t('page.search.placeholderPoolType')"
|
||||
clearable
|
||||
/>
|
||||
</el-form-item>
|
||||
@@ -27,6 +27,7 @@
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { useI18n } from 'vue-i18n'
|
||||
interface Props {
|
||||
modelValue: Record<string, any>
|
||||
}
|
||||
@@ -40,11 +41,12 @@
|
||||
// 展开/收起
|
||||
const isExpanded = ref<boolean>(false)
|
||||
|
||||
const typeOptions = [
|
||||
{ name: '0', value: '正常' },
|
||||
{ name: '1', value: '强制杀猪' },
|
||||
{ name: '2', value: 'T1高倍率' }
|
||||
]
|
||||
const { t } = useI18n()
|
||||
const typeOptions = computed(() => [
|
||||
{ name: '0', value: t('page.search.poolTypeNormal') },
|
||||
{ name: '1', value: t('page.search.poolTypeKill') },
|
||||
{ name: '2', value: t('page.search.poolTypeT1') }
|
||||
])
|
||||
// 表单数据双向绑定
|
||||
const searchBarRef = ref()
|
||||
const formData = computed({
|
||||
|
||||
@@ -53,19 +53,19 @@
|
||||
<!-- 抽奖类型 tag -->
|
||||
<template #lottery_type="{ row }">
|
||||
<ElTag size="small" :type="row.lottery_type === 0 ? 'warning' : 'success'">
|
||||
{{ row.lottery_type === 0 ? '付费' : row.lottery_type === 1 ? '赠送' : '-' }}
|
||||
{{ row.lottery_type === 0 ? t('page.search.paid') : row.lottery_type === 1 ? t('page.search.free') : '-' }}
|
||||
</ElTag>
|
||||
</template>
|
||||
<!-- 是否中大奖 tag -->
|
||||
<template #is_win="{ row }">
|
||||
<ElTag size="small" :type="row.is_win === 1 ? 'success' : 'info'">
|
||||
{{ row.is_win === 0 ? '无' : row.is_win === 1 ? '中大奖' : '-' }}
|
||||
{{ row.is_win === 0 ? t('page.search.noBigWin') : row.is_win === 1 ? t('page.search.bigWin') : '-' }}
|
||||
</ElTag>
|
||||
</template>
|
||||
<!-- 方向 tag -->
|
||||
<template #direction="{ row }">
|
||||
<ElTag size="small" :type="row.direction === 0 ? 'primary' : 'warning'">
|
||||
{{ row.direction === 0 ? '顺时针' : row.direction === 1 ? '逆时针' : '-' }}
|
||||
{{ row.direction === 0 ? t('page.search.clockwise') : row.direction === 1 ? t('page.search.anticlockwise') : '-' }}
|
||||
</ElTag>
|
||||
</template>
|
||||
<!-- 摇取点数 tag -->
|
||||
@@ -103,11 +103,13 @@
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { useI18n } from 'vue-i18n'
|
||||
import { useTable } from '@/hooks/core/useTable'
|
||||
import { useSaiAdmin } from '@/composables/useSaiAdmin'
|
||||
import api from '../../api/play_record/index'
|
||||
import TableSearch from './modules/table-search.vue'
|
||||
import EditDialog from './modules/edit-dialog.vue'
|
||||
const { t } = useI18n()
|
||||
|
||||
// 搜索表单
|
||||
const searchForm = ref<Record<string, unknown>>({
|
||||
@@ -171,36 +173,36 @@
|
||||
apiFn: api.list,
|
||||
columnsFactory: () => [
|
||||
// { type: 'selection' },
|
||||
{ prop: 'id', label: 'ID', width: 80 },
|
||||
{ prop: 'id', label: 'page.table.id', width: 80 },
|
||||
{
|
||||
prop: 'player_id',
|
||||
label: '玩家',
|
||||
label: 'page.table.player',
|
||||
formatter: (row: Record<string, any>) => usernameFormatter(row)
|
||||
},
|
||||
{
|
||||
prop: 'lottery_config_id',
|
||||
label: '彩金池配置',
|
||||
label: 'page.table.lotteryPoolConfig',
|
||||
width: 120,
|
||||
useSlot: true
|
||||
},
|
||||
{ prop: 'lottery_type', label: '抽奖类型', width: 100, useSlot: true },
|
||||
{ prop: 'is_win', label: '是否中大奖', width: 100, useSlot: true },
|
||||
{ prop: 'win_coin', label: '赢取平台币', width: 110 },
|
||||
{ prop: 'super_win_coin', label: '中大奖平台币', width: 120 },
|
||||
{ prop: 'reward_win_coin', label: '摇色子中奖平台币', width: 140 },
|
||||
{ prop: 'direction', label: '方向', width: 90, useSlot: true },
|
||||
{ prop: 'start_index', label: '起始索引', width: 90 },
|
||||
{ prop: 'target_index', label: '终点索引', width: 90 },
|
||||
{ prop: 'roll_array', label: '摇取点数', width: 140, useSlot: true },
|
||||
{ prop: 'roll_number', label: '摇取点数和', width: 110, sortable: true },
|
||||
{ prop: 'lottery_type', label: 'page.table.drawType', width: 100, useSlot: true },
|
||||
{ prop: 'is_win', label: 'page.table.isBigWin', width: 100, useSlot: true },
|
||||
{ prop: 'win_coin', label: 'page.table.winCoin', width: 110 },
|
||||
{ prop: 'super_win_coin', label: 'page.table.superWinCoin', width: 120 },
|
||||
{ prop: 'reward_win_coin', label: 'page.table.rewardWinCoin', width: 140 },
|
||||
{ prop: 'direction', label: 'page.table.direction', width: 90, useSlot: true },
|
||||
{ prop: 'start_index', label: 'page.table.startIndex', width: 90 },
|
||||
{ prop: 'target_index', label: 'page.table.targetIndex', width: 90 },
|
||||
{ prop: 'roll_array', label: 'page.table.rollArray', width: 140, useSlot: true },
|
||||
{ prop: 'roll_number', label: 'page.table.rollNumber', width: 110, sortable: true },
|
||||
{
|
||||
prop: 'reward_config_id',
|
||||
label: '奖励配置',
|
||||
label: 'page.table.rewardConfig',
|
||||
formatter: (row: Record<string, any>) => rewardTierFormatter(row)
|
||||
},
|
||||
{ prop: 'create_time', label: '创建时间', width: 170 },
|
||||
{ prop: 'update_time', label: '修改时间', width: 170 },
|
||||
{ prop: 'operation', label: '操作', width: 100, fixed: 'right', useSlot: true }
|
||||
{ prop: 'create_time', label: 'page.table.createTime', width: 170 },
|
||||
{ prop: 'update_time', label: 'page.table.updateTime', width: 170 },
|
||||
{ prop: 'operation', label: 'table.actions.operation', width: 100, fixed: 'right', useSlot: true }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
v-model="visible"
|
||||
:title="dialogType === 'add' ? '新增玩家抽奖记录' : '编辑玩家抽奖记录'"
|
||||
:title="dialogType === 'add' ? $t('page.form.dialogTitleAdd') : $t('page.form.dialogTitleEdit')"
|
||||
width="600px"
|
||||
align-center
|
||||
:close-on-click-modal="false"
|
||||
@close="handleClose"
|
||||
>
|
||||
<el-form ref="formRef" :model="formData" :rules="rules" label-width="120px">
|
||||
<el-form-item label="玩家" prop="player_id">
|
||||
<el-form-item :label="$t('page.form.player')" prop="player_id">
|
||||
<el-select
|
||||
v-model="formData.player_id"
|
||||
placeholder="请选择玩家(显示用户名)"
|
||||
:placeholder="$t('page.form.placeholderPlayer')"
|
||||
clearable
|
||||
filterable
|
||||
style="width: 100%"
|
||||
@@ -25,10 +25,10 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="彩金池配置" prop="lottery_config_id">
|
||||
<el-form-item :label="$t('page.form.lotteryPoolConfig')" prop="lottery_config_id">
|
||||
<el-select
|
||||
v-model="formData.lottery_config_id"
|
||||
placeholder="请选择彩金池配置"
|
||||
:placeholder="$t('page.form.placeholderLotteryPool')"
|
||||
clearable
|
||||
filterable
|
||||
style="width: 100%"
|
||||
@@ -42,90 +42,90 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="抽奖类型" prop="lottery_type">
|
||||
<el-form-item :label="$t('page.form.drawType')" prop="lottery_type">
|
||||
<el-select
|
||||
v-model="formData.lottery_type"
|
||||
placeholder="请选择"
|
||||
:placeholder="$t('form.placeholderSelect')"
|
||||
clearable
|
||||
style="width: 100%"
|
||||
:disabled="dialogType === 'edit'"
|
||||
>
|
||||
<el-option label="付费" :value="0" />
|
||||
<el-option label="赠送" :value="1" />
|
||||
<el-option :label="$t('page.form.paid')" :value="0" />
|
||||
<el-option :label="$t('page.form.free')" :value="1" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="是否中大奖" prop="is_win">
|
||||
<el-form-item :label="$t('page.form.isBigWin')" prop="is_win">
|
||||
<el-select
|
||||
v-model="formData.is_win"
|
||||
placeholder="请选择"
|
||||
:placeholder="$t('form.placeholderSelect')"
|
||||
clearable
|
||||
style="width: 100%"
|
||||
:disabled="dialogType === 'edit'"
|
||||
>
|
||||
<el-option label="无" :value="0" />
|
||||
<el-option label="中大奖" :value="1" />
|
||||
<el-option :label="$t('page.form.noBigWin')" :value="0" />
|
||||
<el-option :label="$t('page.form.bigWin')" :value="1" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="赢取平台币" prop="win_coin">
|
||||
<el-form-item :label="$t('page.form.winCoin')" prop="win_coin">
|
||||
<el-input-number
|
||||
v-model="formData.win_coin"
|
||||
placeholder="= 中大奖 + 摇色子中奖"
|
||||
:placeholder="$t('page.form.placeholderWinCoin')"
|
||||
:precision="2"
|
||||
style="width: 100%"
|
||||
:disabled="dialogType === 'edit'"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="中大奖平台币" prop="super_win_coin">
|
||||
<el-form-item :label="$t('page.form.superWinCoin')" prop="super_win_coin">
|
||||
<el-input-number
|
||||
v-model="formData.super_win_coin"
|
||||
placeholder="豹子时发放"
|
||||
:placeholder="$t('page.form.placeholderSuperWinCoin')"
|
||||
:precision="2"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
:disabled="dialogType === 'edit'"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="摇色子中奖平台币" prop="reward_win_coin">
|
||||
<el-form-item :label="$t('page.form.rewardWinCoin')" prop="reward_win_coin">
|
||||
<el-input-number
|
||||
v-model="formData.reward_win_coin"
|
||||
placeholder="摇色子中奖"
|
||||
:placeholder="$t('page.form.placeholderRewardWinCoin')"
|
||||
:precision="2"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
:disabled="dialogType === 'edit'"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="方向" prop="direction">
|
||||
<el-form-item :label="$t('page.form.direction')" prop="direction">
|
||||
<el-select
|
||||
v-model="formData.direction"
|
||||
placeholder="请选择方向"
|
||||
:placeholder="$t('page.form.placeholderDirection')"
|
||||
clearable
|
||||
style="width: 100%"
|
||||
:disabled="dialogType === 'edit'"
|
||||
>
|
||||
<el-option label="顺时针" :value="0" />
|
||||
<el-option label="逆时针" :value="1" />
|
||||
<el-option :label="$t('page.form.clockwise')" :value="0" />
|
||||
<el-option :label="$t('page.form.anticlockwise')" :value="1" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="起始索引" prop="start_index">
|
||||
<el-form-item :label="$t('page.form.startIndex')" prop="start_index">
|
||||
<el-input-number
|
||||
v-model="formData.start_index"
|
||||
placeholder="起始索引"
|
||||
:placeholder="$t('page.form.placeholderStartIndex')"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
:disabled="dialogType === 'edit'"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="终点索引" prop="target_index">
|
||||
<el-form-item :label="$t('page.form.targetIndex')" prop="target_index">
|
||||
<el-input-number
|
||||
v-model="formData.target_index"
|
||||
placeholder="终点索引"
|
||||
:placeholder="$t('page.form.placeholderTargetIndex')"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
:disabled="dialogType === 'edit'"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="摇取点数" prop="rollArrayItems">
|
||||
<el-form-item :label="$t('page.form.rollArray')" prop="rollArrayItems">
|
||||
<div class="roll-array-wrap">
|
||||
<el-input-number
|
||||
v-for="(_, i) in 5"
|
||||
@@ -140,12 +140,12 @@
|
||||
:disabled="dialogType === 'edit'"
|
||||
/>
|
||||
</div>
|
||||
<div class="roll-array-hint">固定 5 个数,每个 1~6</div>
|
||||
<div class="roll-array-hint">{{ $t('page.form.rollArrayHint') }}</div>
|
||||
</el-form-item>
|
||||
<el-form-item label="摇取点数和" prop="roll_number">
|
||||
<el-form-item :label="$t('page.form.rollNumber')" prop="roll_number">
|
||||
<el-input-number
|
||||
v-model="formData.roll_number"
|
||||
placeholder="5 个色子点数之和(5~30)"
|
||||
:placeholder="$t('page.form.placeholderRollNumber')"
|
||||
:min="5"
|
||||
:max="30"
|
||||
:precision="0"
|
||||
@@ -153,10 +153,10 @@
|
||||
:disabled="dialogType === 'edit'"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="奖励配置" prop="reward_config_id">
|
||||
<el-form-item :label="$t('page.form.rewardConfig')" prop="reward_config_id">
|
||||
<el-select
|
||||
v-model="formData.reward_config_id"
|
||||
placeholder="请选择奖励配置(显示前端文本)"
|
||||
:placeholder="$t('page.form.placeholderRewardConfig')"
|
||||
clearable
|
||||
filterable
|
||||
style="width: 100%"
|
||||
@@ -176,8 +176,8 @@
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<template #footer>
|
||||
<el-button @click="handleClose">{{ dialogType === 'edit' ? '关闭' : '取消' }}</el-button>
|
||||
<el-button v-if="dialogType === 'add'" type="primary" @click="handleSubmit">提交</el-button>
|
||||
<el-button @click="handleClose">{{ dialogType === 'edit' ? $t('form.close') : $t('common.cancel') }}</el-button>
|
||||
<el-button v-if="dialogType === 'add'" type="primary" @click="handleSubmit">{{ $t('table.form.submit') }}</el-button>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
@@ -9,53 +9,53 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="玩家" prop="username">
|
||||
<el-input v-model="formData.username" placeholder="用户名模糊" clearable />
|
||||
<el-form-item :label="$t('page.search.player')" prop="username">
|
||||
<el-input v-model="formData.username" :placeholder="$t('page.search.usernameFuzzy')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="彩金池配置" prop="lottery_config_name">
|
||||
<el-input v-model="formData.lottery_config_name" placeholder="名称模糊" clearable />
|
||||
<el-form-item :label="$t('page.search.lotteryPoolConfig')" prop="lottery_config_name">
|
||||
<el-input v-model="formData.lottery_config_name" :placeholder="$t('page.search.nameFuzzy')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="抽奖类型" prop="lottery_type">
|
||||
<el-select v-model="formData.lottery_type" placeholder="全部" clearable style="width: 100%">
|
||||
<el-option label="付费" :value="0" />
|
||||
<el-option label="赠送" :value="1" />
|
||||
<el-form-item :label="$t('page.search.drawType')" prop="lottery_type">
|
||||
<el-select v-model="formData.lottery_type" :placeholder="$t('table.searchBar.all')" clearable style="width: 100%">
|
||||
<el-option :label="$t('page.search.paid')" :value="0" />
|
||||
<el-option :label="$t('page.search.free')" :value="1" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="是否中大奖" prop="is_win">
|
||||
<el-select v-model="formData.is_win" placeholder="全部" clearable style="width: 100%">
|
||||
<el-option label="无" :value="0" />
|
||||
<el-option label="中大奖" :value="1" />
|
||||
<el-form-item :label="$t('page.search.isBigWin')" prop="is_win">
|
||||
<el-select v-model="formData.is_win" :placeholder="$t('table.searchBar.all')" clearable style="width: 100%">
|
||||
<el-option :label="$t('page.search.noBigWin')" :value="0" />
|
||||
<el-option :label="$t('page.search.bigWin')" :value="1" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="方向" prop="direction">
|
||||
<el-select v-model="formData.direction" placeholder="全部" clearable style="width: 100%">
|
||||
<el-option label="顺时针" :value="0" />
|
||||
<el-option label="逆时针" :value="1" />
|
||||
<el-form-item :label="$t('page.search.direction')" prop="direction">
|
||||
<el-select v-model="formData.direction" :placeholder="$t('table.searchBar.all')" clearable style="width: 100%">
|
||||
<el-option :label="$t('page.search.clockwise')" :value="0" />
|
||||
<el-option :label="$t('page.search.anticlockwise')" :value="1" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="赢取平台币" prop="win_coin_min">
|
||||
<el-form-item :label="$t('page.search.winCoin')" prop="win_coin_min">
|
||||
<div class="range-wrap">
|
||||
<el-input-number
|
||||
v-model="formData.win_coin_min"
|
||||
placeholder="最小"
|
||||
:placeholder="$t('table.searchBar.min')"
|
||||
:precision="2"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
/>
|
||||
<span class="range-sep">至</span>
|
||||
<span class="range-sep">{{ $t('table.searchBar.rangeSeparator') }}</span>
|
||||
<el-input-number
|
||||
v-model="formData.win_coin_max"
|
||||
placeholder="最大"
|
||||
:placeholder="$t('table.searchBar.max')"
|
||||
:precision="2"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
@@ -64,21 +64,21 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="摇取点数和" prop="roll_number_min">
|
||||
<el-form-item :label="$t('page.search.rollNumber')" prop="roll_number_min">
|
||||
<div class="range-wrap">
|
||||
<el-input-number
|
||||
v-model="formData.roll_number_min"
|
||||
placeholder="最小"
|
||||
:placeholder="$t('table.searchBar.min')"
|
||||
:min="5"
|
||||
:max="30"
|
||||
:precision="0"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
/>
|
||||
<span class="range-sep">至</span>
|
||||
<span class="range-sep">{{ $t('table.searchBar.rangeSeparator') }}</span>
|
||||
<el-input-number
|
||||
v-model="formData.roll_number_max"
|
||||
placeholder="最大"
|
||||
:placeholder="$t('table.searchBar.max')"
|
||||
:min="5"
|
||||
:max="30"
|
||||
:precision="0"
|
||||
@@ -89,13 +89,13 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="奖励配置" prop="reward_ui_text">
|
||||
<el-input v-model="formData.reward_ui_text" placeholder="前端显示文本模糊" clearable />
|
||||
<el-form-item :label="$t('page.search.rewardConfig')" prop="reward_ui_text">
|
||||
<el-input v-model="formData.reward_ui_text" :placeholder="$t('page.search.uiTextFuzzy')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="中奖名(档位)" prop="reward_tier">
|
||||
<el-select v-model="formData.reward_tier" placeholder="全部" clearable style="width: 100%">
|
||||
<el-form-item :label="$t('page.search.rewardTier')" prop="reward_tier">
|
||||
<el-select v-model="formData.reward_tier" :placeholder="$t('table.searchBar.all')" clearable style="width: 100%">
|
||||
<el-option label="T1" value="T1" />
|
||||
<el-option label="T2" value="T2" />
|
||||
<el-option label="T3" value="T3" />
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
<ArtTableHeader v-model:columns="columnChecks" :loading="loading" @refresh="refreshData">
|
||||
<template #left>
|
||||
<span v-if="totalWinCoin !== null" class="table-summary-inline">
|
||||
平台总盈利:<strong>{{ totalWinCoin }}</strong>
|
||||
{{ $t('page.toolbar.platformTotalProfit') }}:<strong>{{ totalWinCoin }}</strong>
|
||||
</span>
|
||||
<ElSpace wrap class="table-toolbar-buttons">
|
||||
<ElButton
|
||||
@@ -20,7 +20,7 @@
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:delete-bin-5-line" />
|
||||
</template>
|
||||
删除
|
||||
{{ $t('table.actions.delete') }}
|
||||
</ElButton>
|
||||
<ElButton
|
||||
v-permission="'dice:play_record_test:index:destroy'"
|
||||
@@ -32,7 +32,7 @@
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:delete-bin-2-line" />
|
||||
</template>
|
||||
一键删除所有数据
|
||||
{{ $t('page.toolbar.clearAllData') }}
|
||||
</ElButton>
|
||||
</ElSpace>
|
||||
</template>
|
||||
@@ -58,19 +58,19 @@
|
||||
<!-- 抽奖类型 -->
|
||||
<template #lottery_type="{ row }">
|
||||
<ElTag size="small" :type="row.lottery_type === 0 ? 'warning' : 'success'">
|
||||
{{ row.lottery_type === 0 ? '付费' : row.lottery_type === 1 ? '赠送' : '-' }}
|
||||
{{ row.lottery_type === 0 ? t('page.search.paid') : row.lottery_type === 1 ? t('page.search.free') : '-' }}
|
||||
</ElTag>
|
||||
</template>
|
||||
<!-- 是否中大奖 -->
|
||||
<template #is_win="{ row }">
|
||||
<ElTag size="small" :type="row.is_win === 1 ? 'success' : 'info'">
|
||||
{{ row.is_win === 0 ? '无' : row.is_win === 1 ? '中大奖' : '-' }}
|
||||
{{ row.is_win === 0 ? t('page.search.noBigWin') : row.is_win === 1 ? t('page.search.bigWin') : '-' }}
|
||||
</ElTag>
|
||||
</template>
|
||||
<!-- 方向 -->
|
||||
<template #direction="{ row }">
|
||||
<ElTag size="small" :type="row.direction === 0 ? 'primary' : 'warning'">
|
||||
{{ row.direction === 0 ? '顺时针' : row.direction === 1 ? '逆时针' : '-' }}
|
||||
{{ row.direction === 0 ? t('page.search.clockwise') : row.direction === 1 ? t('page.search.anticlockwise') : '-' }}
|
||||
</ElTag>
|
||||
</template>
|
||||
<!-- 摇取点数 -->
|
||||
@@ -86,7 +86,7 @@
|
||||
<!-- 状态 -->
|
||||
<template #status="{ row }">
|
||||
<ElTag size="small" :type="row.status === 1 ? 'success' : 'info'">
|
||||
{{ row.status === 1 ? '成功' : '失败' }}
|
||||
{{ row.status === 1 ? t('table.searchBar.success') : t('table.searchBar.failure') }}
|
||||
</ElTag>
|
||||
</template>
|
||||
<!-- 操作列 -->
|
||||
@@ -118,12 +118,14 @@
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { useI18n } from 'vue-i18n'
|
||||
import { useTable } from '@/hooks/core/useTable'
|
||||
import { useSaiAdmin } from '@/composables/useSaiAdmin'
|
||||
import api from '../../api/play_record_test/index'
|
||||
import TableSearch from './modules/table-search.vue'
|
||||
import EditDialog from './modules/edit-dialog.vue'
|
||||
import { ElMessage, ElMessageBox } from 'element-plus'
|
||||
const { t } = useI18n()
|
||||
|
||||
// 搜索表单(与 play_record 对齐:方向、赢取平台币范围、是否中大奖、中奖档位、点数和)
|
||||
const searchForm = ref<Record<string, unknown>>({
|
||||
@@ -205,22 +207,22 @@
|
||||
apiFn: listApi,
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'id', label: 'ID', width: 80 },
|
||||
{ prop: 'lottery_config_id', label: '彩金池配置', width: 120, useSlot: true },
|
||||
{ prop: 'lottery_type', label: '抽奖类型', width: 100, useSlot: true },
|
||||
{ prop: 'is_win', label: '是否中大奖', width: 100, useSlot: true },
|
||||
{ prop: 'win_coin', label: '赢取平台币', width: 110 },
|
||||
{ prop: 'super_win_coin', label: '中大奖平台币', width: 120 },
|
||||
{ prop: 'reward_win_coin', label: '摇色子中奖平台币', width: 140 },
|
||||
{ prop: 'direction', label: '方向', width: 90, useSlot: true },
|
||||
{ prop: 'start_index', label: '起始索引', width: 90 },
|
||||
{ prop: 'target_index', label: '终点索引', width: 90 },
|
||||
{ prop: 'roll_array', label: '摇取点数', width: 140, useSlot: true },
|
||||
{ prop: 'roll_number', label: '摇取点数和', width: 110, sortable: true },
|
||||
{ prop: 'reward_config_id', label: '奖励档位', width: 100, useSlot: true },
|
||||
{ prop: 'status', label: '状态', width: 80, useSlot: true },
|
||||
{ prop: 'create_time', label: '创建时间', width: 170 },
|
||||
{ prop: 'operation', label: '操作', width: 100, fixed: 'right', useSlot: true }
|
||||
{ prop: 'id', label: 'page.table.id', width: 80 },
|
||||
{ prop: 'lottery_config_id', label: 'page.table.lotteryPoolConfig', width: 120, useSlot: true },
|
||||
{ prop: 'lottery_type', label: 'page.table.drawType', width: 100, useSlot: true },
|
||||
{ prop: 'is_win', label: 'page.table.isBigWin', width: 100, useSlot: true },
|
||||
{ prop: 'win_coin', label: 'page.table.winCoin', width: 110 },
|
||||
{ prop: 'super_win_coin', label: 'page.table.superWinCoin', width: 120 },
|
||||
{ prop: 'reward_win_coin', label: 'page.table.rewardWinCoin', width: 140 },
|
||||
{ prop: 'direction', label: 'page.table.direction', width: 90, useSlot: true },
|
||||
{ prop: 'start_index', label: 'page.table.startIndex', width: 90 },
|
||||
{ prop: 'target_index', label: 'page.table.targetIndex', width: 90 },
|
||||
{ prop: 'roll_array', label: 'page.table.rollArray', width: 140, useSlot: true },
|
||||
{ prop: 'roll_number', label: 'page.table.rollNumber', width: 110, sortable: true },
|
||||
{ prop: 'reward_config_id', label: 'page.table.rewardConfig', width: 100, useSlot: true },
|
||||
{ prop: 'status', label: 'page.table.status', width: 80, useSlot: true },
|
||||
{ prop: 'create_time', label: 'page.table.createTime', width: 170 },
|
||||
{ prop: 'operation', label: 'table.actions.operation', width: 100, fixed: 'right', useSlot: true }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -9,43 +9,43 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="抽奖类型" prop="lottery_type">
|
||||
<el-select v-model="formData.lottery_type" placeholder="全部" clearable style="width: 100%">
|
||||
<el-option label="付费" :value="0" />
|
||||
<el-option label="赠送" :value="1" />
|
||||
<el-form-item :label="$t('page.search.drawType')" prop="lottery_type">
|
||||
<el-select v-model="formData.lottery_type" :placeholder="$t('table.searchBar.all')" clearable style="width: 100%">
|
||||
<el-option :label="$t('page.search.paid')" :value="0" />
|
||||
<el-option :label="$t('page.search.free')" :value="1" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="方向" prop="direction">
|
||||
<el-select v-model="formData.direction" placeholder="全部" clearable style="width: 100%">
|
||||
<el-option label="顺时针" :value="0" />
|
||||
<el-option label="逆时针" :value="1" />
|
||||
<el-form-item :label="$t('page.search.direction')" prop="direction">
|
||||
<el-select v-model="formData.direction" :placeholder="$t('table.searchBar.all')" clearable style="width: 100%">
|
||||
<el-option :label="$t('page.search.clockwise')" :value="0" />
|
||||
<el-option :label="$t('page.search.anticlockwise')" :value="1" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="是否中大奖" prop="is_win">
|
||||
<el-select v-model="formData.is_win" placeholder="全部" clearable style="width: 100%">
|
||||
<el-option label="无" :value="0" />
|
||||
<el-option label="中大奖" :value="1" />
|
||||
<el-form-item :label="$t('page.search.isBigWin')" prop="is_win">
|
||||
<el-select v-model="formData.is_win" :placeholder="$t('table.searchBar.all')" clearable style="width: 100%">
|
||||
<el-option :label="$t('page.search.noBigWin')" :value="0" />
|
||||
<el-option :label="$t('page.search.bigWin')" :value="1" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="赢取平台币" prop="win_coin_min">
|
||||
<el-form-item :label="$t('page.search.winCoin')" prop="win_coin_min">
|
||||
<div class="range-wrap">
|
||||
<el-input-number
|
||||
v-model="formData.win_coin_min"
|
||||
placeholder="最小"
|
||||
:placeholder="$t('table.searchBar.min')"
|
||||
:precision="2"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
/>
|
||||
<span class="range-sep">至</span>
|
||||
<span class="range-sep">{{ $t('table.searchBar.rangeSeparator') }}</span>
|
||||
<el-input-number
|
||||
v-model="formData.win_coin_max"
|
||||
placeholder="最大"
|
||||
:placeholder="$t('table.searchBar.max')"
|
||||
:precision="2"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
@@ -54,8 +54,8 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="中奖档位" prop="reward_tier">
|
||||
<el-select v-model="formData.reward_tier" placeholder="全部" clearable style="width: 100%">
|
||||
<el-form-item :label="$t('page.search.rewardTier')" prop="reward_tier">
|
||||
<el-select v-model="formData.reward_tier" :placeholder="$t('table.searchBar.all')" clearable style="width: 100%">
|
||||
<el-option label="T1" value="T1" />
|
||||
<el-option label="T2" value="T2" />
|
||||
<el-option label="T3" value="T3" />
|
||||
@@ -65,10 +65,10 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="点数和" prop="roll_number">
|
||||
<el-form-item :label="$t('page.search.rollNumber')" prop="roll_number">
|
||||
<el-select
|
||||
v-model="formData.roll_number"
|
||||
placeholder="全部"
|
||||
:placeholder="$t('table.searchBar.all')"
|
||||
clearable
|
||||
style="width: 100%"
|
||||
>
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:add-fill" />
|
||||
</template>
|
||||
新增
|
||||
{{ $t('table.actions.add') }}
|
||||
</ElButton>
|
||||
<ElButton
|
||||
v-permission="'dice:player:index:destroy'"
|
||||
@@ -23,7 +23,7 @@
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:delete-bin-5-line" />
|
||||
</template>
|
||||
删除
|
||||
{{ $t('table.actions.delete') }}
|
||||
</ElButton>
|
||||
</ElSpace>
|
||||
</template>
|
||||
@@ -150,73 +150,73 @@
|
||||
apiFn: api.list,
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'username', label: '用户名', align: 'center' },
|
||||
{ prop: 'phone', label: '手机号', align: 'center' },
|
||||
{ prop: 'name', label: '昵称', align: 'center' },
|
||||
{ prop: 'username', label: 'page.table.username', align: 'center' },
|
||||
{ prop: 'phone', label: 'page.table.phone', align: 'center' },
|
||||
{ prop: 'name', label: 'page.table.nickname', align: 'center' },
|
||||
{
|
||||
prop: 'status',
|
||||
label: '状态',
|
||||
label: 'page.table.status',
|
||||
width: 88,
|
||||
align: 'center',
|
||||
useSlot: true
|
||||
},
|
||||
{
|
||||
prop: 'coin',
|
||||
label: '平台币',
|
||||
label: 'page.table.coin',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
useSlot: true
|
||||
},
|
||||
{
|
||||
prop: 'lottery_config_id',
|
||||
label: '彩金池配置',
|
||||
label: 'page.table.lotteryPoolConfig',
|
||||
width: 120,
|
||||
align: 'center',
|
||||
formatter: (row: any) => lotteryConfigNameFormatter(row)
|
||||
},
|
||||
{
|
||||
prop: 't1_weight',
|
||||
label: 'T1权重',
|
||||
label: 'page.table.t1Weight',
|
||||
width: 80,
|
||||
align: 'center',
|
||||
formatter: weightFormatter('t1_weight')
|
||||
},
|
||||
{
|
||||
prop: 't2_weight',
|
||||
label: 'T2权重',
|
||||
label: 'page.table.t2Weight',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
formatter: weightFormatter('t2_weight')
|
||||
},
|
||||
{
|
||||
prop: 't3_weight',
|
||||
label: 'T3权重',
|
||||
label: 'page.table.t3Weight',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
formatter: weightFormatter('t3_weight')
|
||||
},
|
||||
{
|
||||
prop: 't4_weight',
|
||||
label: 'T4权重',
|
||||
label: 'page.table.t4Weight',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
formatter: weightFormatter('t4_weight')
|
||||
},
|
||||
{
|
||||
prop: 't5_weight',
|
||||
label: 'T5权重',
|
||||
label: 'page.table.t5Weight',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
formatter: weightFormatter('t5_weight')
|
||||
},
|
||||
{ prop: 'total_ticket_count', label: '总抽奖次数', align: 'center' },
|
||||
{ prop: 'paid_ticket_count', label: '购买抽奖次数', align: 'center' },
|
||||
{ prop: 'free_ticket_count', label: '赠送抽奖次数', align: 'center' },
|
||||
{ prop: 'create_time', label: '创建时间', align: 'center' },
|
||||
{ prop: 'update_time', label: '更新时间', align: 'center' },
|
||||
{ prop: 'total_ticket_count', label: 'page.table.totalDrawCount', align: 'center' },
|
||||
{ prop: 'paid_ticket_count', label: 'page.table.paidDrawCount', align: 'center' },
|
||||
{ prop: 'free_ticket_count', label: 'page.table.freeDrawCount', align: 'center' },
|
||||
{ prop: 'create_time', label: 'page.table.createTime', align: 'center' },
|
||||
{ prop: 'update_time', label: 'page.table.updateTime', align: 'center' },
|
||||
{
|
||||
prop: 'operation',
|
||||
label: '操作',
|
||||
label: 'table.actions.operation',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
fixed: 'right',
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
v-model="visible"
|
||||
title="玩家钱包操作"
|
||||
:title="$t('page.form.walletTitle')"
|
||||
width="480px"
|
||||
align-center
|
||||
:close-on-click-modal="false"
|
||||
@close="handleClose"
|
||||
>
|
||||
<el-form ref="formRef" :model="formData" :rules="rules" label-width="100px">
|
||||
<el-form-item label="玩家">
|
||||
<el-form-item :label="$t('page.form.walletPlayer')">
|
||||
<el-input :model-value="player?.username" disabled placeholder="-" />
|
||||
</el-form-item>
|
||||
<el-form-item label="钱包余额">
|
||||
<el-form-item :label="$t('page.form.walletBalance')">
|
||||
<el-input-number
|
||||
:model-value="walletBalance"
|
||||
disabled
|
||||
@@ -20,36 +20,36 @@
|
||||
style="width: 100%"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="操作类型" prop="type">
|
||||
<el-select v-model="formData.type" placeholder="请选择" clearable style="width: 100%">
|
||||
<el-option label="加点" :value="3" />
|
||||
<el-option label="扣点" :value="4" />
|
||||
<el-form-item :label="$t('page.form.operationType')" prop="type">
|
||||
<el-select v-model="formData.type" :placeholder="$t('form.placeholderSelect')" clearable style="width: 100%">
|
||||
<el-option :label="$t('page.form.typeAdd')" :value="3" />
|
||||
<el-option :label="$t('page.form.typeSub')" :value="4" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="平台币变动" prop="coin">
|
||||
<el-form-item :label="$t('page.form.coinChange')" prop="coin">
|
||||
<el-input-number
|
||||
v-model="formData.coin"
|
||||
:min="0.01"
|
||||
:precision="2"
|
||||
placeholder="正数,扣点时不能超过余额"
|
||||
:placeholder="$t('page.form.placeholderCoinChange')"
|
||||
controls-position="right"
|
||||
style="width: 100%"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<el-form-item :label="$t('form.labelRemark')" prop="remark">
|
||||
<el-input
|
||||
v-model="formData.remark"
|
||||
type="textarea"
|
||||
:rows="2"
|
||||
placeholder="选填,不填则按类型自动填写"
|
||||
:placeholder="$t('page.form.placeholderRemarkOptional')"
|
||||
maxlength="500"
|
||||
show-word-limit
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<template #footer>
|
||||
<el-button @click="handleClose">取消</el-button>
|
||||
<el-button type="primary" :loading="submitting" @click="handleSubmit">确定</el-button>
|
||||
<el-button @click="handleClose">{{ $t('common.cancel') }}</el-button>
|
||||
<el-button type="primary" :loading="submitting" @click="handleSubmit">{{ $t('common.confirm') }}</el-button>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
@@ -58,6 +58,9 @@
|
||||
import walletRecordApi from '../../../api/player_wallet_record/index'
|
||||
import { ElMessage } from 'element-plus'
|
||||
import type { FormInstance, FormRules } from 'element-plus'
|
||||
import { useI18n } from 'vue-i18n'
|
||||
|
||||
const { t } = useI18n()
|
||||
|
||||
interface PlayerRow {
|
||||
id: number
|
||||
@@ -95,19 +98,19 @@
|
||||
return c != null ? Number(c) : 0
|
||||
})
|
||||
|
||||
const rules = reactive<FormRules>({
|
||||
type: [{ required: true, message: '请选择操作类型', trigger: 'change' }],
|
||||
const rules = computed<FormRules>(() => ({
|
||||
type: [{ required: true, message: t('page.form.ruleSelectType'), trigger: 'change' }],
|
||||
coin: [
|
||||
{ required: true, message: '请输入平台币变动', trigger: 'blur' },
|
||||
{ required: true, message: t('page.form.ruleEnterCoin'), trigger: 'blur' },
|
||||
{
|
||||
validator: (_rule, value, callback) => {
|
||||
const n = Number(value)
|
||||
if (Number.isNaN(n) || n <= 0) {
|
||||
callback(new Error('平台币变动必须大于 0'))
|
||||
callback(new Error(t('page.form.ruleCoinPositive')))
|
||||
return
|
||||
}
|
||||
if (formData.type === 4 && n > walletBalance.value) {
|
||||
callback(new Error('扣点不能超过当前余额'))
|
||||
callback(new Error(t('page.form.ruleDeductExceed')))
|
||||
return
|
||||
}
|
||||
callback()
|
||||
@@ -115,7 +118,7 @@
|
||||
trigger: 'blur'
|
||||
}
|
||||
]
|
||||
})
|
||||
}))
|
||||
|
||||
const initialFormData = {
|
||||
type: null as 3 | 4 | null,
|
||||
@@ -146,11 +149,11 @@
|
||||
await formRef.value.validate()
|
||||
const coin = Number(formData.coin) || 0
|
||||
if (coin <= 0) {
|
||||
ElMessage.warning('平台币变动必须大于 0')
|
||||
ElMessage.warning(t('page.form.ruleCoinPositive'))
|
||||
return
|
||||
}
|
||||
if (formData.type === 4 && coin > walletBalance.value) {
|
||||
ElMessage.warning('扣点不能超过当前余额')
|
||||
ElMessage.warning(t('page.form.ruleDeductExceed'))
|
||||
return
|
||||
}
|
||||
submitting.value = true
|
||||
@@ -160,7 +163,7 @@
|
||||
coin,
|
||||
remark: formData.remark?.trim() || undefined
|
||||
})
|
||||
ElMessage.success('操作成功')
|
||||
ElMessage.success(t('page.form.operateSuccess'))
|
||||
emit('success')
|
||||
handleClose()
|
||||
} catch (e) {
|
||||
|
||||
@@ -1,43 +1,43 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
v-model="visible"
|
||||
:title="dialogType === 'add' ? '新增大富翁-玩家' : '编辑大富翁-玩家'"
|
||||
:title="dialogType === 'add' ? $t('page.form.dialogTitleAdd') : $t('page.form.dialogTitleEdit')"
|
||||
width="600px"
|
||||
align-center
|
||||
:close-on-click-modal="false"
|
||||
@close="handleClose"
|
||||
>
|
||||
<el-form ref="formRef" :model="formData" :rules="rules" label-width="120px">
|
||||
<el-form-item label="用户名" prop="username">
|
||||
<el-input v-model="formData.username" placeholder="请输入用户名" />
|
||||
<el-form-item :label="$t('page.form.username')" prop="username">
|
||||
<el-input v-model="formData.username" :placeholder="$t('page.form.placeholderUsername')" />
|
||||
</el-form-item>
|
||||
<el-form-item label="昵称" prop="name">
|
||||
<el-input v-model="formData.name" placeholder="请输入昵称" />
|
||||
<el-form-item :label="$t('page.form.nickname')" prop="name">
|
||||
<el-input v-model="formData.name" :placeholder="$t('page.form.placeholderNickname')" />
|
||||
</el-form-item>
|
||||
<el-form-item label="手机号" prop="phone">
|
||||
<el-form-item :label="$t('page.form.phone')" prop="phone">
|
||||
<el-input
|
||||
v-model="formData.phone"
|
||||
placeholder="请输入手机号"
|
||||
:placeholder="$t('page.form.placeholderPhone')"
|
||||
clearable
|
||||
maxlength="20"
|
||||
show-word-limit
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="密码" prop="password" :rules="passwordRules">
|
||||
<el-form-item :label="$t('page.form.password')" prop="password" :rules="passwordRules">
|
||||
<el-input
|
||||
v-model="formData.password"
|
||||
type="password"
|
||||
placeholder="编辑留空则不修改"
|
||||
:placeholder="$t('page.form.placeholderPasswordEdit')"
|
||||
show-password
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="状态" prop="status">
|
||||
<el-form-item :label="$t('page.form.status')" prop="status">
|
||||
<sa-switch v-model="formData.status" />
|
||||
</el-form-item>
|
||||
<el-form-item label="所属管理员" prop="admin_id">
|
||||
<el-form-item :label="$t('page.form.adminId')" prop="admin_id">
|
||||
<el-select
|
||||
v-model="formData.admin_id"
|
||||
placeholder="选择后台管理员(可选)"
|
||||
:placeholder="$t('page.form.placeholderAdmin')"
|
||||
clearable
|
||||
filterable
|
||||
style="width: 100%"
|
||||
@@ -51,21 +51,21 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="平台币" prop="coin">
|
||||
<el-form-item :label="$t('page.form.coin')" prop="coin">
|
||||
<el-input-number
|
||||
v-model="formData.coin"
|
||||
:min="0"
|
||||
:precision="2"
|
||||
:disabled="dialogType === 'add'"
|
||||
placeholder="创建时默认0,不可改"
|
||||
:placeholder="$t('page.form.placeholderCoinAdd')"
|
||||
style="width: 100%"
|
||||
/>
|
||||
</el-form-item>
|
||||
<!-- lottery_config_id:空 = 自定义权重,否则 = DiceLotteryConfig.id;选择后该配置的五个 weight 会写入下方 player.*_weight -->
|
||||
<el-form-item label="彩金池配置" prop="lottery_config_id">
|
||||
<el-form-item :label="$t('page.form.lotteryPoolConfig')" prop="lottery_config_id">
|
||||
<el-select
|
||||
v-model="formData.lottery_config_id"
|
||||
placeholder="留空则使用下方自定义权重,或选择彩金池"
|
||||
:placeholder="$t('page.form.placeholderLotteryPool')"
|
||||
clearable
|
||||
filterable
|
||||
style="width: 100%"
|
||||
@@ -81,28 +81,28 @@
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- 当前选中的 DiceLotteryConfig 数据展示 -->
|
||||
<el-form-item v-if="currentLotteryConfig" label="当前配置" class="current-config-block">
|
||||
<el-form-item v-if="currentLotteryConfig" :label="$t('page.form.currentConfig')" class="current-config-block">
|
||||
<div class="current-lottery-config">
|
||||
<div class="config-row">
|
||||
<span class="config-label">名称:</span>
|
||||
<span class="config-label">{{ $t('page.form.configLabelName') }}:</span>
|
||||
<span>{{ currentLotteryConfig.name ?? '-' }}</span>
|
||||
</div>
|
||||
<div class="config-row">
|
||||
<span class="config-label">类型:</span>
|
||||
<span class="config-label">{{ $t('page.form.configLabelType') }}:</span>
|
||||
<span>{{ lotteryConfigTypeText(currentLotteryConfig.type) }}</span>
|
||||
</div>
|
||||
<div class="config-row">
|
||||
<span class="config-label">T1~T5 权重:</span>
|
||||
<span class="config-label">{{ $t('page.form.configLabelWeights') }}:</span>
|
||||
<span>{{ currentLotteryConfigWeightsText }}</span>
|
||||
</div>
|
||||
<div v-if="currentLotteryConfig.remark" class="config-row">
|
||||
<span class="config-label">备注:</span>
|
||||
<span class="config-label">{{ $t('page.form.configLabelRemark') }}:</span>
|
||||
<span>{{ currentLotteryConfig.remark }}</span>
|
||||
</div>
|
||||
</div>
|
||||
</el-form-item>
|
||||
<!-- lottery_config_id 为空时自定义权重可编辑;有值时来自所选 DiceLotteryConfig,仅展示不可编辑 -->
|
||||
<el-form-item label="T1池权重(%)" prop="t1_weight">
|
||||
<el-form-item :label="$t('page.form.t1Weight')" prop="t1_weight">
|
||||
<el-slider
|
||||
v-model="formData.t1_weight"
|
||||
:min="0"
|
||||
@@ -112,7 +112,7 @@
|
||||
:disabled="!isLotteryConfigEmpty()"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="T2池权重(%)" prop="t2_weight">
|
||||
<el-form-item :label="$t('page.form.t2Weight')" prop="t2_weight">
|
||||
<el-slider
|
||||
v-model="formData.t2_weight"
|
||||
:min="0"
|
||||
@@ -122,7 +122,7 @@
|
||||
:disabled="!isLotteryConfigEmpty()"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="T3池权重(%)" prop="t3_weight">
|
||||
<el-form-item :label="$t('page.form.t3Weight')" prop="t3_weight">
|
||||
<el-slider
|
||||
v-model="formData.t3_weight"
|
||||
:min="0"
|
||||
@@ -132,7 +132,7 @@
|
||||
:disabled="!isLotteryConfigEmpty()"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="T4池权重(%)" prop="t4_weight">
|
||||
<el-form-item :label="$t('page.form.t4Weight')" prop="t4_weight">
|
||||
<el-slider
|
||||
v-model="formData.t4_weight"
|
||||
:min="0"
|
||||
@@ -142,7 +142,7 @@
|
||||
:disabled="!isLotteryConfigEmpty()"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="T5池权重(%)" prop="t5_weight">
|
||||
<el-form-item :label="$t('page.form.t5Weight')" prop="t5_weight">
|
||||
<el-slider
|
||||
v-model="formData.t5_weight"
|
||||
:min="0"
|
||||
@@ -154,16 +154,16 @@
|
||||
</el-form-item>
|
||||
<el-form-item v-if="isLotteryConfigEmpty()">
|
||||
<div class="text-gray-500 text-sm">
|
||||
五个池权重总和:<span :class="Math.abs(weightsSum - 100) > 0.01 ? 'text-red-500' : ''">{{
|
||||
{{ $t('page.form.weightsSumHint') }}<span :class="Math.abs(weightsSum - 100) > 0.01 ? 'text-red-500' : ''">{{
|
||||
weightsSum
|
||||
}}</span
|
||||
>% / 100%(必须为100%)
|
||||
>{{ $t('page.form.weightsSumUnit') }}
|
||||
</div>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<template #footer>
|
||||
<el-button @click="handleClose">取消</el-button>
|
||||
<el-button type="primary" @click="handleSubmit">提交</el-button>
|
||||
<el-button @click="handleClose">{{ $t('common.cancel') }}</el-button>
|
||||
<el-button type="primary" @click="handleSubmit">{{ $t('table.form.submit') }}</el-button>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
@@ -9,45 +9,45 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="用户名" prop="username">
|
||||
<el-input v-model="formData.username" placeholder="请输入用户名" clearable />
|
||||
<el-form-item :label="$t('page.search.username')" prop="username">
|
||||
<el-input v-model="formData.username" :placeholder="$t('page.search.placeholderUsername')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="昵称" prop="name">
|
||||
<el-input v-model="formData.name" placeholder="请输入昵称" clearable />
|
||||
<el-form-item :label="$t('page.search.nickname')" prop="name">
|
||||
<el-input v-model="formData.name" :placeholder="$t('page.search.placeholderNickname')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="手机号" prop="phone">
|
||||
<el-input v-model="formData.phone" placeholder="手机号模糊查询" clearable />
|
||||
<el-form-item :label="$t('page.search.phone')" prop="phone">
|
||||
<el-input v-model="formData.phone" :placeholder="$t('page.search.placeholderPhoneFuzzy')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="状态" prop="status">
|
||||
<el-select v-model="formData.status" placeholder="全部" clearable style="width: 100%">
|
||||
<el-option label="启用" :value="1" />
|
||||
<el-option label="禁用" :value="0" />
|
||||
<el-form-item :label="$t('page.search.status')" prop="status">
|
||||
<el-select v-model="formData.status" :placeholder="$t('table.searchBar.all')" clearable style="width: 100%">
|
||||
<el-option :label="$t('table.searchBar.enable')" :value="1" />
|
||||
<el-option :label="$t('table.searchBar.disable')" :value="0" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="平台币" prop="coin">
|
||||
<el-form-item :label="$t('page.search.coin')" prop="coin">
|
||||
<el-input-number
|
||||
v-model="formData.coin"
|
||||
:min="0"
|
||||
:precision="2"
|
||||
placeholder="精确搜索"
|
||||
:placeholder="$t('page.search.exactSearch')"
|
||||
controls-position="right"
|
||||
style="width: 100%"
|
||||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="彩金池配置" prop="lottery_config_id">
|
||||
<el-form-item :label="$t('page.search.lotteryPoolConfig')" prop="lottery_config_id">
|
||||
<el-select
|
||||
v-model="formData.lottery_config_id"
|
||||
placeholder="全部"
|
||||
:placeholder="$t('page.search.placeholderAll')"
|
||||
clearable
|
||||
style="width: 100%"
|
||||
>
|
||||
|
||||
@@ -127,22 +127,22 @@
|
||||
row?.dicePlayer?.username ?? row?.player_id ?? '-'
|
||||
return [
|
||||
// { type: 'selection' },
|
||||
{ prop: 'id', label: 'ID', width: 80, align: 'center' },
|
||||
{ prop: 'id', label: 'page.table.id', width: 80, align: 'center' },
|
||||
{
|
||||
prop: 'player_id',
|
||||
label: '玩家用户名',
|
||||
label: 'page.table.playerUsername',
|
||||
align: 'center',
|
||||
formatter: (row: Record<string, any>) => usernameFormatter(row)
|
||||
},
|
||||
{ prop: 'use_coins', label: '消耗硬币', align: 'center' },
|
||||
{ prop: 'total_ticket_count', label: '总抽奖次数', align: 'center' },
|
||||
{ prop: 'paid_ticket_count', label: '购买抽奖次数', align: 'center' },
|
||||
{ prop: 'free_ticket_count', label: '赠送抽奖次数', align: 'center' },
|
||||
{ prop: 'remark', label: '备注', width: 100, align: 'center', showOverflowTooltip: true },
|
||||
{ prop: 'create_time', label: '创建时间', width: 170, align: 'center' },
|
||||
{ prop: 'use_coins', label: 'page.table.useCoins', align: 'center' },
|
||||
{ prop: 'total_ticket_count', label: 'page.table.totalDrawCount', align: 'center' },
|
||||
{ prop: 'paid_ticket_count', label: 'page.table.paidDrawCount', align: 'center' },
|
||||
{ prop: 'free_ticket_count', label: 'page.table.freeDrawCount', align: 'center' },
|
||||
{ prop: 'remark', label: 'page.table.remark', width: 100, align: 'center', showOverflowTooltip: true },
|
||||
{ prop: 'create_time', label: 'page.table.createTime', width: 170, align: 'center' },
|
||||
{
|
||||
prop: 'operation',
|
||||
label: '操作',
|
||||
label: 'table.actions.operation',
|
||||
width: 60,
|
||||
align: 'center',
|
||||
fixed: 'right',
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
v-model="visible"
|
||||
:title="dialogType === 'add' ? '新增抽奖券获取记录' : '编辑抽奖券获取记录'"
|
||||
:title="dialogType === 'add' ? $t('page.form.dialogTitleAdd') : $t('page.form.dialogTitleEdit')"
|
||||
width="600px"
|
||||
align-center
|
||||
:close-on-click-modal="false"
|
||||
@close="handleClose"
|
||||
>
|
||||
<el-form ref="formRef" :model="formData" :rules="rules" label-width="120px">
|
||||
<el-form-item label="玩家" prop="player_id">
|
||||
<el-form-item :label="$t('page.form.player')" prop="player_id">
|
||||
<el-select
|
||||
v-model="formData.player_id"
|
||||
placeholder="请选择玩家(显示用户名)"
|
||||
:placeholder="$t('page.form.placeholderPlayer')"
|
||||
clearable
|
||||
filterable
|
||||
style="width: 100%"
|
||||
@@ -25,46 +25,46 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="消耗硬币" prop="use_coins">
|
||||
<el-form-item :label="$t('page.form.useCoins')" prop="use_coins">
|
||||
<el-input-number
|
||||
v-model="formData.use_coins"
|
||||
placeholder="请输入消耗硬币"
|
||||
:placeholder="$t('page.form.placeholderUseCoins')"
|
||||
:min="0"
|
||||
:disabled="dialogType === 'edit'"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="购买抽奖次数" prop="paid_ticket_count">
|
||||
<el-form-item :label="$t('page.form.paidDrawCount')" prop="paid_ticket_count">
|
||||
<el-input-number
|
||||
v-model="formData.paid_ticket_count"
|
||||
placeholder="请输入购买抽奖次数"
|
||||
:placeholder="$t('page.form.placeholderPaidDrawCount')"
|
||||
:min="0"
|
||||
@change="onTicketCountChange"
|
||||
:disabled="dialogType === 'edit'"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="赠送抽奖次数" prop="free_ticket_count">
|
||||
<el-form-item :label="$t('page.form.freeDrawCount')" prop="free_ticket_count">
|
||||
<el-input-number
|
||||
v-model="formData.free_ticket_count"
|
||||
placeholder="请输入赠送抽奖次数"
|
||||
:placeholder="$t('page.form.placeholderFreeDrawCount')"
|
||||
:min="0"
|
||||
@change="onTicketCountChange"
|
||||
:disabled="dialogType === 'edit'"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="总抽奖次数" prop="total_ticket_count">
|
||||
<el-form-item :label="$t('page.form.totalDrawCount')" prop="total_ticket_count">
|
||||
<el-input-number
|
||||
:model-value="totalTicketCountComputed"
|
||||
placeholder="自动求和"
|
||||
:placeholder="$t('page.form.placeholderTotalDrawCount')"
|
||||
:min="0"
|
||||
disabled
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<el-form-item :label="$t('form.labelRemark')" prop="remark">
|
||||
<el-input
|
||||
v-model="formData.remark"
|
||||
type="textarea"
|
||||
:rows="3"
|
||||
placeholder="请输入备注(必填)"
|
||||
:placeholder="$t('page.form.placeholderRemark')"
|
||||
maxlength="500"
|
||||
show-word-limit
|
||||
style="width: 100%"
|
||||
@@ -73,8 +73,8 @@
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<template #footer>
|
||||
<el-button @click="handleClose">取消</el-button>
|
||||
<el-button type="primary" @click="handleSubmit">提交</el-button>
|
||||
<el-button @click="handleClose">{{ $t('common.cancel') }}</el-button>
|
||||
<el-button type="primary" @click="handleSubmit">{{ $t('table.form.submit') }}</el-button>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
@@ -9,24 +9,24 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="玩家(用户名)" prop="username">
|
||||
<el-input v-model="formData.username" placeholder="按用户名搜索" clearable />
|
||||
<el-form-item :label="$t('page.search.player')" prop="username">
|
||||
<el-input v-model="formData.username" :placeholder="$t('page.search.byUsername')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="消耗硬币" prop="use_coins_min">
|
||||
<el-form-item :label="$t('page.search.useCoins')" prop="use_coins_min">
|
||||
<div class="range-wrap">
|
||||
<el-input-number
|
||||
v-model="formData.use_coins_min"
|
||||
placeholder="最小"
|
||||
:placeholder="$t('table.searchBar.min')"
|
||||
:min="0"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
/>
|
||||
<span class="range-sep">至</span>
|
||||
<span class="range-sep">{{ $t('table.searchBar.rangeSeparator') }}</span>
|
||||
<el-input-number
|
||||
v-model="formData.use_coins_max"
|
||||
placeholder="最大"
|
||||
:placeholder="$t('table.searchBar.max')"
|
||||
:min="0"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
@@ -35,19 +35,19 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="总抽奖次数" prop="total_ticket_count_min">
|
||||
<el-form-item :label="$t('page.search.totalDrawCount')" prop="total_ticket_count_min">
|
||||
<div class="range-wrap">
|
||||
<el-input-number
|
||||
v-model="formData.total_ticket_count_min"
|
||||
placeholder="最小"
|
||||
:placeholder="$t('table.searchBar.min')"
|
||||
:min="0"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
/>
|
||||
<span class="range-sep">至</span>
|
||||
<span class="range-sep">{{ $t('table.searchBar.rangeSeparator') }}</span>
|
||||
<el-input-number
|
||||
v-model="formData.total_ticket_count_max"
|
||||
placeholder="最大"
|
||||
:placeholder="$t('table.searchBar.max')"
|
||||
:min="0"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
@@ -56,19 +56,19 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="购买抽奖次数" prop="paid_ticket_count_min">
|
||||
<el-form-item :label="$t('page.search.paidDrawCount')" prop="paid_ticket_count_min">
|
||||
<div class="range-wrap">
|
||||
<el-input-number
|
||||
v-model="formData.paid_ticket_count_min"
|
||||
placeholder="最小"
|
||||
:placeholder="$t('table.searchBar.min')"
|
||||
:min="0"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
/>
|
||||
<span class="range-sep">至</span>
|
||||
<span class="range-sep">{{ $t('table.searchBar.rangeSeparator') }}</span>
|
||||
<el-input-number
|
||||
v-model="formData.paid_ticket_count_max"
|
||||
placeholder="最大"
|
||||
:placeholder="$t('table.searchBar.max')"
|
||||
:min="0"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
@@ -77,19 +77,19 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="赠送抽奖次数" prop="free_ticket_count_min">
|
||||
<el-form-item :label="$t('page.search.freeDrawCount')" prop="free_ticket_count_min">
|
||||
<div class="range-wrap">
|
||||
<el-input-number
|
||||
v-model="formData.free_ticket_count_min"
|
||||
placeholder="最小"
|
||||
:placeholder="$t('table.searchBar.min')"
|
||||
:min="0"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
/>
|
||||
<span class="range-sep">至</span>
|
||||
<span class="range-sep">{{ $t('table.searchBar.rangeSeparator') }}</span>
|
||||
<el-input-number
|
||||
v-model="formData.free_ticket_count_max"
|
||||
placeholder="最大"
|
||||
:placeholder="$t('table.searchBar.max')"
|
||||
:min="0"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
@@ -98,13 +98,13 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(8)">
|
||||
<el-form-item label="创建时间" prop="create_time_min">
|
||||
<el-form-item :label="$t('page.search.createTime')" prop="create_time_min">
|
||||
<el-date-picker
|
||||
v-model="formData.create_time"
|
||||
type="datetimerange"
|
||||
range-separator="至"
|
||||
start-placeholder="开始时间"
|
||||
end-placeholder="结束时间"
|
||||
:range-separator="$t('table.searchBar.rangeSeparator')"
|
||||
:start-placeholder="$t('table.searchBar.startTime')"
|
||||
:end-placeholder="$t('table.searchBar.endTime')"
|
||||
value-format="YYYY-MM-DD HH:mm:ss"
|
||||
style="width: 100%"
|
||||
clearable
|
||||
|
||||
@@ -81,6 +81,7 @@
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { useI18n } from 'vue-i18n'
|
||||
import { useTable } from '@/hooks/core/useTable'
|
||||
import { useSaiAdmin } from '@/composables/useSaiAdmin'
|
||||
import api from '../../api/player_wallet_record/index'
|
||||
@@ -108,15 +109,16 @@
|
||||
getData()
|
||||
}
|
||||
|
||||
const { t } = useI18n()
|
||||
// 类型展示:0=充值 1=提现 2=购买抽奖次数 3=管理员加点 4=管理员扣点 5=抽奖
|
||||
const typeFormatter = (row: Record<string, unknown>) => {
|
||||
const t = row.type
|
||||
if (t === 0) return '充值'
|
||||
if (t === 1) return '提现'
|
||||
if (t === 2) return '购买抽奖次数'
|
||||
if (t === 3) return '管理员加点'
|
||||
if (t === 4) return '管理员扣点'
|
||||
if (t === 5) return '抽奖'
|
||||
const ty = row.type
|
||||
if (ty === 0) return t('page.search.typeRecharge')
|
||||
if (ty === 1) return t('page.search.typeWithdraw')
|
||||
if (ty === 2) return t('page.search.typeBuyTicket')
|
||||
if (ty === 3) return t('page.search.typeAdminAdd')
|
||||
if (ty === 4) return t('page.search.typeAdminSub')
|
||||
if (ty === 5) return t('page.table.typeDraw')
|
||||
return '-'
|
||||
}
|
||||
|
||||
@@ -163,18 +165,18 @@
|
||||
apiFn: api.list,
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection', align: 'center' },
|
||||
{ prop: 'id', label: 'ID', width: 80, align: 'center' },
|
||||
{ prop: 'id', label: 'page.table.id', width: 80, align: 'center' },
|
||||
{
|
||||
prop: 'player_id',
|
||||
label: '用户',
|
||||
label: 'page.table.user',
|
||||
width: 120,
|
||||
align: 'center',
|
||||
formatter: usernameFormatter
|
||||
},
|
||||
{ prop: 'coin', label: '平台币变化', width: 110, align: 'center' },
|
||||
{ prop: 'coin', label: 'page.table.coinChange', width: 110, align: 'center' },
|
||||
{
|
||||
prop: 'type',
|
||||
label: '类型',
|
||||
label: 'page.table.type',
|
||||
width: 140,
|
||||
align: 'center',
|
||||
useSlot: true,
|
||||
@@ -182,27 +184,27 @@
|
||||
},
|
||||
{
|
||||
prop: 'user_id',
|
||||
label: '操作人',
|
||||
label: 'page.table.operator',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
formatter: operatorFormatter
|
||||
},
|
||||
{ prop: 'wallet_before', label: '钱包操作前', width: 110, align: 'center' },
|
||||
{ prop: 'wallet_after', label: '钱包操作后', width: 110, align: 'center' },
|
||||
{ prop: 'wallet_before', label: 'page.table.walletBefore', width: 110, align: 'center' },
|
||||
{ prop: 'wallet_after', label: 'page.table.walletAfter', width: 110, align: 'center' },
|
||||
{
|
||||
prop: 'remark',
|
||||
label: '备注',
|
||||
label: 'page.table.remark',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
showOverflowTooltip: true
|
||||
},
|
||||
{ prop: 'total_ticket_count', label: '总抽奖次数', align: 'center' },
|
||||
{ prop: 'paid_ticket_count', label: '购买抽奖次数', align: 'center' },
|
||||
{ prop: 'free_ticket_count', label: '赠送抽奖次数', align: 'center' },
|
||||
{ prop: 'create_time', label: '创建时间', width: 170, align: 'center' },
|
||||
{ prop: 'total_ticket_count', label: 'page.table.totalDrawCount', align: 'center' },
|
||||
{ prop: 'paid_ticket_count', label: 'page.table.paidDrawCount', align: 'center' },
|
||||
{ prop: 'free_ticket_count', label: 'page.table.freeDrawCount', align: 'center' },
|
||||
{ prop: 'create_time', label: 'page.table.createTime', width: 170, align: 'center' },
|
||||
{
|
||||
prop: 'operation',
|
||||
label: '操作',
|
||||
label: 'table.actions.operation',
|
||||
width: 60,
|
||||
align: 'center',
|
||||
fixed: 'right',
|
||||
|
||||
@@ -1,17 +1,17 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
v-model="visible"
|
||||
:title="dialogType === 'add' ? '新增玩家钱包流水' : '编辑玩家钱包流水'"
|
||||
:title="dialogType === 'add' ? $t('page.form.dialogTitleAdd') : $t('page.form.dialogTitleEdit')"
|
||||
width="600px"
|
||||
align-center
|
||||
:close-on-click-modal="false"
|
||||
@close="handleClose"
|
||||
>
|
||||
<el-form ref="formRef" :model="formData" :rules="rules" label-width="120px">
|
||||
<el-form-item label="用户" prop="player_id">
|
||||
<el-form-item :label="$t('page.form.user')" prop="player_id">
|
||||
<el-select
|
||||
v-model="formData.player_id"
|
||||
placeholder="请选择用户(显示用户名)"
|
||||
:placeholder="$t('page.form.placeholderUser')"
|
||||
clearable
|
||||
filterable
|
||||
style="width: 100%"
|
||||
@@ -26,55 +26,55 @@
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="类型" prop="type">
|
||||
<el-form-item :label="$t('page.form.type')" prop="type">
|
||||
<el-select
|
||||
v-model="formData.type"
|
||||
placeholder="请选择类型"
|
||||
:placeholder="$t('page.form.placeholderType')"
|
||||
clearable
|
||||
style="width: 100%"
|
||||
:disabled="dialogType === 'edit'"
|
||||
>
|
||||
<el-option label="充值" :value="0" />
|
||||
<el-option label="提现" :value="1" />
|
||||
<el-option label="购买抽奖次数" :value="2" />
|
||||
<el-option label="管理员加点" :value="3" />
|
||||
<el-option label="管理员扣点" :value="4" />
|
||||
<el-option :label="$t('page.form.typeRecharge')" :value="0" />
|
||||
<el-option :label="$t('page.form.typeWithdraw')" :value="1" />
|
||||
<el-option :label="$t('page.form.typeBuyTicket')" :value="2" />
|
||||
<el-option :label="$t('page.form.typeAdminAdd')" :value="3" />
|
||||
<el-option :label="$t('page.form.typeAdminSub')" :value="4" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="平台币变化" prop="coin">
|
||||
<el-form-item :label="$t('page.form.coinChange')" prop="coin">
|
||||
<el-input-number
|
||||
v-model="formData.coin"
|
||||
placeholder="正数增加、负数减少"
|
||||
:placeholder="$t('page.form.placeholderCoinChange')"
|
||||
:precision="2"
|
||||
style="width: 100%"
|
||||
@change="onCoinChange"
|
||||
:disabled="dialogType === 'edit'"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="钱包操作前" prop="wallet_before">
|
||||
<el-form-item :label="$t('page.form.walletBefore')" prop="wallet_before">
|
||||
<el-input-number
|
||||
v-model="formData.wallet_before"
|
||||
placeholder="选择用户后自动带出当前平台币"
|
||||
:placeholder="$t('page.form.placeholderWalletBefore')"
|
||||
:precision="2"
|
||||
disabled
|
||||
style="width: 100%"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="钱包操作后" prop="wallet_after">
|
||||
<el-form-item :label="$t('page.form.walletAfter')" prop="wallet_after">
|
||||
<el-input-number
|
||||
v-model="formData.wallet_after"
|
||||
placeholder="根据平台币变化自动计算"
|
||||
:placeholder="$t('page.form.placeholderWalletAfter')"
|
||||
:precision="2"
|
||||
disabled
|
||||
style="width: 100%"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<el-form-item :label="$t('form.labelRemark')" prop="remark">
|
||||
<el-input
|
||||
v-model="formData.remark"
|
||||
type="textarea"
|
||||
:rows="2"
|
||||
placeholder="选填"
|
||||
:placeholder="$t('page.form.placeholderRemark')"
|
||||
maxlength="500"
|
||||
show-word-limit
|
||||
:disabled="dialogType === 'edit'"
|
||||
@@ -82,8 +82,8 @@
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<template #footer>
|
||||
<el-button @click="handleClose">取消</el-button>
|
||||
<el-button type="primary" @click="handleSubmit">提交</el-button>
|
||||
<el-button @click="handleClose">{{ $t('common.cancel') }}</el-button>
|
||||
<el-button type="primary" @click="handleSubmit">{{ $t('table.form.submit') }}</el-button>
|
||||
</template>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
@@ -9,35 +9,35 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(5)">
|
||||
<el-form-item label="类型" prop="type">
|
||||
<el-select v-model="formData.type" placeholder="全部" clearable style="width: 100%">
|
||||
<el-option label="充值" :value="0" />
|
||||
<el-option label="提现" :value="1" />
|
||||
<el-option label="购买抽奖次数" :value="2" />
|
||||
<el-option label="管理员加点" :value="3" />
|
||||
<el-option label="管理员扣点" :value="4" />
|
||||
<el-form-item :label="$t('page.search.type')" prop="type">
|
||||
<el-select v-model="formData.type" :placeholder="$t('table.searchBar.all')" clearable style="width: 100%">
|
||||
<el-option :label="$t('page.search.typeRecharge')" :value="0" />
|
||||
<el-option :label="$t('page.search.typeWithdraw')" :value="1" />
|
||||
<el-option :label="$t('page.search.typeBuyTicket')" :value="2" />
|
||||
<el-option :label="$t('page.search.typeAdminAdd')" :value="3" />
|
||||
<el-option :label="$t('page.search.typeAdminSub')" :value="4" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(5)">
|
||||
<el-form-item label="用户(用户名)" prop="username">
|
||||
<el-input v-model="formData.username" placeholder="按用户名搜索" clearable />
|
||||
<el-form-item :label="$t('page.search.user')" prop="username">
|
||||
<el-input v-model="formData.username" :placeholder="$t('page.search.byUsername')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(8)">
|
||||
<el-form-item label="平台币" prop="coin_min">
|
||||
<el-form-item :label="$t('page.search.coin')" prop="coin_min">
|
||||
<div class="coin-range-wrap">
|
||||
<el-input-number
|
||||
v-model="formData.coin_min"
|
||||
placeholder="最小"
|
||||
:placeholder="$t('table.searchBar.min')"
|
||||
:precision="2"
|
||||
controls-position="right"
|
||||
class="coin-range-input"
|
||||
/>
|
||||
<span class="coin-range-sep">至</span>
|
||||
<span class="coin-range-sep">{{ $t('table.searchBar.rangeSeparator') }}</span>
|
||||
<el-input-number
|
||||
v-model="formData.coin_max"
|
||||
placeholder="最大"
|
||||
:placeholder="$t('table.searchBar.max')"
|
||||
:precision="2"
|
||||
controls-position="right"
|
||||
class="coin-range-input"
|
||||
@@ -46,13 +46,13 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(8)">
|
||||
<el-form-item label="创建时间" prop="create_time">
|
||||
<el-form-item :label="$t('page.search.createTime')" prop="create_time">
|
||||
<el-date-picker
|
||||
v-model="formData.create_time"
|
||||
type="datetimerange"
|
||||
range-separator="至"
|
||||
start-placeholder="开始时间"
|
||||
end-placeholder="结束时间"
|
||||
:range-separator="$t('table.searchBar.rangeSeparator')"
|
||||
:start-placeholder="$t('table.searchBar.startTime')"
|
||||
:end-placeholder="$t('table.searchBar.endTime')"
|
||||
value-format="YYYY-MM-DD HH:mm:ss"
|
||||
style="width: 100%"
|
||||
/>
|
||||
|
||||
@@ -3,8 +3,8 @@
|
||||
<!-- 方向切换 + 搜索 -->
|
||||
<div class="direction-bar">
|
||||
<el-radio-group v-model="currentDirection" size="default" @change="onDirectionChange">
|
||||
<el-radio-button :value="0">顺时针</el-radio-button>
|
||||
<el-radio-button :value="1">逆时针</el-radio-button>
|
||||
<el-radio-button :value="0">{{ $t('page.search.clockwise') }}</el-radio-button>
|
||||
<el-radio-button :value="1">{{ $t('page.search.anticlockwise') }}</el-radio-button>
|
||||
</el-radio-group>
|
||||
</div>
|
||||
<TableSearch v-model="searchForm" @search="handleSearch" @reset="resetSearchParams" />
|
||||
@@ -19,14 +19,14 @@
|
||||
@click="weightRatioVisible = true"
|
||||
v-ripple
|
||||
>
|
||||
权重配比
|
||||
{{ $t('page.toolbar.weightRatio') }}
|
||||
</ElButton>
|
||||
<ElButton
|
||||
v-permission="'dice:reward:index:index'"
|
||||
@click="weightTestVisible = true"
|
||||
v-ripple
|
||||
>
|
||||
一键测试权重
|
||||
{{ $t('page.toolbar.weightTest') }}
|
||||
</ElButton>
|
||||
</ElSpace>
|
||||
</template>
|
||||
@@ -99,12 +99,12 @@
|
||||
apiFn: listApi,
|
||||
apiParams: { direction: 0, limit: 100 },
|
||||
columnsFactory: () => [
|
||||
{ prop: 'start_index', label: '起始索引', width: 100, align: 'center' },
|
||||
{ prop: 'end_index', label: '结束索引(end_index)', width: 110, align: 'center' },
|
||||
{ prop: 'tier', label: '档位', width: 90, align: 'center', sortable: true },
|
||||
{ prop: 'start_index', label: 'page.table.startIndex', width: 100, align: 'center' },
|
||||
{ prop: 'end_index', label: 'page.table.endIndex', width: 110, align: 'center' },
|
||||
{ prop: 'tier', label: 'page.table.tier', width: 90, align: 'center', sortable: true },
|
||||
{
|
||||
prop: 'grid_number',
|
||||
label: '色子点数(摇取5-30)',
|
||||
label: 'page.table.dicePoints',
|
||||
width: 120,
|
||||
align: 'center',
|
||||
sortable: true,
|
||||
@@ -112,14 +112,14 @@
|
||||
},
|
||||
{
|
||||
prop: 'ui_text',
|
||||
label: '显示文本',
|
||||
label: 'page.table.displayText',
|
||||
minWidth: 100,
|
||||
align: 'center',
|
||||
showOverflowTooltip: true
|
||||
},
|
||||
{ prop: 'real_ev', label: '实际中奖金额', width: 110, align: 'center' },
|
||||
{ prop: 'remark', label: '备注', minWidth: 80, align: 'center', showOverflowTooltip: true },
|
||||
{ prop: 'weight', label: '权重(1-10000)', width: 110, align: 'center' }
|
||||
{ prop: 'real_ev', label: 'page.table.realEv', width: 110, align: 'center' },
|
||||
{ prop: 'remark', label: 'page.table.remark', minWidth: 80, align: 'center', showOverflowTooltip: true },
|
||||
{ prop: 'weight', label: 'page.table.weight', width: 110, align: 'center' }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -8,8 +8,8 @@
|
||||
@search="handleSearch"
|
||||
>
|
||||
<el-col v-bind="setSpan(8)">
|
||||
<el-form-item label="档位" prop="tier">
|
||||
<el-select v-model="formData.tier" placeholder="全部" clearable style="width: 100%">
|
||||
<el-form-item :label="$t('page.search.tier')" prop="tier">
|
||||
<el-select v-model="formData.tier" :placeholder="$t('table.searchBar.all')" clearable style="width: 100%">
|
||||
<el-option label="T1" value="T1" />
|
||||
<el-option label="T2" value="T2" />
|
||||
<el-option label="T3" value="T3" />
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<ElCard shadow="never" class="form-card">
|
||||
<template #header>
|
||||
<div class="card-header">
|
||||
<span>游戏奖励配置</span>
|
||||
<span>{{ $t('page.toolbar.gameRewardConfig') }}</span>
|
||||
<ElButton
|
||||
v-permission="'dice:reward_config:index:update'"
|
||||
type="warning"
|
||||
@@ -12,7 +12,7 @@
|
||||
v-ripple
|
||||
title="按规则:start_index=config(grid_number).id;顺时针 end_index=(start_index+grid_number)%26;逆时针 end_index=start_index-grid_number≥0?start_index-grid_number:26+start_index-grid_number"
|
||||
>
|
||||
创建奖励对照
|
||||
{{ $t('page.toolbar.createRewardRef') }}
|
||||
</ElButton>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -9,18 +9,18 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="色子点数" prop="grid_number_min">
|
||||
<el-form-item :label="$t('page.search.dicePoints')" prop="grid_number_min">
|
||||
<div class="range-wrap">
|
||||
<el-input-number
|
||||
v-model="formData.grid_number_min"
|
||||
placeholder="最小"
|
||||
:placeholder="$t('table.searchBar.min')"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
/>
|
||||
<span class="range-sep">至</span>
|
||||
<span class="range-sep">{{ $t('table.searchBar.rangeSeparator') }}</span>
|
||||
<el-input-number
|
||||
v-model="formData.grid_number_max"
|
||||
placeholder="最大"
|
||||
:placeholder="$t('table.searchBar.max')"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
/>
|
||||
@@ -28,24 +28,24 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="前端显示文本" prop="ui_text">
|
||||
<el-input v-model="formData.ui_text" placeholder="模糊查询" clearable />
|
||||
<el-form-item :label="$t('page.search.displayText')" prop="ui_text">
|
||||
<el-input v-model="formData.ui_text" :placeholder="$t('page.search.fuzzyQuery')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="真实资金结算" prop="real_ev_min">
|
||||
<el-form-item :label="$t('page.search.realEv')" prop="real_ev_min">
|
||||
<div class="range-wrap">
|
||||
<el-input-number
|
||||
v-model="formData.real_ev_min"
|
||||
placeholder="最小"
|
||||
:placeholder="$t('table.searchBar.min')"
|
||||
:precision="2"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
/>
|
||||
<span class="range-sep">至</span>
|
||||
<span class="range-sep">{{ $t('table.searchBar.rangeSeparator') }}</span>
|
||||
<el-input-number
|
||||
v-model="formData.real_ev_max"
|
||||
placeholder="最大"
|
||||
:placeholder="$t('table.searchBar.max')"
|
||||
:precision="2"
|
||||
controls-position="right"
|
||||
class="range-input"
|
||||
@@ -54,8 +54,8 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="所属档位" prop="tier">
|
||||
<el-select v-model="formData.tier" placeholder="全部" clearable style="width: 100%">
|
||||
<el-form-item :label="$t('page.search.tier')" prop="tier">
|
||||
<el-select v-model="formData.tier" :placeholder="$t('table.searchBar.all')" clearable style="width: 100%">
|
||||
<el-option label="T1" value="T1" />
|
||||
<el-option label="T2" value="T2" />
|
||||
<el-option label="T3" value="T3" />
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:delete-bin-5-line" />
|
||||
</template>
|
||||
删除
|
||||
{{ $t('table.actions.delete') }}
|
||||
</ElButton>
|
||||
</ElSpace>
|
||||
</template>
|
||||
@@ -58,7 +58,7 @@
|
||||
<SaButton
|
||||
v-permission="'dice:reward_config_record:index:read'"
|
||||
type="success"
|
||||
toolTip="查看详情"
|
||||
:toolTip="$t('page.toolbar.viewDetail')"
|
||||
@click="openDetail(row)"
|
||||
/>
|
||||
<SaButton
|
||||
@@ -84,6 +84,7 @@
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { useI18n } from 'vue-i18n'
|
||||
import { useTable } from '@/hooks/core/useTable'
|
||||
import { useSaiAdmin } from '@/composables/useSaiAdmin'
|
||||
import api from '../../api/reward_config_record/index'
|
||||
@@ -119,12 +120,13 @@
|
||||
}
|
||||
}
|
||||
|
||||
const { t } = useI18n()
|
||||
// 状态文案:-1失败 0测试中 1完成(2=执行中也显示测试中)
|
||||
function formatStatus(status: unknown): string {
|
||||
const s = Number(status)
|
||||
if (s === -1) return '失败'
|
||||
if (s === 1) return '完成'
|
||||
if (s === 0 || s === 2) return '测试中'
|
||||
if (s === -1) return t('page.table.statusFail')
|
||||
if (s === 1) return t('page.table.statusDone')
|
||||
if (s === 0 || s === 2) return t('page.table.statusTesting')
|
||||
return '—'
|
||||
}
|
||||
|
||||
@@ -168,47 +170,47 @@
|
||||
apiParams: { limit: 100 },
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'id', label: 'ID', width: 80, align: 'center' },
|
||||
{ prop: 'id', label: 'page.table.id', width: 80, align: 'center' },
|
||||
{
|
||||
prop: 'status',
|
||||
label: '状态',
|
||||
label: 'page.table.status',
|
||||
width: 90,
|
||||
align: 'center',
|
||||
useSlot: true
|
||||
},
|
||||
{
|
||||
prop: 'paid_draw',
|
||||
label: '付费抽取',
|
||||
label: 'page.table.paidDraw',
|
||||
width: 160,
|
||||
align: 'center',
|
||||
useSlot: true
|
||||
},
|
||||
{
|
||||
prop: 'free_draw',
|
||||
label: '免费抽取',
|
||||
label: 'page.table.freeDraw',
|
||||
width: 160,
|
||||
align: 'center',
|
||||
useSlot: true
|
||||
},
|
||||
{
|
||||
prop: 'platform_profit',
|
||||
label: '平台赚取金额',
|
||||
label: 'page.table.platformProfit',
|
||||
width: 120,
|
||||
align: 'center',
|
||||
useSlot: true
|
||||
},
|
||||
{ prop: 'total_play_count', label: '总抽奖次数', width: 110, align: 'center' },
|
||||
{ prop: 'total_play_count', label: 'page.table.totalDrawCount', width: 110, align: 'center' },
|
||||
{
|
||||
prop: 'admin_name',
|
||||
label: '创建管理员',
|
||||
label: 'page.table.createdBy',
|
||||
width: 120,
|
||||
align: 'center',
|
||||
showOverflowTooltip: true
|
||||
},
|
||||
{ prop: 'create_time', label: '创建时间', width: 170, align: 'center' },
|
||||
{ prop: 'create_time', label: 'page.table.createTime', width: 170, align: 'center' },
|
||||
{
|
||||
prop: 'operation',
|
||||
label: '操作',
|
||||
label: 'table.actions.operation',
|
||||
width: 100,
|
||||
align: 'center',
|
||||
fixed: 'right',
|
||||
|
||||
@@ -244,19 +244,19 @@
|
||||
},
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'url', label: '预览', saiType: 'image', width: 80 },
|
||||
{ prop: 'origin_name', label: '文件名称', minWidth: 160, showOverflowTooltip: true },
|
||||
{ prop: 'url', label: 'page.table.preview', saiType: 'image', width: 80 },
|
||||
{ prop: 'origin_name', label: 'page.table.fileName', minWidth: 160, showOverflowTooltip: true },
|
||||
{
|
||||
prop: 'storage_mode',
|
||||
label: '存储模式',
|
||||
label: 'page.table.storageMode',
|
||||
width: 100,
|
||||
saiType: 'dict',
|
||||
saiDict: 'upload_mode'
|
||||
},
|
||||
{ prop: 'mime_type', label: '文件类型', width: 160, showOverflowTooltip: true },
|
||||
{ prop: 'size_info', label: '文件大小', width: 100 },
|
||||
{ prop: 'create_time', label: '上传时间', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: '操作', width: 100, fixed: 'right', useSlot: true }
|
||||
{ prop: 'mime_type', label: 'page.table.fileType', width: 160, showOverflowTooltip: true },
|
||||
{ prop: 'size_info', label: 'page.table.fileSize', width: 100 },
|
||||
{ prop: 'create_time', label: 'page.table.uploadTime', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: 'table.actions.operation', width: 100, fixed: 'right', useSlot: true }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -9,18 +9,18 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="用户名" prop="username">
|
||||
<el-input v-model="formData.username" placeholder="请输入用户名" clearable />
|
||||
<el-form-item :label="$t('page.search.username')" prop="username">
|
||||
<el-input v-model="formData.username" :placeholder="$t('page.search.placeholderUsername')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="手机号" prop="phone">
|
||||
<el-input v-model="formData.phone" placeholder="请输入手机号" clearable />
|
||||
<el-form-item :label="$t('page.search.phone')" prop="phone">
|
||||
<el-input v-model="formData.phone" :placeholder="$t('page.search.placeholderPhone')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="状态" prop="status">
|
||||
<sa-select v-model="formData.status" dict="data_status" clearable />
|
||||
<el-form-item :label="$t('page.search.status')" prop="status">
|
||||
<sa-select v-model="formData.status" dict="data_status" :placeholder="$t('page.search.searchSelectPlaceholder')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</sa-search-bar>
|
||||
|
||||
@@ -125,16 +125,16 @@
|
||||
},
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'name', label: '表名称', minWidth: 200 },
|
||||
{ prop: 'comment', label: '表注释', minWidth: 150, showOverflowTooltip: true },
|
||||
{ prop: 'engine', label: '表引擎', width: 120 },
|
||||
{ prop: 'update_time', label: '更新时间', width: 180, sortable: true },
|
||||
{ prop: 'rows', label: '总行数', width: 120 },
|
||||
{ prop: 'data_free', label: '碎片大小', width: 120 },
|
||||
{ prop: 'data_length', label: '数据大小', width: 120 },
|
||||
{ prop: 'collation', label: '字符集', width: 180 },
|
||||
{ prop: 'create_time', label: '创建时间', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: '操作', width: 100, fixed: 'right', useSlot: true }
|
||||
{ prop: 'name', label: 'page.table.tableName', minWidth: 200 },
|
||||
{ prop: 'comment', label: 'page.table.tableComment', minWidth: 150, showOverflowTooltip: true },
|
||||
{ prop: 'engine', label: 'page.table.tableEngine', width: 120 },
|
||||
{ prop: 'update_time', label: 'page.table.updateTime', width: 180, sortable: true },
|
||||
{ prop: 'rows', label: 'page.table.totalRows', width: 120 },
|
||||
{ prop: 'data_free', label: 'page.table.fragmentSize', width: 120 },
|
||||
{ prop: 'data_length', label: 'page.table.dataSize', width: 120 },
|
||||
{ prop: 'collation', label: 'page.table.collation', width: 180 },
|
||||
{ prop: 'create_time', label: 'page.table.createTime', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: 'table.actions.operation', width: 100, fixed: 'right', useSlot: true }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -140,8 +140,8 @@
|
||||
},
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'delete_time', label: '删除时间', width: 180 },
|
||||
{ prop: 'json_data', label: '数据详情', useSlot: true, showOverflowTooltip: true }
|
||||
{ prop: 'delete_time', label: 'page.table.deleteTime', width: 180 },
|
||||
{ prop: 'json_data', label: 'page.table.dataDetail', useSlot: true, showOverflowTooltip: true }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -9,8 +9,8 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="表名称" prop="name">
|
||||
<el-input v-model="formData.name" placeholder="请输入表名称" clearable />
|
||||
<el-form-item :label="$t('page.search.tableName')" prop="name">
|
||||
<el-input v-model="formData.name" :placeholder="$t('page.search.placeholderTableName')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</sa-search-bar>
|
||||
|
||||
@@ -268,10 +268,10 @@
|
||||
...typeSearch.value
|
||||
},
|
||||
columnsFactory: () => [
|
||||
{ prop: 'id', label: '选中', width: 80, align: 'center', useSlot: true },
|
||||
{ prop: 'name', label: '字典名称', useHeaderSlot: true, width: 150 },
|
||||
{ prop: 'code', label: '字典标识', useHeaderSlot: true, width: 150 },
|
||||
{ prop: 'status', label: '状态', saiType: 'dict', saiDict: 'data_status', width: 100 }
|
||||
{ prop: 'id', label: 'page.table.select', width: 80, align: 'center', useSlot: true },
|
||||
{ prop: 'name', label: 'page.table.dictName', useHeaderSlot: true, width: 150 },
|
||||
{ prop: 'code', label: 'page.table.dictCode', useHeaderSlot: true, width: 150 },
|
||||
{ prop: 'status', label: 'page.table.status', saiType: 'dict', saiDict: 'data_status', width: 100 }
|
||||
]
|
||||
}
|
||||
})
|
||||
@@ -312,12 +312,12 @@
|
||||
},
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'label', label: '字典标签', useSlot: true },
|
||||
{ prop: 'value', label: '字典键值' },
|
||||
{ prop: 'color', label: '颜色' },
|
||||
{ prop: 'sort', label: '排序' },
|
||||
{ prop: 'status', label: '状态', saiType: 'dict', saiDict: 'data_status' },
|
||||
{ prop: 'operation', label: '操作', useSlot: true, width: 120 }
|
||||
{ prop: 'label', label: 'page.table.dictLabel', useSlot: true },
|
||||
{ prop: 'value', label: 'page.table.dictValue' },
|
||||
{ prop: 'color', label: 'page.table.color' },
|
||||
{ prop: 'sort', label: 'page.table.sort' },
|
||||
{ prop: 'status', label: 'page.table.status', saiType: 'dict', saiDict: 'data_status' },
|
||||
{ prop: 'operation', label: 'table.actions.operation', useSlot: true, width: 120 }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -103,15 +103,15 @@
|
||||
},
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'id', label: '编号', width: 100, align: 'center' },
|
||||
{ prop: 'gateway', label: '服务Host' },
|
||||
{ prop: 'from', label: '发件人', minWidth: 150, showOverflowTooltip: true },
|
||||
{ prop: 'email', label: '收件人', minWidth: 150, showOverflowTooltip: true },
|
||||
{ prop: 'code', label: '验证码' },
|
||||
{ prop: 'status', label: '发送状态', useSlot: true },
|
||||
{ prop: 'response', label: '发送结果', minWidth: 150, showOverflowTooltip: true },
|
||||
{ prop: 'create_time', label: '发送时间', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: '操作', width: 80, fixed: 'right', useSlot: true }
|
||||
{ prop: 'id', label: 'page.table.no', width: 100, align: 'center' },
|
||||
{ prop: 'gateway', label: 'page.table.gateway' },
|
||||
{ prop: 'from', label: 'page.table.emailFrom', minWidth: 150, showOverflowTooltip: true },
|
||||
{ prop: 'email', label: 'page.table.emailTo', minWidth: 150, showOverflowTooltip: true },
|
||||
{ prop: 'code', label: 'page.table.emailCode' },
|
||||
{ prop: 'status', label: 'page.table.sendStatus', useSlot: true },
|
||||
{ prop: 'response', label: 'page.table.emailResponse', minWidth: 150, showOverflowTooltip: true },
|
||||
{ prop: 'create_time', label: 'page.table.sendTime', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: 'table.actions.operation', width: 80, fixed: 'right', useSlot: true }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -9,31 +9,31 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="发件人" prop="from">
|
||||
<el-input v-model="formData.from" placeholder="请输入发件人" clearable />
|
||||
<el-form-item :label="$t('page.search.labelFrom')" prop="from">
|
||||
<el-input v-model="formData.from" :placeholder="$t('page.search.placeholderFrom')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="收件人" prop="email">
|
||||
<el-input v-model="formData.email" placeholder="请输入收件人" clearable />
|
||||
<el-form-item :label="$t('page.search.labelTo')" prop="email">
|
||||
<el-input v-model="formData.email" :placeholder="$t('page.search.placeholderTo')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="发送状态" prop="status">
|
||||
<el-select v-model="formData.status" placeholder="请选择发送状态" clearable>
|
||||
<el-option label="成功" value="success" />
|
||||
<el-option label="失败" value="failure" />
|
||||
<el-form-item :label="$t('page.search.placeholderSendStatus')" prop="status">
|
||||
<el-select v-model="formData.status" :placeholder="$t('page.search.placeholderSendStatus')" clearable>
|
||||
<el-option :label="$t('table.searchBar.success')" value="success" />
|
||||
<el-option :label="$t('table.searchBar.failure')" value="failure" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(12)" v-show="isExpanded">
|
||||
<el-form-item label="发送时间" prop="create_time">
|
||||
<el-form-item :label="$t('page.search.operTime')" prop="create_time">
|
||||
<el-date-picker
|
||||
v-model="formData.create_time"
|
||||
type="datetimerange"
|
||||
range-separator="至"
|
||||
start-placeholder="开始时间"
|
||||
end-placeholder="结束时间"
|
||||
:range-separator="$t('table.searchBar.rangeSeparator')"
|
||||
:start-placeholder="$t('table.searchBar.startTime')"
|
||||
:end-placeholder="$t('table.searchBar.endTime')"
|
||||
value-format="YYYY-MM-DD HH:mm:ss"
|
||||
clearable
|
||||
/>
|
||||
|
||||
@@ -103,16 +103,16 @@
|
||||
},
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'id', label: '编号', width: 100, align: 'center' },
|
||||
{ prop: 'username', label: '登录用户' },
|
||||
{ prop: 'status', label: '登录状态', useSlot: true },
|
||||
{ prop: 'ip', label: '登录IP' },
|
||||
{ prop: 'ip_location', label: '登录地点' },
|
||||
{ prop: 'os', label: '操作系统' },
|
||||
{ prop: 'browser', label: '浏览器' },
|
||||
{ prop: 'message', label: '登录信息', showOverflowTooltip: true },
|
||||
{ prop: 'login_time', label: '登录时间', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: '操作', width: 80, fixed: 'right', useSlot: true }
|
||||
{ prop: 'id', label: 'page.table.no', width: 100, align: 'center' },
|
||||
{ prop: 'username', label: 'page.table.loginUser' },
|
||||
{ prop: 'status', label: 'page.table.loginStatus', useSlot: true },
|
||||
{ prop: 'ip', label: 'page.table.loginIp' },
|
||||
{ prop: 'ip_location', label: 'page.table.operLocation' },
|
||||
{ prop: 'os', label: 'page.table.os' },
|
||||
{ prop: 'browser', label: 'page.table.browser' },
|
||||
{ prop: 'message', label: 'page.table.loginMessage', showOverflowTooltip: true },
|
||||
{ prop: 'login_time', label: 'page.table.loginTime', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: 'table.actions.operation', width: 80, fixed: 'right', useSlot: true }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -9,31 +9,31 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="登录用户" prop="username">
|
||||
<el-input v-model="formData.username" placeholder="请输入登录用户" clearable />
|
||||
<el-form-item :label="$t('page.search.loginUser')" prop="username">
|
||||
<el-input v-model="formData.username" :placeholder="$t('page.search.placeholderLoginUser')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="登录IP" prop="ip">
|
||||
<el-input v-model="formData.ip" placeholder="请输入登录IP" clearable />
|
||||
<el-form-item :label="$t('page.search.loginIp')" prop="ip">
|
||||
<el-input v-model="formData.ip" :placeholder="$t('page.search.placeholderLoginIp')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="登录状态" prop="status">
|
||||
<el-select v-model="formData.status" placeholder="请选择登录状态" clearable>
|
||||
<el-option label="成功" value="1" />
|
||||
<el-option label="失败" value="0" />
|
||||
<el-form-item :label="$t('page.search.loginStatus')" prop="status">
|
||||
<el-select v-model="formData.status" :placeholder="$t('page.search.placeholderLoginStatus')" clearable>
|
||||
<el-option :label="$t('table.searchBar.success')" value="1" />
|
||||
<el-option :label="$t('table.searchBar.failure')" value="0" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(12)" v-show="isExpanded">
|
||||
<el-form-item label="登录时间" prop="login_time">
|
||||
<el-form-item :label="$t('page.search.operTime')" prop="login_time">
|
||||
<el-date-picker
|
||||
v-model="formData.login_time"
|
||||
type="datetimerange"
|
||||
range-separator="至"
|
||||
start-placeholder="开始时间"
|
||||
end-placeholder="结束时间"
|
||||
:range-separator="$t('table.searchBar.rangeSeparator')"
|
||||
:start-placeholder="$t('table.searchBar.startTime')"
|
||||
:end-placeholder="$t('table.searchBar.endTime')"
|
||||
value-format="YYYY-MM-DD HH:mm:ss"
|
||||
clearable
|
||||
/>
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:delete-bin-5-line" />
|
||||
</template>
|
||||
删除
|
||||
{{ $t('table.actions.delete') }}
|
||||
</ElButton>
|
||||
</ElSpace>
|
||||
</template>
|
||||
@@ -102,14 +102,14 @@
|
||||
},
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'id', label: '编号', width: 100, align: 'center' },
|
||||
{ prop: 'username', label: '操作用户' },
|
||||
{ prop: 'service_name', label: '业务名称' },
|
||||
{ prop: 'router', label: '路由', minWidth: 180, showOverflowTooltip: true },
|
||||
{ prop: 'ip', label: '操作IP' },
|
||||
{ prop: 'ip_location', label: '操作地点' },
|
||||
{ prop: 'create_time', label: '操作时间', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: '操作', width: 100, fixed: 'right', useSlot: true }
|
||||
{ prop: 'id', label: 'page.table.no', width: 100, align: 'center' },
|
||||
{ prop: 'username', label: 'page.table.operator' },
|
||||
{ prop: 'service_name', label: 'page.table.serviceName' },
|
||||
{ prop: 'router', label: 'page.table.router', minWidth: 180, showOverflowTooltip: true },
|
||||
{ prop: 'ip', label: 'page.table.operIp' },
|
||||
{ prop: 'ip_location', label: 'page.table.operLocation' },
|
||||
{ prop: 'create_time', label: 'page.table.operTime', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: 'table.actions.operation', width: 100, fixed: 'right', useSlot: true }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -9,28 +9,28 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="操作用户" prop="username">
|
||||
<el-input v-model="formData.username" placeholder="请输入操作用户" clearable />
|
||||
<el-form-item :label="$t('page.search.operator')" prop="username">
|
||||
<el-input v-model="formData.username" :placeholder="$t('page.search.placeholderOperator')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="操作路由" prop="router">
|
||||
<el-input v-model="formData.router" placeholder="请输入操作路由" clearable />
|
||||
<el-form-item :label="$t('page.search.router')" prop="router">
|
||||
<el-input v-model="formData.router" :placeholder="$t('page.search.placeholderOperRouter')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="操作IP" prop="ip">
|
||||
<el-input v-model="formData.ip" placeholder="请输入操作IP" clearable />
|
||||
<el-form-item :label="$t('page.search.operIp')" prop="ip">
|
||||
<el-input v-model="formData.ip" :placeholder="$t('page.search.placeholderOperIp')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(12)" v-show="isExpanded">
|
||||
<el-form-item label="操作时间" prop="create_time">
|
||||
<el-form-item :label="$t('page.search.operTime')" prop="create_time">
|
||||
<el-date-picker
|
||||
v-model="formData.create_time"
|
||||
type="datetimerange"
|
||||
range-separator="至"
|
||||
start-placeholder="开始时间"
|
||||
end-placeholder="结束时间"
|
||||
:range-separator="$t('table.searchBar.rangeSeparator')"
|
||||
:start-placeholder="$t('table.searchBar.startTime')"
|
||||
:end-placeholder="$t('table.searchBar.endTime')"
|
||||
value-format="YYYY-MM-DD HH:mm:ss"
|
||||
clearable
|
||||
/>
|
||||
|
||||
@@ -300,9 +300,9 @@
|
||||
...configSearch.value
|
||||
},
|
||||
columnsFactory: () => [
|
||||
{ prop: 'id', label: '选中', width: 80, align: 'center', useSlot: true },
|
||||
{ prop: 'name', label: '配置名称', useHeaderSlot: true, width: 150 },
|
||||
{ prop: 'code', label: '配置标识', useHeaderSlot: true, width: 150 }
|
||||
{ prop: 'id', label: 'page.table.select', width: 80, align: 'center', useSlot: true },
|
||||
{ prop: 'name', label: 'page.table.configName', useHeaderSlot: true, width: 150 },
|
||||
{ prop: 'code', label: 'page.table.configKey', useHeaderSlot: true, width: 150 }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -160,12 +160,12 @@
|
||||
},
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'key', label: '配置标识' },
|
||||
{ prop: 'name', label: '配置标题' },
|
||||
{ prop: 'input_type', label: '组件类型', width: 100 },
|
||||
{ prop: 'sort', label: '排序', width: 100, sortable: true },
|
||||
{ prop: 'remark', label: '备注' },
|
||||
{ prop: 'operation', label: '操作', useSlot: true, width: 100 }
|
||||
{ prop: 'key', label: 'table.columns.system.configKey' },
|
||||
{ prop: 'name', label: 'table.columns.system.configTitle' },
|
||||
{ prop: 'input_type', label: 'table.columns.system.inputType', width: 100 },
|
||||
{ prop: 'sort', label: 'table.columns.common.sort', width: 100, sortable: true },
|
||||
{ prop: 'remark', label: 'table.columns.common.remark' },
|
||||
{ prop: 'operation', label: 'table.actions.operation', useSlot: true, width: 100 }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -12,14 +12,14 @@
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:add-fill" />
|
||||
</template>
|
||||
新增
|
||||
{{ $t('table.actions.add') }}
|
||||
</ElButton>
|
||||
<ElButton @click="toggleExpand" v-ripple>
|
||||
<template #icon>
|
||||
<ArtSvgIcon v-if="isExpanded" icon="ri:collapse-diagonal-line" />
|
||||
<ArtSvgIcon v-else icon="ri:expand-diagonal-line" />
|
||||
</template>
|
||||
{{ isExpanded ? '收起' : '展开' }}
|
||||
{{ isExpanded ? $t('table.searchBar.collapse') : $t('table.searchBar.expand') }}
|
||||
</ElButton>
|
||||
</ElSpace>
|
||||
</template>
|
||||
@@ -106,14 +106,14 @@
|
||||
core: {
|
||||
apiFn: api.list,
|
||||
columnsFactory: () => [
|
||||
{ prop: 'name', label: '部门名称', minWidth: 200 },
|
||||
{ prop: 'code', label: '部门编码', minWidth: 120 },
|
||||
{ prop: 'leader.username', label: '部门领导', minWidth: 120 },
|
||||
{ prop: 'remark', label: '描述', minWidth: 150, showOverflowTooltip: true },
|
||||
{ prop: 'sort', label: '排序', width: 100 },
|
||||
{ prop: 'status', label: '状态', saiType: 'dict', saiDict: 'data_status', width: 100 },
|
||||
{ prop: 'create_time', label: '创建日期', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: '操作', width: 100, fixed: 'right', useSlot: true }
|
||||
{ prop: 'name', label: 'page.table.deptName', minWidth: 200 },
|
||||
{ prop: 'code', label: 'page.table.deptCode', minWidth: 120 },
|
||||
{ prop: 'leader.username', label: 'page.table.leader', minWidth: 120 },
|
||||
{ prop: 'remark', label: 'table.columns.common.description', minWidth: 150, showOverflowTooltip: true },
|
||||
{ prop: 'sort', label: 'page.table.sort', width: 100 },
|
||||
{ prop: 'status', label: 'page.table.status', saiType: 'dict', saiDict: 'data_status', width: 100 },
|
||||
{ prop: 'create_time', label: 'page.table.createTime', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: 'table.actions.operation', width: 100, fixed: 'right', useSlot: true }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -9,18 +9,18 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="部门名称" prop="name">
|
||||
<el-input v-model="formData.name" placeholder="请输入部门名称" clearable />
|
||||
<el-form-item :label="$t('page.search.deptName')" prop="name">
|
||||
<el-input v-model="formData.name" :placeholder="$t('page.search.placeholderDeptName')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="部门编码" prop="code">
|
||||
<el-input v-model="formData.code" placeholder="请输入部门编码" clearable />
|
||||
<el-form-item :label="$t('page.search.deptCode')" prop="code">
|
||||
<el-input v-model="formData.code" :placeholder="$t('page.search.placeholderDeptCode')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="状态" prop="status">
|
||||
<sa-select v-model="formData.status" dict="data_status" clearable />
|
||||
<el-form-item :label="$t('page.search.status')" prop="status">
|
||||
<sa-select v-model="formData.status" dict="data_status" :placeholder="$t('page.search.searchSelectPlaceholder')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</sa-search-bar>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:add-fill" />
|
||||
</template>
|
||||
新增
|
||||
{{ $t('table.actions.add') }}
|
||||
</ElButton>
|
||||
<ElButton
|
||||
v-permission="'core:menu:destroy'"
|
||||
@@ -27,7 +27,7 @@
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:delete-bin-5-line" />
|
||||
</template>
|
||||
删除
|
||||
{{ $t('table.actions.delete') }}
|
||||
</ElButton>
|
||||
<ElButton @click="toggleExpand" v-ripple>
|
||||
<template #icon>
|
||||
@@ -129,10 +129,10 @@
|
||||
apiFn: api.list,
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'name', label: '菜单名称', minWidth: 150 },
|
||||
{ prop: 'name', label: 'page.table.menuName', minWidth: 150 },
|
||||
{
|
||||
prop: 'type',
|
||||
label: '菜单类型',
|
||||
label: 'page.table.menuType',
|
||||
align: 'center',
|
||||
saiType: 'dict',
|
||||
saiDict: 'menu_type',
|
||||
@@ -140,17 +140,17 @@
|
||||
},
|
||||
{
|
||||
prop: 'icon',
|
||||
label: '图标',
|
||||
label: 'page.table.icon',
|
||||
align: 'center',
|
||||
width: 80,
|
||||
formatter: (row: any) => {
|
||||
return h(ArtSvgIcon, { icon: row.icon })
|
||||
}
|
||||
},
|
||||
{ prop: 'code', label: '组件名称' },
|
||||
{ prop: 'code', label: 'page.table.component' },
|
||||
{
|
||||
prop: 'path',
|
||||
label: '路由',
|
||||
label: 'page.table.route',
|
||||
formatter: (row: any) => {
|
||||
if (row.type === 3) return ''
|
||||
return row.path || ''
|
||||
@@ -158,7 +158,7 @@
|
||||
},
|
||||
{
|
||||
prop: 'slug',
|
||||
label: '权限标识',
|
||||
label: 'page.table.auth',
|
||||
minWidth: 160,
|
||||
formatter: (row: any) => {
|
||||
if (row.type === 2) {
|
||||
@@ -170,9 +170,9 @@
|
||||
return ''
|
||||
}
|
||||
},
|
||||
{ prop: 'sort', label: '排序', width: 100 },
|
||||
{ prop: 'status', label: '状态', saiType: 'dict', saiDict: 'data_status', width: 100 },
|
||||
{ prop: 'operation', label: '操作', width: 140, fixed: 'right', useSlot: true }
|
||||
{ prop: 'sort', label: 'page.table.sort', width: 100 },
|
||||
{ prop: 'status', label: 'page.table.status', saiType: 'dict', saiDict: 'data_status', width: 100 },
|
||||
{ prop: 'operation', label: 'table.actions.operation', width: 140, fixed: 'right', useSlot: true }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -9,18 +9,18 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="菜单名称" prop="name">
|
||||
<el-input v-model="formData.name" placeholder="请输入菜单名称" clearable />
|
||||
<el-form-item :label="$t('page.search.menuName')" prop="name">
|
||||
<el-input v-model="formData.name" :placeholder="$t('page.search.placeholderMenuName')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="菜单路由" prop="path">
|
||||
<el-input v-model="formData.path" placeholder="请输入菜单路由" clearable />
|
||||
<el-form-item :label="$t('page.search.route')" prop="path">
|
||||
<el-input v-model="formData.path" :placeholder="$t('page.search.placeholderMenuRoute')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="状态" prop="status">
|
||||
<sa-select v-model="formData.status" dict="data_status" clearable />
|
||||
<el-form-item :label="$t('page.search.status')" prop="status">
|
||||
<sa-select v-model="formData.status" dict="data_status" :placeholder="$t('page.search.searchSelectPlaceholder')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</sa-search-bar>
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:add-fill" />
|
||||
</template>
|
||||
新增
|
||||
{{ $t('table.actions.add') }}
|
||||
</ElButton>
|
||||
<ElButton
|
||||
v-permission="'core:post:destroy'"
|
||||
@@ -23,7 +23,7 @@
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:delete-bin-5-line" />
|
||||
</template>
|
||||
删除
|
||||
{{ $t('table.actions.delete') }}
|
||||
</ElButton>
|
||||
<SaImport
|
||||
v-permission="'core:post:import'"
|
||||
@@ -116,14 +116,14 @@
|
||||
apiFn: api.list,
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'id', label: '编号', width: 100, align: 'center' },
|
||||
{ prop: 'name', label: '岗位名称', minWidth: 120 },
|
||||
{ prop: 'code', label: '岗位编码', minWidth: 120 },
|
||||
{ prop: 'remark', label: '描述', minWidth: 150, showOverflowTooltip: true },
|
||||
{ prop: 'sort', label: '排序', width: 100 },
|
||||
{ prop: 'status', label: '状态', saiType: 'dict', saiDict: 'data_status', width: 100 },
|
||||
{ prop: 'create_time', label: '创建日期', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: '操作', width: 100, fixed: 'right', useSlot: true }
|
||||
{ prop: 'id', label: 'table.columns.common.no', width: 100, align: 'center' },
|
||||
{ prop: 'name', label: 'page.table.postName', minWidth: 120 },
|
||||
{ prop: 'code', label: 'page.table.postCode', minWidth: 120 },
|
||||
{ prop: 'remark', label: 'table.columns.common.description', minWidth: 150, showOverflowTooltip: true },
|
||||
{ prop: 'sort', label: 'page.table.sort', width: 100 },
|
||||
{ prop: 'status', label: 'page.table.status', saiType: 'dict', saiDict: 'data_status', width: 100 },
|
||||
{ prop: 'create_time', label: 'page.table.createTime', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: 'table.actions.operation', width: 100, fixed: 'right', useSlot: true }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -9,18 +9,18 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="岗位名称" prop="name">
|
||||
<el-input v-model="formData.name" placeholder="请输入岗位名称" clearable />
|
||||
<el-form-item :label="$t('page.search.postName')" prop="name">
|
||||
<el-input v-model="formData.name" :placeholder="$t('page.search.placeholderPostName')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="岗位编码" prop="code">
|
||||
<el-input v-model="formData.code" placeholder="请输入岗位编码" clearable />
|
||||
<el-form-item :label="$t('page.search.postCode')" prop="code">
|
||||
<el-input v-model="formData.code" :placeholder="$t('page.search.placeholderPostCode')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="状态" prop="status">
|
||||
<sa-select v-model="formData.status" dict="data_status" clearable />
|
||||
<el-form-item :label="$t('page.search.status')" prop="status">
|
||||
<sa-select v-model="formData.status" dict="data_status" :placeholder="$t('page.search.searchSelectPlaceholder')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</sa-search-bar>
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:add-fill" />
|
||||
</template>
|
||||
新增
|
||||
{{ $t('table.actions.add') }}
|
||||
</ElButton>
|
||||
</ElSpace>
|
||||
</template>
|
||||
@@ -126,15 +126,15 @@
|
||||
core: {
|
||||
apiFn: api.list,
|
||||
columnsFactory: () => [
|
||||
{ prop: 'id', label: '编号', minWidth: 60, align: 'center' },
|
||||
{ prop: 'name', label: '角色名称', minWidth: 120 },
|
||||
{ prop: 'code', label: '角色编码', minWidth: 120 },
|
||||
{ prop: 'level', label: '角色级别', minWidth: 100, sortable: true },
|
||||
{ prop: 'remark', label: '角色描述', minWidth: 150, showOverflowTooltip: true },
|
||||
{ prop: 'sort', label: '排序', minWidth: 100 },
|
||||
{ prop: 'status', label: '状态', saiType: 'dict', saiDict: 'data_status' },
|
||||
{ prop: 'create_time', label: '创建日期', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: '操作', width: 140, fixed: 'right', useSlot: true }
|
||||
{ prop: 'id', label: 'table.columns.common.no', minWidth: 60, align: 'center' },
|
||||
{ prop: 'name', label: 'page.table.roleName', minWidth: 120 },
|
||||
{ prop: 'code', label: 'page.table.roleCode', minWidth: 120 },
|
||||
{ prop: 'level', label: 'page.table.level', minWidth: 100, sortable: true },
|
||||
{ prop: 'remark', label: 'page.table.roleRemark', minWidth: 150, showOverflowTooltip: true },
|
||||
{ prop: 'sort', label: 'table.columns.common.sort', minWidth: 100 },
|
||||
{ prop: 'status', label: 'page.table.status', saiType: 'dict', saiDict: 'data_status' },
|
||||
{ prop: 'create_time', label: 'page.table.createTime', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: 'table.actions.operation', width: 140, fixed: 'right', useSlot: true }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -9,18 +9,18 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="角色名称" prop="name">
|
||||
<el-input v-model="formData.name" placeholder="请输入角色名称" clearable />
|
||||
<el-form-item :label="$t('page.search.roleName')" prop="name">
|
||||
<el-input v-model="formData.name" :placeholder="$t('page.search.placeholderRoleName')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="角色编码" prop="code">
|
||||
<el-input v-model="formData.code" placeholder="请输入角色编码" clearable />
|
||||
<el-form-item :label="$t('page.search.roleCode')" prop="code">
|
||||
<el-input v-model="formData.code" :placeholder="$t('page.search.placeholderRoleCode')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="状态" prop="status">
|
||||
<sa-select v-model="formData.status" dict="data_status" clearable />
|
||||
<el-form-item :label="$t('page.search.status')" prop="status">
|
||||
<sa-select v-model="formData.status" dict="data_status" :placeholder="$t('page.search.searchSelectPlaceholder')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</sa-search-bar>
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:add-fill" />
|
||||
</template>
|
||||
新增
|
||||
{{ $t('table.actions.add') }}
|
||||
</ElButton>
|
||||
</ElSpace>
|
||||
</template>
|
||||
@@ -180,30 +180,30 @@
|
||||
...searchForm.value
|
||||
},
|
||||
columnsFactory: () => [
|
||||
{ type: 'index', width: 60, label: '序号' },
|
||||
{ type: 'index', width: 60, label: 'table.column.index' },
|
||||
{
|
||||
prop: 'avatar',
|
||||
label: '用户名',
|
||||
label: 'page.table.username',
|
||||
minWidth: 200,
|
||||
saiType: 'imageAndText',
|
||||
saiFirst: 'username',
|
||||
saiSecond: 'email'
|
||||
},
|
||||
{ prop: 'phone', label: '手机号', width: 120 },
|
||||
{ prop: 'phone', label: 'page.table.phone', width: 120 },
|
||||
{
|
||||
prop: 'dept_id',
|
||||
label: '部门',
|
||||
label: 'page.table.dept',
|
||||
minWidth: 150,
|
||||
sortable: true,
|
||||
formatter: (row: any) => row.depts?.name ?? ''
|
||||
},
|
||||
{ prop: 'status', label: '状态', width: 80, saiType: 'dict', saiDict: 'data_status' },
|
||||
{ prop: 'agent_id', label: '代理ID', width: 120, showOverflowTooltip: true },
|
||||
{ prop: 'dashboard', label: '首页', width: 100, saiType: 'dict', saiDict: 'dashboard' },
|
||||
{ prop: 'login_time', label: '上次登录', width: 170, sortable: true },
|
||||
{ prop: 'status', label: 'page.table.status', width: 80, saiType: 'dict', saiDict: 'data_status' },
|
||||
{ prop: 'agent_id', label: 'page.table.agentId', width: 120, showOverflowTooltip: true },
|
||||
{ prop: 'dashboard', label: 'page.table.dashboard', width: 100, saiType: 'dict', saiDict: 'dashboard' },
|
||||
{ prop: 'login_time', label: 'page.table.loginTime', width: 170, sortable: true },
|
||||
{
|
||||
prop: 'operation',
|
||||
label: '操作',
|
||||
label: 'table.actions.operation',
|
||||
width: 140,
|
||||
fixed: 'right',
|
||||
useSlot: true
|
||||
|
||||
@@ -9,18 +9,18 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="用户名" prop="username">
|
||||
<el-input v-model="formData.username" placeholder="请输入用户名" clearable />
|
||||
<el-form-item :label="$t('page.search.username')" prop="username">
|
||||
<el-input v-model="formData.username" :placeholder="$t('page.search.placeholderUsername')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="手机号" prop="phone">
|
||||
<el-input v-model="formData.phone" placeholder="请输入手机号" clearable />
|
||||
<el-form-item :label="$t('page.search.phone')" prop="phone">
|
||||
<el-input v-model="formData.phone" :placeholder="$t('page.search.placeholderPhone')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="状态" prop="status">
|
||||
<sa-select v-model="formData.status" dict="data_status" clearable />
|
||||
<el-form-item :label="$t('page.search.status')" prop="status">
|
||||
<sa-select v-model="formData.status" dict="data_status" :placeholder="$t('page.search.searchSelectPlaceholder')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</sa-search-bar>
|
||||
|
||||
@@ -217,11 +217,11 @@
|
||||
},
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'name', label: '表名称' },
|
||||
{ prop: 'comment', label: '表注释' },
|
||||
{ prop: 'engine', label: '引擎' },
|
||||
{ prop: 'collation', label: '编码' },
|
||||
{ prop: 'create_time', label: '创建时间' }
|
||||
{ prop: 'name', label: 'page.table.tableName' },
|
||||
{ prop: 'comment', label: 'page.table.tableComment' },
|
||||
{ prop: 'engine', label: 'page.table.engine' },
|
||||
{ prop: 'collation', label: 'page.table.collation' },
|
||||
{ prop: 'create_time', label: 'page.table.createTime' }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -195,14 +195,14 @@
|
||||
},
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection', width: 50 },
|
||||
{ prop: 'table_name', label: '表名称', minWidth: 180, align: 'left' },
|
||||
{ prop: 'table_comment', label: '表描述', minWidth: 150, align: 'left' },
|
||||
{ prop: 'template', label: '应用类型', minWidth: 120 },
|
||||
{ prop: 'namespace', label: '应用名称', minWidth: 120 },
|
||||
{ prop: 'stub', label: '模板类型', minWidth: 120 },
|
||||
{ prop: 'tpl_category', label: '生成类型', minWidth: 120, useSlot: true },
|
||||
{ prop: 'update_time', label: '更新时间', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: '操作', width: 220, fixed: 'right', useSlot: true }
|
||||
{ prop: 'table_name', label: 'page.table.tableName', minWidth: 180, align: 'left' },
|
||||
{ prop: 'table_comment', label: 'page.table.tableDesc', minWidth: 150, align: 'left' },
|
||||
{ prop: 'template', label: 'page.table.template', minWidth: 120 },
|
||||
{ prop: 'namespace', label: 'page.table.namespace', minWidth: 120 },
|
||||
{ prop: 'stub', label: 'page.table.stub', minWidth: 120 },
|
||||
{ prop: 'tpl_category', label: 'page.table.tplCategory', minWidth: 120, useSlot: true },
|
||||
{ prop: 'update_time', label: 'page.table.updateTime', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: 'table.actions.operation', width: 220, fixed: 'right', useSlot: true }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -8,13 +8,13 @@
|
||||
@search="handleSearch"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="表名称" prop="table_name">
|
||||
<el-input v-model="formData.table_name" placeholder="请输入数据表名称" clearable />
|
||||
<el-form-item :label="$t('page.search.tableName')" prop="table_name">
|
||||
<el-input v-model="formData.table_name" :placeholder="$t('page.search.placeholderTableName')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="数据源" prop="source">
|
||||
<el-input v-model="formData.source" placeholder="请输入数据源名称" clearable />
|
||||
<el-form-item :label="$t('page.search.placeholderDataSource')" prop="source">
|
||||
<el-input v-model="formData.source" :placeholder="$t('page.search.placeholderDataSource')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</sa-search-bar>
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:add-fill" />
|
||||
</template>
|
||||
新增
|
||||
{{ $t('table.actions.add') }}
|
||||
</ElButton>
|
||||
</ElSpace>
|
||||
</template>
|
||||
@@ -115,20 +115,20 @@
|
||||
core: {
|
||||
apiFn: api.list,
|
||||
columnsFactory: () => [
|
||||
{ prop: 'id', label: '编号', width: 100, align: 'center' },
|
||||
{ prop: 'name', label: '任务名称', minWidth: 120 },
|
||||
{ prop: 'id', label: 'page.table.no', width: 100, align: 'center' },
|
||||
{ prop: 'name', label: 'page.table.taskName', minWidth: 120 },
|
||||
{
|
||||
prop: 'type',
|
||||
label: '任务类型',
|
||||
label: 'page.table.taskType',
|
||||
saiType: 'dict',
|
||||
saiDict: 'crontab_task_type',
|
||||
minWidth: 120
|
||||
},
|
||||
{ prop: 'rule', label: '定时规则', minWidth: 140 },
|
||||
{ prop: 'target', label: '调用目标', minWidth: 200, showOverflowTooltip: true },
|
||||
{ prop: 'status', label: '状态', saiType: 'dict', saiDict: 'data_status', width: 100 },
|
||||
{ prop: 'update_time', label: '更新日期', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: '操作', width: 180, fixed: 'right', useSlot: true }
|
||||
{ prop: 'rule', label: 'page.table.rule', minWidth: 140 },
|
||||
{ prop: 'target', label: 'page.table.target', minWidth: 200, showOverflowTooltip: true },
|
||||
{ prop: 'status', label: 'page.table.status', saiType: 'dict', saiDict: 'data_status', width: 100 },
|
||||
{ prop: 'update_time', label: 'page.table.updateDate', width: 180, sortable: true },
|
||||
{ prop: 'operation', label: 'table.actions.operation', width: 180, fixed: 'right', useSlot: true }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -212,10 +212,10 @@
|
||||
},
|
||||
columnsFactory: () => [
|
||||
{ type: 'selection' },
|
||||
{ prop: 'create_time', label: '执行时间', sortable: true },
|
||||
{ prop: 'target', label: '调用目标' },
|
||||
{ prop: 'parameter', label: '任务参数' },
|
||||
{ prop: 'status', label: '执行状态', useSlot: true, width: 100 }
|
||||
{ prop: 'create_time', label: 'page.table.executeTime', sortable: true },
|
||||
{ prop: 'target', label: 'page.table.target' },
|
||||
{ prop: 'parameter', label: 'page.table.parameter' },
|
||||
{ prop: 'status', label: 'page.table.executeStatus', useSlot: true, width: 100 }
|
||||
]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -9,18 +9,18 @@
|
||||
@expand="handleExpand"
|
||||
>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="任务名称" prop="name">
|
||||
<el-input v-model="formData.name" placeholder="请输入任务名称" clearable />
|
||||
<el-form-item :label="$t('page.search.taskName')" prop="name">
|
||||
<el-input v-model="formData.name" :placeholder="$t('page.search.placeholderTaskName')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="任务类型" prop="type">
|
||||
<sa-select v-model="formData.type" dict="crontab_task_type" clearable />
|
||||
<el-form-item :label="$t('page.search.taskType')" prop="type">
|
||||
<sa-select v-model="formData.type" dict="crontab_task_type" :placeholder="$t('page.search.searchSelectPlaceholder')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col v-bind="setSpan(6)">
|
||||
<el-form-item label="状态" prop="status">
|
||||
<sa-select v-model="formData.status" dict="data_status" clearable />
|
||||
<el-form-item :label="$t('page.search.status')" prop="status">
|
||||
<sa-select v-model="formData.status" dict="data_status" :placeholder="$t('page.search.searchSelectPlaceholder')" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</sa-search-bar>
|
||||
|
||||
@@ -6,6 +6,7 @@ namespace app\api\controller;
|
||||
use support\Log;
|
||||
use support\Request;
|
||||
use support\Response;
|
||||
use support\think\Db;
|
||||
use app\api\logic\GameLogic;
|
||||
use app\api\logic\PlayStartLogic;
|
||||
use app\api\util\ReturnCode;
|
||||
@@ -162,6 +163,11 @@ class GameController extends BaseController
|
||||
return $this->success([], $msg);
|
||||
}
|
||||
|
||||
$lockName = 'play_start_' . $userId;
|
||||
$lockResult = Db::query('SELECT GET_LOCK(?, 30) as l', [$lockName]);
|
||||
if (empty($lockResult) || (int) ($lockResult[0]['l'] ?? 0) !== 1) {
|
||||
return $this->fail('请求过于频繁,请稍后再试', ReturnCode::BUSINESS_ERROR);
|
||||
}
|
||||
try {
|
||||
$logic = new PlayStartLogic();
|
||||
$data = $logic->run($userId, (int)$direction);
|
||||
@@ -245,6 +251,8 @@ class GameController extends BaseController
|
||||
$msg = '没有原因';
|
||||
}
|
||||
return $this->fail('服务超时,' . $msg);
|
||||
} finally {
|
||||
Db::execute('SELECT RELEASE_LOCK(?)', [$lockName]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -70,27 +70,31 @@ class PlayStartLogic
|
||||
|
||||
$lotteryService = LotteryService::getOrCreate($playerId);
|
||||
$ticketType = LotteryService::drawTicketType($paid, $free);
|
||||
$config = $ticketType === self::LOTTERY_TYPE_PAID
|
||||
? ($lotteryService->getConfigType0Id() ? DiceLotteryPoolConfig::find($lotteryService->getConfigType0Id()) : null)
|
||||
: ($lotteryService->getConfigType1Id() ? DiceLotteryPoolConfig::find($lotteryService->getConfigType1Id()) : null);
|
||||
// 未找到付费/免费对应配置时,统一回退到 type=0 的彩金池
|
||||
if (!$config) {
|
||||
$config = DiceLotteryPoolConfig::where('type', 0)->find();
|
||||
}
|
||||
if (!$config) {
|
||||
throw new ApiException('奖池配置不存在');
|
||||
$configType0 = DiceLotteryPoolConfig::where('type', 0)->find();
|
||||
$configType1 = DiceLotteryPoolConfig::where('type', 1)->find();
|
||||
if (!$configType0) {
|
||||
throw new ApiException('奖池配置不存在(需 type=0)');
|
||||
}
|
||||
// 杀分时使用 type=1 配置的权重;未杀分时付费用 type=0、免费用 type=1(无 type=1 时回退 type=0)
|
||||
$configForWeights = $ticketType === self::LOTTERY_TYPE_PAID
|
||||
? $configType0
|
||||
: ($configType1 ?? $configType0);
|
||||
|
||||
// 计算当前玩家在该彩金池中的累计盈利金额:当前中奖金额(含 BIGWIN)减去抽奖券费用 100
|
||||
// 玩家累计盈利:仅统计 lottery_config_id=type=0 的成功对局(中奖金额-100*局数)
|
||||
$playerQuery = DicePlayRecord::where('player_id', $playerId)
|
||||
->where('lottery_config_id', $config->id)
|
||||
->where('lottery_config_id', $configType0->id)
|
||||
->where('status', self::RECORD_STATUS_SUCCESS);
|
||||
$playerWinSum = (float) $playerQuery->sum('win_coin');
|
||||
$playerPlayCount = (int) $playerQuery->count();
|
||||
$playerProfitTotal = $playerWinSum - 100.0 * $playerPlayCount;
|
||||
$safetyLine = (int) ($config->safety_line ?? 0);
|
||||
// 玩家累计盈利金额达到或超过安全线时,按奖池 T*_weight 杀分;否则按玩家 T*_weight 抽档位
|
||||
$usePoolWeights = $playerProfitTotal >= $safetyLine;
|
||||
$safetyLine = (int) ($configType0->safety_line ?? 0);
|
||||
// 玩家累计盈利>=安全线时杀分:用 type=1 的 T*_weight,并记录 lottery_config_id=type=1 的 id;否则用玩家权重,记录对应配置 id
|
||||
$usePoolWeights = $playerProfitTotal >= $safetyLine && $configType1 !== null;
|
||||
if ($usePoolWeights) {
|
||||
$config = $configType1;
|
||||
} else {
|
||||
$config = $configForWeights;
|
||||
}
|
||||
|
||||
// 按档位 T1-T5 抽取后,从 DiceReward 表按当前方向取该档位数据,再按 weight 抽取一条得到 grid_number
|
||||
$rewardInstance = DiceReward::getCachedInstance();
|
||||
@@ -177,6 +181,7 @@ class PlayStartLogic
|
||||
|
||||
$record = null;
|
||||
$configId = (int) $config->id;
|
||||
$type0ConfigId = (int) $configType0->id;
|
||||
$rewardId = ($isWin === 1 && $superWinCoin > 0) ? 0 : $targetIndex; // 中豹子不记录原奖励配置 id
|
||||
$configName = (string) ($config->name ?? '');
|
||||
$adminId = ($player->admin_id ?? null) ? (int) $player->admin_id : null;
|
||||
@@ -185,6 +190,7 @@ class PlayStartLogic
|
||||
$playerId,
|
||||
$adminId,
|
||||
$configId,
|
||||
$type0ConfigId,
|
||||
$rewardId,
|
||||
$configName,
|
||||
$ticketType,
|
||||
@@ -250,20 +256,17 @@ class PlayStartLogic
|
||||
|
||||
$p->save();
|
||||
|
||||
// 玩家累计盈利底层仍使用 profit_amount 字段存储:每局按“当前中奖金额(含 BIGWIN) - 抽奖券费用 100”累加
|
||||
// 需确保表有 profit_amount 字段(见 db/dice_lottery_config_add_profit_amount.sql)
|
||||
// 玩家累计盈利累加在 type=0 彩金池上:每局按“当前中奖金额(含 BIGWIN) - 抽奖券费用 100”
|
||||
$perPlayProfit = $winCoin - 100.0;
|
||||
$addProfit = $perPlayProfit;
|
||||
try {
|
||||
DiceLotteryPoolConfig::where('id', $configId)->update([
|
||||
DiceLotteryPoolConfig::where('id', $type0ConfigId)->update([
|
||||
'profit_amount' => Db::raw('IFNULL(profit_amount,0) + ' . (float) $addProfit),
|
||||
]);
|
||||
} catch (\Throwable $e) {
|
||||
Log::warning('彩金池盈利累加失败,请确认表 dice_lottery_config 已存在 profit_amount 字段并执行 db/dice_lottery_config_add_profit_amount.sql', [
|
||||
'config_id' => $configId,
|
||||
Log::warning('彩金池盈利累加失败', [
|
||||
'config_id' => $type0ConfigId,
|
||||
'add_profit' => $addProfit,
|
||||
'real_ev' => $realEv,
|
||||
'bigwin_ev' => $bigWinRealEv,
|
||||
'message' => $e->getMessage(),
|
||||
]);
|
||||
}
|
||||
|
||||
@@ -31,83 +31,49 @@ class DiceLotteryPoolConfigLogic extends BaseLogic
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取当前彩金池:从 Redis 读取实例,profit_amount 每次从 DB 实时读取(表示玩家在该池子的累计盈利)
|
||||
* 获取当前彩金池(type=0)+ 杀分权重为 type=1 的只读展示
|
||||
* profit_amount 每次从 DB 实时读取;t1_weight~t5_weight 来自 type=1(杀分权重,不可在弹窗内修改)
|
||||
*
|
||||
* @return array{id:int,name:string,safety_line:int,t1_weight:int,t2_weight:int,t3_weight:int,t4_weight:int,t5_weight:int,profit_amount:float}
|
||||
* @return array{id:int,name:string,safety_line:int,t1_weight:int,...,t5_weight:int,profit_amount:float}
|
||||
*/
|
||||
public function getCurrentPool(): array
|
||||
{
|
||||
$cached = Cache::get(self::REDIS_KEY_CURRENT_POOL);
|
||||
if ($cached && is_string($cached)) {
|
||||
$data = json_decode($cached, true);
|
||||
if (is_array($data)) {
|
||||
$config = DiceLotteryPoolConfig::find($data['id'] ?? 0);
|
||||
$profit = 0.0;
|
||||
if ($config) {
|
||||
$profit = isset($config->profit_amount) ? (float) $config->profit_amount : (isset($config->ev) ? (float) $config->ev : 0.0);
|
||||
} else {
|
||||
$profit = (float) ($data['profit_amount'] ?? 0);
|
||||
}
|
||||
$data['profit_amount'] = $profit;
|
||||
return $data;
|
||||
}
|
||||
}
|
||||
$config = DiceLotteryPoolConfig::where('type', 0)->find();
|
||||
if (!$config) {
|
||||
$configType0 = DiceLotteryPoolConfig::where('type', 0)->find();
|
||||
if (!$configType0) {
|
||||
throw new ApiException('未找到 type=0 的奖池配置,请先创建');
|
||||
}
|
||||
$row = $config->toArray();
|
||||
$profitAmount = isset($row['profit_amount']) ? (float) $row['profit_amount'] : (isset($row['ev']) ? (float) $row['ev'] : 0.0);
|
||||
$configType1 = DiceLotteryPoolConfig::where('type', 1)->find();
|
||||
$row0 = $configType0->toArray();
|
||||
$profitAmount = isset($row0['profit_amount']) ? (float) $row0['profit_amount'] : (isset($row0['ev']) ? (float) $row0['ev'] : 0.0);
|
||||
$pool = [
|
||||
'id' => (int) $row['id'],
|
||||
'name' => (string) ($row['name'] ?? ''),
|
||||
'safety_line' => (int) ($row['safety_line'] ?? 0),
|
||||
't1_weight' => (int) ($row['t1_weight'] ?? 0),
|
||||
't2_weight' => (int) ($row['t2_weight'] ?? 0),
|
||||
't3_weight' => (int) ($row['t3_weight'] ?? 0),
|
||||
't4_weight' => (int) ($row['t4_weight'] ?? 0),
|
||||
't5_weight' => (int) ($row['t5_weight'] ?? 0),
|
||||
'id' => (int) $row0['id'],
|
||||
'name' => (string) ($row0['name'] ?? ''),
|
||||
'safety_line' => (int) ($row0['safety_line'] ?? 0),
|
||||
'profit_amount' => $profitAmount,
|
||||
];
|
||||
Cache::set(self::REDIS_KEY_CURRENT_POOL, json_encode($pool), self::EXPIRE);
|
||||
$row1 = $configType1 ? $configType1->toArray() : [];
|
||||
$pool['t1_weight'] = (int) ($row1['t1_weight'] ?? 0);
|
||||
$pool['t2_weight'] = (int) ($row1['t2_weight'] ?? 0);
|
||||
$pool['t3_weight'] = (int) ($row1['t3_weight'] ?? 0);
|
||||
$pool['t4_weight'] = (int) ($row1['t4_weight'] ?? 0);
|
||||
$pool['t5_weight'] = (int) ($row1['t5_weight'] ?? 0);
|
||||
return $pool;
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新当前彩金池:仅允许修改 safety_line、t1_weight~t5_weight,不修改 profit_amount
|
||||
* 同时更新 Redis 与 DB 中 type=0 的记录
|
||||
* 更新当前彩金池:仅允许修改 type=0 的 safety_line(杀分权重来自 type=1,不可在此接口修改)
|
||||
*
|
||||
* @param array{safety_line?:int,t1_weight?:int,t2_weight?:int,t3_weight?:int,t4_weight?:int,t5_weight?:int} $data
|
||||
* @param array{safety_line?:int} $data
|
||||
*/
|
||||
public function updateCurrentPool(array $data): void
|
||||
{
|
||||
$pool = $this->getCurrentPool();
|
||||
$id = (int) $pool['id'];
|
||||
$config = DiceLotteryPoolConfig::find($id);
|
||||
if (!$config) {
|
||||
throw new ApiException('奖池配置不存在');
|
||||
}
|
||||
$allow = ['safety_line', 't1_weight', 't2_weight', 't3_weight', 't4_weight', 't5_weight'];
|
||||
$update = [];
|
||||
foreach ($allow as $k) {
|
||||
if (array_key_exists($k, $data)) {
|
||||
if ($k === 'safety_line') {
|
||||
$update[$k] = (int) $data[$k];
|
||||
} else {
|
||||
$update[$k] = max(0, min(100, (int) $data[$k]));
|
||||
}
|
||||
}
|
||||
}
|
||||
if (empty($update)) {
|
||||
if (!array_key_exists('safety_line', $data)) {
|
||||
return;
|
||||
}
|
||||
DiceLotteryPoolConfig::where('id', $id)->update($update);
|
||||
$pool = array_merge($pool, $update);
|
||||
$refreshed = DiceLotteryPoolConfig::find($id);
|
||||
$pool['profit_amount'] = $refreshed && (isset($refreshed->profit_amount) || isset($refreshed->ev))
|
||||
? (float) ($refreshed->profit_amount ?? $refreshed->ev)
|
||||
: (float) ($pool['profit_amount'] ?? 0);
|
||||
Cache::set(self::REDIS_KEY_CURRENT_POOL, json_encode($pool), self::EXPIRE);
|
||||
$safetyLine = (int) $data['safety_line'];
|
||||
DiceLotteryPoolConfig::where('id', $id)->update(['safety_line' => $safetyLine]);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user