新增查看显示实时彩金池
This commit is contained in:
@@ -135,4 +135,25 @@ class DiceLotteryConfigController extends BaseController
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取当前彩金池(Redis 实例化,无则按 type=0 创建)
|
||||
* 返回含 profit_amount 实时值,供前端轮询展示
|
||||
*/
|
||||
#[Permission('色子奖池配置列表', 'dice:lottery_config:index:index')]
|
||||
public function getCurrentPool(Request $request): Response
|
||||
{
|
||||
$data = $this->logic->getCurrentPool();
|
||||
return $this->success($data);
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新当前彩金池:仅可修改 safety_line、t1_weight~t5_weight,不可修改 profit_amount
|
||||
*/
|
||||
#[Permission('色子奖池配置修改', 'dice:lottery_config:index:update')]
|
||||
public function updateCurrentPool(Request $request): Response
|
||||
{
|
||||
$data = $request->post();
|
||||
$this->logic->updateCurrentPool($data);
|
||||
return $this->success('保存成功');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user