feat(俱乐部): 增加俱乐部详细介绍和关注数功能
This commit is contained in:
@@ -69,4 +69,53 @@ class Game extends Base
|
||||
|
||||
$this->success('Success', $model);
|
||||
}
|
||||
|
||||
public function getMacth()
|
||||
{
|
||||
$params = $this->request->param();
|
||||
$game = $this->model->get($params['id'] ?? NULL);
|
||||
if (empty($game)) {
|
||||
$this->error('比赛不存在');
|
||||
}
|
||||
$participant = Participant::where('game_id', $game['id'])->where('status', 1)->select();
|
||||
|
||||
|
||||
if ($game['team_type'] == 1) { //双打
|
||||
// 转转 4-16 每个人与其他人各搭档1次,决出个人排名 人数 4 ≦ n ≦ 16 (Default:8)
|
||||
// 轮数 3 ≦ m<n (Default:7) 报名费 0 ≦ m ≦ 10 元 (Default: 5)
|
||||
// 由前几名按比例瓜分 (可调 Default:40%/30%/20%/10%)
|
||||
// 混双转 4-32
|
||||
// (偶数) 每男与每女各搭档1次,分别决出男女排名 人数 4 ≦ n ≦ 32 (Default:16)
|
||||
// 轮数2 ≦ m ≦ n/2 (Default:8) 报名费 0 ≦ m ≦ 10 元 (Default: 5)
|
||||
// 由前几名按比例瓜分 (可调 Default:40%/30%/20%/10%)
|
||||
// 固搭转 4-32
|
||||
// (偶数) 固定组合,分别与其他组合对战一次,决出组合排名 人数 4 ≦ n ≦ 32 (Default:16)
|
||||
// 轮数 2 ≦ m ≦ n/2-1 (Default:7) 报名费 0 ≦ m ≦ 10 元 (Default: 5)
|
||||
// 由前几名按比例瓜分 (可调 Default:40%/30%/20%/10%)
|
||||
// 分区转 4-32
|
||||
// (偶数) 分为AB两区,A区与B区各搭档1次,分别决出AB区排名 人数 4 ≦ n ≦ 32 (Default:16)
|
||||
// 轮数2 ≦ m ≦ n/2 (Default:8) 报名费 0 ≦ m ≦ 10 元 (Default: 5)
|
||||
// 由前几名按比例瓜分 (可调 Default:40%/30%/20%/10%)
|
||||
// 擂台赛 8-44 由擂主决定出战组合,攻擂者按组合报名(不重复报名,但可兼项) 擂主人数 2 ≦ k ≦ 4 (Default:2)
|
||||
// 总攻擂数4 ≦ n ≦ 5k(Default:8) 攻擂报名费 0 ≦ m ≦ 10 (Default:5)
|
||||
// 擂主报名费 2n/k (不可调)
|
||||
// 攻擂者赢局获得2m元(不可调)
|
||||
// 由擂主分摊盈亏
|
||||
// 守擂赛 4-32
|
||||
// (偶数) 选手组合报名(不可重复报名),抽签决定对战顺序,相邻顺序对战,连赢m局进入决赛,决赛为淘汰赛,决出冠亚季 人数 4 ≦ n ≦ 32 (Default:16)
|
||||
// 连赢 1 ≦ m ≦ 3 (Default:2) 报名费0 ≦ k ≦ 10 (Default:5)
|
||||
// 由前几名按比例瓜分 (可调 Default:40%/30%/20%/10%)
|
||||
if ($game['rule_type'] == 1) { //转转
|
||||
foreach ($participant as $key => $value) {
|
||||
|
||||
}
|
||||
}
|
||||
} elseif ($game['team_type'] == 2) { //单打
|
||||
|
||||
} elseif ($game['team_type'] == 3) { //团队
|
||||
|
||||
}
|
||||
|
||||
$this->success('Success', ['list' => $participant]);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user