|
|
@ -882,9 +882,12 @@ class PaymentMerchantController extends ThinkController
|
|
|
|
public function saveMasterRule()
|
|
|
|
public function saveMasterRule()
|
|
|
|
{
|
|
|
|
{
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$userAuth = session('user_auth');
|
|
|
|
|
|
|
|
|
|
|
|
$params = I('post.');
|
|
|
|
$params = I('post.');
|
|
|
|
$service = new PaymentRuleService();
|
|
|
|
$service = new PaymentRuleService();
|
|
|
|
$service->saveGameMasterMerchantRule($params);
|
|
|
|
$service->saveGameMasterMerchantRule($params, $userAuth);
|
|
|
|
|
|
|
|
|
|
|
|
$this->ajaxReturn([
|
|
|
|
$this->ajaxReturn([
|
|
|
|
'status' => 1,
|
|
|
|
'status' => 1,
|
|
|
@ -933,12 +936,16 @@ class PaymentMerchantController extends ThinkController
|
|
|
|
$admins = M('ucenter_member', 'sys_')->field(['id', 'username'])->select();
|
|
|
|
$admins = M('ucenter_member', 'sys_')->field(['id', 'username'])->select();
|
|
|
|
$admins = index_by_column('id', $admins);
|
|
|
|
$admins = index_by_column('id', $admins);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$gameService = new GameService();
|
|
|
|
|
|
|
|
$games = $gameService->getBaseGames();
|
|
|
|
|
|
|
|
$gameNameMap = array_column($games, 'id', 'name');
|
|
|
|
|
|
|
|
|
|
|
|
$records = [];
|
|
|
|
$records = [];
|
|
|
|
foreach ($items as $item) {
|
|
|
|
foreach ($items as $item) {
|
|
|
|
$records[] = [
|
|
|
|
$records[] = [
|
|
|
|
'id' => $item['id'],
|
|
|
|
'id' => $item['id'],
|
|
|
|
'base_game_id' => $item['base_game_id'],
|
|
|
|
'base_game_id' => $item['base_game_id'],
|
|
|
|
'base_game_name' => $item['base_game_name'],
|
|
|
|
'base_game_name' => $gameNameMap[$item['base_game_id']] ?: '',
|
|
|
|
'is_first_pay' => $item['is_first_pay'],
|
|
|
|
'is_first_pay' => $item['is_first_pay'],
|
|
|
|
'max_times' => $item['max_times'],
|
|
|
|
'max_times' => $item['max_times'],
|
|
|
|
'max_pay_amount' => $item['max_pay_amount'],
|
|
|
|
'max_pay_amount' => $item['max_pay_amount'],
|
|
|
@ -953,9 +960,6 @@ class PaymentMerchantController extends ThinkController
|
|
|
|
$this->assign('_page', $page);
|
|
|
|
$this->assign('_page', $page);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
$gameService = new GameService();
|
|
|
|
|
|
|
|
$games = $gameService->getBaseGames();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$this->assign('games', $games);
|
|
|
|
$this->assign('games', $games);
|
|
|
|
$this->assign('records', $records);
|
|
|
|
$this->assign('records', $records);
|
|
|
|
$this->assign('admins', $admins);
|
|
|
|
$this->assign('admins', $admins);
|
|
|
|