From dfb37dd33acd636181bf515b23e06e06805456e2 Mon Sep 17 00:00:00 2001 From: zhenhui <1276357500@qq.com> Date: Thu, 4 Jun 2026 12:21:57 +0800 Subject: [PATCH] =?UTF-8?q?1.=E6=96=B0=E5=A2=9E=E9=BB=98=E8=AE=A4=E5=BD=A9?= =?UTF-8?q?=E9=87=91=E6=B1=A0=E9=85=8D=E7=BD=AE=202.=E4=BC=98=E5=8C=96?= =?UTF-8?q?=E5=85=B3=E8=81=94=E5=BD=A9=E9=87=91=E6=B1=A0=E9=85=8D=E7=BD=AE?= =?UTF-8?q?=E7=9A=84=E5=90=8D=E7=A7=B0=E6=98=BE=E7=A4=BA=203.=E4=BC=98?= =?UTF-8?q?=E5=8C=96=E4=B8=80=E9=94=AE=E6=B5=8B=E8=AF=95=E6=9D=83=E9=87=8D?= =?UTF-8?q?=204.=E4=BC=98=E5=8C=96=E5=BA=95=E6=B3=A8=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../locales/langs/en/dice/ante_config.json | 2 + .../langs/en/dice/lottery_pool_config.json | 10 +- .../src/locales/langs/en/dice/player.json | 2 + .../src/locales/langs/en/dice/reward.json | 6 +- .../langs/en/dice/reward_config_record.json | 8 +- .../locales/langs/zh/dice/ante_config.json | 2 + .../langs/zh/dice/lottery_pool_config.json | 14 +- .../src/locales/langs/zh/dice/player.json | 2 + .../src/locales/langs/zh/dice/reward.json | 6 +- .../langs/zh/dice/reward_config_record.json | 8 +- .../ante_config/index/modules/edit-dialog.vue | 20 ++- .../dice/api/lottery_pool_config/index.ts | 44 +++--- .../plugin/dice/api/play_record/index.ts | 9 +- .../src/views/plugin/dice/api/player/index.ts | 10 +- .../dice/lottery_pool_config/index/index.vue | 27 ++-- .../index/modules/edit-dialog.vue | 13 +- .../plugin/dice/play_record/index/index.vue | 4 +- .../play_record/index/modules/edit-dialog.vue | 8 +- .../dice/play_record_test/index/index.vue | 4 +- .../index/modules/table-search.vue | 24 ++-- .../views/plugin/dice/player/index/index.vue | 12 +- .../dice/player/index/modules/edit-dialog.vue | 11 +- .../player/index/modules/table-search.vue | 3 +- .../index/modules/weight-test-dialog.vue | 135 ++++++++++++++---- .../dice/reward_config_record/index/index.vue | 39 ++++- .../index/modules/detail-drawer.vue | 71 ++++++++- .../plugin/dice/utils/lotteryPoolDisplay.ts | 99 +++++++++++++ server/app/api/logic/PlayStartLogic.php | 31 +++- .../DiceLotteryPoolConfigController.php | 20 +-- .../play_record/DicePlayRecordController.php | 10 +- .../player/DicePlayerController.php | 10 +- .../reward/DiceRewardController.php | 1 + .../logic/ante_config/DiceAnteConfigLogic.php | 17 +++ .../app/dice/logic/reward/DiceRewardLogic.php | 107 ++++++++++---- .../DiceRewardConfigRecordLogic.php | 25 +++- .../DiceLotteryPoolConfig.php | 56 +++++++- .../dice/model/play_record/DicePlayRecord.php | 8 +- server/app/dice/model/player/DicePlayer.php | 46 ++++-- .../dice/service/DiceChannelConfigService.php | 92 ++++++++++++ .../DiceLotteryPoolConfigValidate.php | 6 + 40 files changed, 845 insertions(+), 177 deletions(-) create mode 100644 saiadmin-artd/src/views/plugin/dice/utils/lotteryPoolDisplay.ts diff --git a/saiadmin-artd/src/locales/langs/en/dice/ante_config.json b/saiadmin-artd/src/locales/langs/en/dice/ante_config.json index 2130a3c..58f31af 100644 --- a/saiadmin-artd/src/locales/langs/en/dice/ante_config.json +++ b/saiadmin-artd/src/locales/langs/en/dice/ante_config.json @@ -27,6 +27,8 @@ "labelIsDefault": "Default Ante", "placeholderName": "Please enter name", "placeholderTitle": "Please enter title", + "placeholderNameAuto": "Auto from multiplier, e.g. x5", + "placeholderTitleAuto": "Auto from multiplier, e.g. x5", "ruleNameRequired": "Please enter name", "ruleTitleRequired": "Please enter title", "ruleMultRequired": "Please enter ante multiplier", diff --git a/saiadmin-artd/src/locales/langs/en/dice/lottery_pool_config.json b/saiadmin-artd/src/locales/langs/en/dice/lottery_pool_config.json index b846d73..fa20884 100644 --- a/saiadmin-artd/src/locales/langs/en/dice/lottery_pool_config.json +++ b/saiadmin-artd/src/locales/langs/en/dice/lottery_pool_config.json @@ -5,11 +5,13 @@ "dialogTitleEdit": "Edit Lottery Pool Config", "placeholderName": "Please enter name", "placeholderRemark": "Please enter remark", + "placeholderPoolName": "Pool display name, e.g. Normal pool", + "placeholderConfigNote": "Optional notes about this pool", "poolType": "Pool Type", "placeholderPoolType": "Please select pool type", "poolTypeNormal": "Normal", "poolTypeFree": "Free", - "poolTypeKill": "Kill", + "poolTypeKill": "Force score kill", "poolTypeT1": "T1 High", "safetyLine": "Safety Line", "t1Weight": "T1 Pool Weight (%)", @@ -59,11 +61,13 @@ "placeholderPoolType": "Please select pool type", "poolTypeNormal": "Normal", "poolTypeFree": "Free", - "poolTypeKill": "Force Kill", + "poolTypeKill": "Force Score Kill", "poolTypeT1": "T1 High Rate" }, "table": { - "name": "Name", + "name": "Code", + "poolName": "Pool Name", + "configNote": "Remark", "poolType": "Pool Type", "safetyLine": "Safety Line", "safetyLineNotUsed": "Not used for kill", diff --git a/saiadmin-artd/src/locales/langs/en/dice/player.json b/saiadmin-artd/src/locales/langs/en/dice/player.json index 5605f44..3c4cd0c 100644 --- a/saiadmin-artd/src/locales/langs/en/dice/player.json +++ b/saiadmin-artd/src/locales/langs/en/dice/player.json @@ -22,6 +22,8 @@ "placeholderLotteryPool": "Leave empty for custom weights below, or select pool", "currentConfig": "Current Config", "configLabelName": "Name", + "configLabelPoolName": "Pool name", + "configLabelCode": "Code", "configLabelType": "Type", "configLabelWeights": "T1–T5 Weights", "configLabelRemark": "Remark", diff --git a/saiadmin-artd/src/locales/langs/en/dice/reward.json b/saiadmin-artd/src/locales/langs/en/dice/reward.json index d05dd8a..25c2229 100644 --- a/saiadmin-artd/src/locales/langs/en/dice/reward.json +++ b/saiadmin-artd/src/locales/langs/en/dice/reward.json @@ -73,8 +73,10 @@ "labelLotteryTypeFree": "Free tier pool", "labelAnte": "Ante", "placeholderAnte": "Select ante config", - "placeholderPaidPool": "Leave empty for custom tier odds below (default: default)", - "placeholderFreePool": "Leave empty for custom tier odds below (default: free pool)", + "anteRandomOption": "Random (pick from channel ante configs)", + "placeholderPaidPool": "Leave empty to set T1–T5 weights manually", + "placeholderFreePool": "Leave empty to set T1–T5 weights manually", + "selectedPoolHint": "Selected pool: {name}", "tierProbHint": "Custom tier odds (T1–T5), each 0–100%, sum of five must not exceed 100%", "tierFieldLabel": "Tier {tier} (%)", "tierSumError": "Current sum of five tiers is {sum}%, cannot exceed 100%", diff --git a/saiadmin-artd/src/locales/langs/en/dice/reward_config_record.json b/saiadmin-artd/src/locales/langs/en/dice/reward_config_record.json index cc5eeff..3ca97da 100644 --- a/saiadmin-artd/src/locales/langs/en/dice/reward_config_record.json +++ b/saiadmin-artd/src/locales/langs/en/dice/reward_config_record.json @@ -17,6 +17,8 @@ "chainModeNo": "No", "paidPlannedSpins": "Planned paid spins", "ante": "Ante", + "anteRandom": "Random", + "testSafetyLine": "Safety line", "playAgainCount": "Play-again count", "progressDraws": "{over} done", "progressFailed": "{over} before fail", @@ -51,11 +53,13 @@ "testCountProgress": "In progress: {over} done", "testCountFailed": "{over} before failure", "chainModeLabel": "Chain play-again", + "killModeOff": "Kill mode off", "paidPlannedSpins": "Planned paid spins", + "testSafetyLine": "Test safety line", "createTime": "Created at", "admin": "Operator", - "paidPoolId": "Paid lottery pool config ID", - "freePoolId": "Free lottery pool config ID", + "paidPoolId": "Paid lottery pool", + "freePoolId": "Free lottery pool", "bigwinSnapshot": "BIGWIN weight snapshot", "sectionPaidTier": "Paid draw tier odds (T1–T5, used in test)", "sectionFreeTier": "Free draw tier odds (T1–T5, used in test)", diff --git a/saiadmin-artd/src/locales/langs/zh/dice/ante_config.json b/saiadmin-artd/src/locales/langs/zh/dice/ante_config.json index 4d33405..6862106 100644 --- a/saiadmin-artd/src/locales/langs/zh/dice/ante_config.json +++ b/saiadmin-artd/src/locales/langs/zh/dice/ante_config.json @@ -27,6 +27,8 @@ "labelIsDefault": "默认底注", "placeholderName": "请输入名称", "placeholderTitle": "请输入标题", + "placeholderNameAuto": "随底注倍率自动生成,如 x5", + "placeholderTitleAuto": "随底注倍率自动生成,如 x5", "ruleNameRequired": "请输入名称", "ruleTitleRequired": "请输入标题", "ruleMultRequired": "请输入底注倍率", diff --git a/saiadmin-artd/src/locales/langs/zh/dice/lottery_pool_config.json b/saiadmin-artd/src/locales/langs/zh/dice/lottery_pool_config.json index e319ac0..0015a17 100644 --- a/saiadmin-artd/src/locales/langs/zh/dice/lottery_pool_config.json +++ b/saiadmin-artd/src/locales/langs/zh/dice/lottery_pool_config.json @@ -5,11 +5,14 @@ "dialogTitleEdit": "编辑色子奖池配置", "placeholderName": "请输入名称", "placeholderRemark": "请输入备注", + "placeholderPoolName": "请输入奖池名称,如:正常池", + "placeholderConfigNote": "选填,用于说明该奖池用途或规则", "poolType": "奖池类型", + "poolName": "奖池名称", "placeholderPoolType": "请选择奖池类型", "poolTypeNormal": "正常", "poolTypeFree": "免费", - "poolTypeKill": "强制杀猪", + "poolTypeKill": "强制杀分", "poolTypeT1": "T1高倍率", "safetyLine": "安全线", "t1Weight": "T1池权重(%)", @@ -29,7 +32,7 @@ "tierRuleContent": "比较对象为 default 奖池的 profit_amount(非单个玩家盈利)。当 profit_amount 低于安全线或未开启杀分时,付费按玩家 T*_weight 抽档;当 profit_amount 高于或等于安全线且已开启杀分时,付费按 killScore 奖池抽档。免费抽奖始终按本渠道 name=free 奖池权重(无 free 时回退 default),与安全线无关。", "enableKillScore": "开启杀分", "killScoreWeights": "杀分权重(killScore)", - "killWeightNote": "杀分权重请在列表中编辑 name=killScore(强制杀猪)记录;本弹窗仅配置 default 奖池的安全线与杀分开关。", + "killWeightNote": "杀分权重请在列表中编辑 name=killScore(强制杀分)记录;本弹窗仅配置 default 奖池的安全线与杀分开关。", "btnResetProfit": "重置彩金池累计盈利", "btnSaveSafetyLine": "保存安全线与杀分开关", "safetyLineDefaultOnlyHint": "仅 name=default(正常)奖池的安全线参与杀分判定;其它奖池类型请勿在此配置安全线。", @@ -55,15 +58,18 @@ }, "search": { "poolType": "奖池类型", + "poolName": "奖池名称", "placeholderName": "请输入名称", "placeholderPoolType": "请选择奖池类型", "poolTypeNormal": "正常", "poolTypeFree": "免费", - "poolTypeKill": "强制杀猪", + "poolTypeKill": "强制杀分", "poolTypeT1": "T1高倍率" }, "table": { - "name": "名称", + "name": "内部标识", + "poolName": "奖池名称", + "configNote": "备注", "poolType": "奖池类型", "safetyLine": "安全线", "safetyLineNotUsed": "不参与杀分判定", diff --git a/saiadmin-artd/src/locales/langs/zh/dice/player.json b/saiadmin-artd/src/locales/langs/zh/dice/player.json index cb0b0d1..3738a4e 100644 --- a/saiadmin-artd/src/locales/langs/zh/dice/player.json +++ b/saiadmin-artd/src/locales/langs/zh/dice/player.json @@ -22,6 +22,8 @@ "placeholderLotteryPool": "留空则使用下方自定义权重,或选择彩金池", "currentConfig": "当前配置", "configLabelName": "名称", + "configLabelPoolName": "奖池名称", + "configLabelCode": "内部标识", "configLabelType": "类型", "configLabelWeights": "T1~T5 权重", "configLabelRemark": "备注", diff --git a/saiadmin-artd/src/locales/langs/zh/dice/reward.json b/saiadmin-artd/src/locales/langs/zh/dice/reward.json index efd4bbb..e981806 100644 --- a/saiadmin-artd/src/locales/langs/zh/dice/reward.json +++ b/saiadmin-artd/src/locales/langs/zh/dice/reward.json @@ -73,8 +73,10 @@ "labelLotteryTypeFree": "免费档位奖池", "labelAnte": "底注", "placeholderAnte": "请选择底注配置", - "placeholderPaidPool": "不选则下方自定义档位概率(默认 default)", - "placeholderFreePool": "不选则下方自定义档位概率(默认 free 免费奖池)", + "anteRandomOption": "随机(从当前渠道底注配置中抽取)", + "placeholderPaidPool": "不选则下方手动设定 T1–T5 档位权重", + "placeholderFreePool": "不选则下方手动设定 T1–T5 档位权重", + "selectedPoolHint": "已选奖池:{name}", "tierProbHint": "自定义档位概率(T1~T5),每档 0-100%,五档之和不能超过 100%", "tierFieldLabel": "档位 {tier}(%)", "tierSumError": "当前五档之和为 {sum}%,不能超过 100%", diff --git a/saiadmin-artd/src/locales/langs/zh/dice/reward_config_record.json b/saiadmin-artd/src/locales/langs/zh/dice/reward_config_record.json index 0fb6ebe..98d39d4 100644 --- a/saiadmin-artd/src/locales/langs/zh/dice/reward_config_record.json +++ b/saiadmin-artd/src/locales/langs/zh/dice/reward_config_record.json @@ -17,6 +17,8 @@ "chainModeNo": "否", "paidPlannedSpins": "计划付费次数", "ante": "底注", + "anteRandom": "随机", + "testSafetyLine": "安全线", "playAgainCount": "再来一次次数", "progressDraws": "已完成 {over} 次", "progressFailed": "失败前 {over} 次", @@ -51,11 +53,13 @@ "testCountProgress": "进行中:已完成 {over} 次", "testCountFailed": "失败前 {over} 次", "chainModeLabel": "链式再来一次", + "killModeOff": "未开启杀分", "paidPlannedSpins": "计划付费次数", + "testSafetyLine": "测试安全线", "createTime": "创建时间", "admin": "执行管理员", - "paidPoolId": "付费奖池配置ID", - "freePoolId": "免费奖池配置ID", + "paidPoolId": "付费彩金池", + "freePoolId": "免费彩金池", "bigwinSnapshot": "BIGWIN 权重快照", "sectionPaidTier": "付费抽奖档位概率(T1-T5,测试时使用)", "sectionFreeTier": "免费抽奖档位概率(T1-T5,测试时使用)", diff --git a/saiadmin-artd/src/views/plugin/dice/ante_config/index/modules/edit-dialog.vue b/saiadmin-artd/src/views/plugin/dice/ante_config/index/modules/edit-dialog.vue index 6edde9a..b29bf37 100644 --- a/saiadmin-artd/src/views/plugin/dice/ante_config/index/modules/edit-dialog.vue +++ b/saiadmin-artd/src/views/plugin/dice/ante_config/index/modules/edit-dialog.vue @@ -9,13 +9,19 @@ > - + - + - + @@ -87,6 +93,13 @@ const formData = reactive({ ...initialFormData }) + function syncNameTitleFromMult() { + const mult = Number(formData.mult) || 1 + const label = `x${mult}` + formData.name = label + formData.title = label + } + watch( () => props.modelValue, async (newVal) => { @@ -99,6 +112,7 @@ if (typeof props.data.title === 'string') formData.title = props.data.title formData.mult = Number(props.data.mult ?? 1) || 1 formData.is_default = Number(props.data.is_default ?? 0) === 1 ? 1 : 0 + syncNameTitleFromMult() } ) diff --git a/saiadmin-artd/src/views/plugin/dice/api/lottery_pool_config/index.ts b/saiadmin-artd/src/views/plugin/dice/api/lottery_pool_config/index.ts index c81f9ab..b862b27 100644 --- a/saiadmin-artd/src/views/plugin/dice/api/lottery_pool_config/index.ts +++ b/saiadmin-artd/src/views/plugin/dice/api/lottery_pool_config/index.ts @@ -1,4 +1,16 @@ import request from '@/utils/http' +import { + normalizeLotteryPoolOption, + type LotteryPoolOption +} from '@/views/plugin/dice/utils/lotteryPoolDisplay' + +export type LotteryPoolConfigOption = LotteryPoolOption & { + t1_weight: number + t2_weight: number + t3_weight: number + t4_weight: number + t5_weight: number +} /** * 色子奖池配置 API 接口 @@ -20,32 +32,24 @@ export default { * 获取 DiceLotteryPoolConfig 列表数据,含 id、name、t1_weight~t5_weight,用于一键测试权重档位类型下拉 * name 映射:default=原 type=0,killScore=原 type=1,up=原 type=2 */ - async getOptions(params?: Record): Promise< - Array<{ - id: number - name: string - t1_weight: number - t2_weight: number - t3_weight: number - t4_weight: number - t5_weight: number - }> - > { + async getOptions(params?: Record): Promise { const res = await request.get({ url: '/core/dice/lottery_pool_config/DiceLotteryPoolConfig/getOptions', params }) const rows = Array.isArray(res) ? res : (Array.isArray((res as any)?.data) ? (res as any).data : []) if (!Array.isArray(rows)) return [] - return rows.map((r: any) => ({ - id: Number(r.id), - name: String(r.name ?? r.id ?? ''), - t1_weight: Number(r.t1_weight ?? 0), - t2_weight: Number(r.t2_weight ?? 0), - t3_weight: Number(r.t3_weight ?? 0), - t4_weight: Number(r.t4_weight ?? 0), - t5_weight: Number(r.t5_weight ?? 0) - })) + return rows.map((r: Record) => { + const base = normalizeLotteryPoolOption(r) + return { + ...base, + t1_weight: Number(r.t1_weight ?? 0), + t2_weight: Number(r.t2_weight ?? 0), + t3_weight: Number(r.t3_weight ?? 0), + t4_weight: Number(r.t4_weight ?? 0), + t5_weight: Number(r.t5_weight ?? 0) + } + }) }, /** diff --git a/saiadmin-artd/src/views/plugin/dice/api/play_record/index.ts b/saiadmin-artd/src/views/plugin/dice/api/play_record/index.ts index b6ea1ef..555a126 100644 --- a/saiadmin-artd/src/views/plugin/dice/api/play_record/index.ts +++ b/saiadmin-artd/src/views/plugin/dice/api/play_record/index.ts @@ -1,4 +1,5 @@ import request from '@/utils/http' +import { normalizeLotteryPoolOption, type LotteryPoolOption } from '@/views/plugin/dice/utils/lotteryPoolDisplay' /** * 玩家抽奖记录 API接口 @@ -59,11 +60,13 @@ export default { }) }, - /** 获取彩金池配置选项(id、name) */ - getLotteryConfigOptions(params?: Record) { - return request.get<{ id: number; name: string }[]>({ + /** 获取彩金池配置选项(含奖池名称) */ + async getLotteryConfigOptions(params?: Record): Promise { + const res = await request.get({ url: '/core/dice/play_record/DicePlayRecord/getLotteryConfigOptions', params }) + const rows = (Array.isArray(res) ? res : (res?.data ?? [])) as Array> + return rows.map((r) => normalizeLotteryPoolOption(r)) } } diff --git a/saiadmin-artd/src/views/plugin/dice/api/player/index.ts b/saiadmin-artd/src/views/plugin/dice/api/player/index.ts index 75eef36..702246e 100644 --- a/saiadmin-artd/src/views/plugin/dice/api/player/index.ts +++ b/saiadmin-artd/src/views/plugin/dice/api/player/index.ts @@ -1,4 +1,5 @@ import request from '@/utils/http' +import { normalizeLotteryPoolOption } from '@/views/plugin/dice/utils/lotteryPoolDisplay' /** * 大富翁-玩家 API接口 @@ -84,16 +85,15 @@ export default { }, /** - * 获取彩金池配置选项(DiceLotteryPoolConfig.id、name),供 lottery_config_id 下拉使用 - * @returns [ { id, name } ] + * 获取彩金池配置选项,供 lottery_config_id 下拉使用(含奖池名称 display_name) */ - async getLotteryConfigOptions(params?: Record): Promise> { + async getLotteryConfigOptions(params?: Record) { const res = await request.get({ url: '/core/dice/player/DicePlayer/getLotteryConfigOptions', params }) - const rows = (Array.isArray(res) ? res : (res?.data ?? [])) as Array<{ id: number; name: string }> - return rows.map((r) => ({ id: Number(r.id), name: String(r.name ?? r.id ?? '') })) + const rows = (Array.isArray(res) ? res : (res?.data ?? [])) as Array> + return rows.map((r) => normalizeLotteryPoolOption(r)) }, /** diff --git a/saiadmin-artd/src/views/plugin/dice/lottery_pool_config/index/index.vue b/saiadmin-artd/src/views/plugin/dice/lottery_pool_config/index/index.vue index b9f2a11..8c807cc 100644 --- a/saiadmin-artd/src/views/plugin/dice/lottery_pool_config/index/index.vue +++ b/saiadmin-artd/src/views/plugin/dice/lottery_pool_config/index/index.vue @@ -87,14 +87,10 @@ getData() } - // 奖池类型展示:按 name 映射 - const typeFormatter = (row: Record) => { - const n = String(row.name ?? '') - if (n === 'default') return t('page.search.poolTypeNormal') - if (n === 'free') return t('page.search.poolTypeFree') - if (n === 'killScore') return t('page.search.poolTypeKill') - if (n === 'up') return t('page.search.poolTypeT1') - return n || '-' + const poolNameFormatter = (row: Record) => { + const remark = String(row.remark ?? '').trim() + if (remark) return remark + return String(row.name ?? '').trim() || '-' } // 权重列带 % @@ -132,8 +128,19 @@ core: { apiFn: api.list, columnsFactory: () => [ - { prop: 'name', label: 'page.table.name', align: 'center' }, - { prop: 'name', label: 'page.table.poolType', width: 100, align: 'center', formatter: typeFormatter }, + { prop: 'remark', label: 'page.table.poolName', minWidth: 120, align: 'center', formatter: poolNameFormatter }, + { + prop: 'config_note', + label: 'page.table.configNote', + minWidth: 140, + align: 'center', + showOverflowTooltip: true, + formatter: (row: Record) => { + const v = String(row.config_note ?? '').trim() + return v || '-' + } + }, + { prop: 'name', label: 'page.table.name', width: 110, align: 'center' }, { prop: 'safety_line', label: 'page.table.safetyLine', diff --git a/saiadmin-artd/src/views/plugin/dice/lottery_pool_config/index/modules/edit-dialog.vue b/saiadmin-artd/src/views/plugin/dice/lottery_pool_config/index/modules/edit-dialog.vue index 6201f55..07654cd 100644 --- a/saiadmin-artd/src/views/plugin/dice/lottery_pool_config/index/modules/edit-dialog.vue +++ b/saiadmin-artd/src/views/plugin/dice/lottery_pool_config/index/modules/edit-dialog.vue @@ -15,12 +15,20 @@ :disabled="dialogType === 'edit'" /> - + + + + @@ -159,6 +167,7 @@ dept_id: undefined as number | undefined, name: '', remark: '', + config_note: '', safety_line: 0 as number, t1_weight: 0 as number, t2_weight: 0 as number, diff --git a/saiadmin-artd/src/views/plugin/dice/play_record/index/index.vue b/saiadmin-artd/src/views/plugin/dice/play_record/index/index.vue index 0b18093..cfc2d85 100644 --- a/saiadmin-artd/src/views/plugin/dice/play_record/index/index.vue +++ b/saiadmin-artd/src/views/plugin/dice/play_record/index/index.vue @@ -143,6 +143,7 @@ import api from '../../api/play_record/index' import TableSearch from './modules/table-search.vue' import EditDialog from './modules/edit-dialog.vue' + import { lotteryPoolRowLabel } from '@/views/plugin/dice/utils/lotteryPoolDisplay' const { t } = useI18n() // 搜索表单 @@ -177,8 +178,7 @@ const usernameFormatter = (row: Record) => row?.dicePlayer?.username ?? row?.player_id ?? '-' - const lotteryConfigNameFormatter = (row: Record) => - row?.diceLotteryPoolConfig?.name ?? row?.lottery_config_id ?? '-' + const lotteryConfigNameFormatter = (row: Record) => lotteryPoolRowLabel(row) const rewardTierFormatter = (row: Record) => row?.reward_tier ?? '-' /** 摇取点数格式化为 1,3,4,5,6,6 */ diff --git a/saiadmin-artd/src/views/plugin/dice/play_record/index/modules/edit-dialog.vue b/saiadmin-artd/src/views/plugin/dice/play_record/index/modules/edit-dialog.vue index e228a02..19e1b97 100644 --- a/saiadmin-artd/src/views/plugin/dice/play_record/index/modules/edit-dialog.vue +++ b/saiadmin-artd/src/views/plugin/dice/play_record/index/modules/edit-dialog.vue @@ -37,7 +37,7 @@ @@ -180,6 +180,10 @@