diff --git a/Application/Admin/Controller/PromoteGameRatioController.class.php b/Application/Admin/Controller/PromoteGameRatioController.class.php index 6e358417b..37f290871 100644 --- a/Application/Admin/Controller/PromoteGameRatioController.class.php +++ b/Application/Admin/Controller/PromoteGameRatioController.class.php @@ -20,18 +20,15 @@ class PromoteGameRatioController extends ThinkController public function lists() { $params = I('get.'); - $promoteAccount = $params['promote_account'] ?? ''; + $promoteId = $params['promote_id'] ?? 0; $gameId = $params['game_id'] ?? 0; $status = $params['status'] ?? ''; $page = $params['p'] ? intval($params['p']) : 1; $row = $params['row'] ? intval($params['row']) : 10; $map['_string'] = '1 = 1'; - if ($promoteAccount) { - $promoteMap['account'] = trim($promoteAccount); - $promoteId = M('promote', 'tab_')->where($promoteMap)->getField('id'); - $promoteId = $promoteId ?? 0; - $map['promote_id'] = $promoteId; + if ($promoteId) { + $map['promote_id'] = intval($promoteId); } if ($gameId) { $map['game_id'] = intval($gameId); @@ -73,11 +70,10 @@ class PromoteGameRatioController extends ThinkController $thisReviewer = $promoteGameRatio['reviewer_id'] ? getPromoteAccount($promoteGameRatio['reviewer_id']) : '待确认'; if ($promoteGameRatio['ratio'] > 0) { $thisBeninTime = date('Y/m/d', $promoteGameRatio['begin_time']); - $thisEndTime = date('Y/m/d', $promoteGameRatio['end_time']); } else { $thisBeninTime = date('Y/m/d', $this->getPromoteApplyCreateTime($thisPromoteId, $thisGameId)); - $thisEndTime = '永久'; } + $thisEndTime = $promoteGameRatio['end_time'] ? date('Y/m/d', $promoteGameRatio['end_time']) : '永久'; $validDate = $thisBeninTime . ' - ' . $thisEndTime; if ($issetPromote) { $thisPromoteAccount = $promotes[$thisPromoteId]['account']; @@ -117,10 +113,36 @@ class PromoteGameRatioController extends ThinkController $this->assign('count', $count); $this->assign('gameList', getAllGameList()); $this->assign('promoteList', getPromoteByLevel(1)); + $this->assign('statusList', self::$statusList); $this->meta_title = '公会分成管理'; $this->display(); } + public function applyRatio() + { + if ($_POST) { + + } else { + $params = I('get.'); + $id = $params['id'] ?? 0; + $id = intval($id); + if ($id) { + $field = 'promote_id, game_id, ratio, begin_time, end_time, remark'; + $map['id'] = $id; + $promoteGameRatio = D(self::MODEL_NAME)->field($field)->where($map)->find(); + if (empty($promoteGameRatio)) { + $this->error('数据异常'); + } + $this->assign('record', $promoteGameRatio); + } + + $this->assign('gameList', getAllGameList()); + $this->assign('promoteList', getPromoteByLevel(1)); + $this->meta_title = '游戏分成比例申请'; + $this->display(); + } + } + private function getPromoteApplyCreateTime($promoteId, $gameId) { $map['promote_id'] = $promoteId; diff --git a/Application/Admin/View/PromoteGameRatio/applyRatio.html b/Application/Admin/View/PromoteGameRatio/applyRatio.html new file mode 100644 index 000000000..776077526 --- /dev/null +++ b/Application/Admin/View/PromoteGameRatio/applyRatio.html @@ -0,0 +1,171 @@ + + + + + + + + + + +
+
+ +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
*会长账号: + + 通过推广员后台注册申请或者管理后台创建的账号 +
*已申请游戏: + + 密码长度必须大于6位 +
账号状态: + + + + + 锁定状态下,推广员账号则无法登录 +
真实姓名: + +
手机号: + +
邮箱: + +
商务专员 + + 设置该推广员所属的商务专员组 +
+
+ + +
+ + + 返回 + +
+
+
+
+ + + +
+ + + + + + diff --git a/Application/Admin/View/PromoteGameRatio/lists.html b/Application/Admin/View/PromoteGameRatio/lists.html index b00ab7fc0..209559541 100644 --- a/Application/Admin/View/PromoteGameRatio/lists.html +++ b/Application/Admin/View/PromoteGameRatio/lists.html @@ -40,7 +40,7 @@
+
+ +
@@ -134,80 +142,12 @@
- -
- 导出 - {$_page|default=''} -
-
- +
已添加添加至常用设置
@@ -223,7 +163,7 @@ $(".select_gallery").select2();