修改推广后台首页

master
ELF 5 years ago
parent 16d458155a
commit e2d75ec2c6

@ -294,17 +294,11 @@ class AutoPackController extends Think
* 渠道游戏打包
*/
private function channel() {
$zip = new \ZipArchive();
$map = [];
$map['status'] = 1;
$map['enable_status'] = ['in', '0,2,3'];
$applyModel = M('apply', 'tab_');
$gameSourceModel = M('Game_source', 'tab_');
$launchModel = M('apply_launch', 'tab_');
$applys = $applyModel
->field('id,game_id,game_name,promote_id,promote_account,sdk_version')
$applys = M('apply', 'tab_')->field('id,game_id,game_name,promote_id,promote_account,sdk_version')
->where($map)
->order('bale_sort desc,id desc')
->limit(200)
@ -319,7 +313,7 @@ class AutoPackController extends Think
$games = M('game', 'tab_')->field(['id', 'game_appid', 'game_name', 'icon', 'sdk_version'])->where(['id' => ['in', $gameIds]])->select();
$games = index_by_column('id', $games);
$launchCountList = $launchModel->field(['apply_id', 'count(*) count'])->where(['apply_id' => ['in', $applyIds]])->group('apply_id')->select();
$launchCountList = M('apply_launch', 'tab_')->field(['apply_id', 'count(*) count'])->where(['apply_id' => ['in', $applyIds]])->group('apply_id')->select();
$launchCountList = index_by_column('apply_id', $launchCountList);
$gameSources = M('game_source', 'tab_')->field(['id', 'file_name', 'source_version', 'file_type', 'bao_name', 'game_id'])->where(['game_id' => ['in', $gameIds]])->select();

@ -37,9 +37,8 @@ class PromoteController extends BaseController
{
$this->meta_title = "首页";
$loginPromote = $this->getLoginPromote();
$whiteList = [1, 8, 84];
$isOpenQuery = in_array($loginPromote['id'], $whiteList) || in_array($loginPromote['parent_id'], $whiteList) || in_array($loginPromote['grand_id'], $whiteList) ? true : false;
$isOpenQuery = true;
if (!$isOpenQuery) {
$this->display('prepare');

Loading…
Cancel
Save