1.优化色子奖励权重表备注没有更新上去

This commit is contained in:
2026-06-04 14:55:33 +08:00
parent 0cc81299f0
commit f8969097d7

View File

@@ -465,7 +465,7 @@ class DiceRewardLogic
* - 奖励档位tier = DiceRewardConfig::where('id', $end_index)->first()->tier * - 奖励档位tier = DiceRewardConfig::where('id', $end_index)->first()->tier
* - 显示uiui_text = DiceRewardConfig::where('id', $end_index)->first()->ui_text * - 显示uiui_text = DiceRewardConfig::where('id', $end_index)->first()->ui_text
* - 实际中奖real_ev = DiceRewardConfig::where('id', $end_index)->first()->real_ev * - 实际中奖real_ev = DiceRewardConfig::where('id', $end_index)->first()->real_ev
* - 备注remark = DiceRewardConfig::where('id', $end_index)->first()->remark * - 备注remark = 按本条对照档位(推断后 T1-T5的默认备注T1 大奖、T2 小赚…),非落点格盘面 remark 字段
* - 类型type = DiceRewardConfig::where('id', $end_index)->first()->type-2=唯一惩罚,-1=抽水,0=回本,1=再来一次,2=小赚,3=大奖格) * - 类型type = DiceRewardConfig::where('id', $end_index)->first()->type-2=唯一惩罚,-1=抽水,0=回本,1=再来一次,2=小赚,3=大奖格)
* - weight 默认 1后续在权重编辑弹窗设置 * - weight 默认 1后续在权重编辑弹窗设置
* *
@@ -631,7 +631,8 @@ class DiceRewardLogic
} }
/** /**
* 对照表落点行:档位按结算金额推断备注与奖励配置页规则一致 * 对照表落点行:档位按落点格 real_ev 推断备注随**本条对照档位**T1 大奖 / T2 小赚 …),
* 与奖励配置页「按结算金额匹配档位备注」一致,不拷贝落点格盘面备注(盘面可保留「大奖格」等细分文案)。
* *
* @param array<string, mixed> $landingConfig * @param array<string, mixed> $landingConfig
* @return array<string, mixed> * @return array<string, mixed>
@@ -659,24 +660,11 @@ class DiceRewardLogic
'end_index' => isset($landingConfig['id']) ? (int) $landingConfig['id'] : 0, 'end_index' => isset($landingConfig['id']) ? (int) $landingConfig['id'] : 0,
'ui_text' => $landingConfig['ui_text'] ?? '', 'ui_text' => $landingConfig['ui_text'] ?? '',
'real_ev' => $landingConfig['real_ev'] ?? null, 'real_ev' => $landingConfig['real_ev'] ?? null,
'remark' => $this->resolveRemarkForReferenceRow($tier, $landingConfig), 'remark' => $this->defaultRemarkForTier($tier),
'type' => isset($landingConfig['type']) ? (int) $landingConfig['type'] : 0, 'type' => isset($landingConfig['type']) ? (int) $landingConfig['type'] : 0,
]; ];
} }
/**
* 对照表备注:优先落点格 dice_reward_config.remark空时再按档位默认与 createRewardReference 文档一致)
*/
private function resolveRemarkForReferenceRow(string $tier, array $landingConfig): string
{
$fromLanding = trim((string) ($landingConfig['remark'] ?? ''));
if ($fromLanding !== '') {
return $fromLanding;
}
return $this->defaultRemarkForTier($tier);
}
/** /**
* 按结算金额推断档位(与前端 generateIndexByRules 一致) * 按结算金额推断档位(与前端 generateIndexByRules 一致)
*/ */