解决冲突

master
ELF 5 years ago
commit e8a0975981

@ -724,7 +724,7 @@ function getAllGameList($groupByRelation = false)
{
$field = 'id, game_name, relation_game_id, relation_game_name';
if ($groupByRelation) {
$games = M('game', 'tab_')->field($field)->group('relation_game_id')->select();
$games = M('game', 'tab_')->field($field)->where('id = relation_game_id')->group('relation_game_id')->select();
} else {
$games = M('game', 'tab_')->field($field)->select();
}

@ -295,11 +295,14 @@ class AjaxController extends ThinkController{
$data['game_ratio'] = $handleStatementData;
$data['company_name'] = $second_party_info['partner'];
$data['mobile_phone'] = $second_party_info['link_phone'];
$data['bank_card'] = $second_party_info['bank_account'];
$data['account_openin'] = $second_party_info['opening_bank'];
$data['settlement_type'] = $second_party_info['settlement_type'];
$data['address'] = $second_party_info['address'];
$data['real_name'] = $second_party_info['link_man'];
$data['bank_account_name'] = $second_party_info['bank_account_name'];
$data['settlement_type_value'] = $getStatementData['settlement_type'];
$data['settlement_type_value'] = $getStatementData['settlement_type'];
$data['invoice_item'] = $second_party_info['invoice_item'];
$data['invoice_type'] = $second_party_info['invoice_type'];

@ -5884,6 +5884,9 @@ class ExportController extends Controller
if (I('status')) {
$map['tab_promote.status'] = I('status');
}
if (strlen(I('company_belong'))) {
$map['company_belong'] = I("company_belong");
}
//为数据权限添加
setPowerPromoteIds($map, 'tab_promote.id');

@ -19,6 +19,7 @@ use BaiduBce\Auth\SignOptions;
use BaiduBce\Log\LogFactory;
use Admin\Model\AuthRuleModel;
use Admin\Model\AuthGroupModel;
use Base\Service\GameService;
/**
* 后台首页控制器
@ -172,6 +173,15 @@ class GameController extends ThinkController
$this->error('游戏标示不能为空!');
exit;
}
$downloadWays = $_POST['download_ways'] ?? [];
if (in_array(GameService::DOWNLOAD_BETA, $downloadWays)) {
if (empty($_POST['beta_url'])) {
return $this->error("请在Beta按钮开启的情况填写Beta链接");
}
if (!preg_match("/^((https|http|itms-beta)?:\/\/)[^\s]+/i", $_POST['beta_url'])) {
return $this->error("请填写正确的Beta链接");
}
}
$_POST['relation_game_name'] = $_POST['game_name'];
if ($_POST['sdk_version'] == 1) {
unset($_POST['ios_game_address']);
@ -205,6 +215,10 @@ class GameController extends ThinkController
//$_POST['material_url'] = $_POST['file_url'].$_POST['file_name'];
$_POST['discount'] == '' ? $_POST['discount'] = 10 : $_POST['discount'];
$_POST['short'] = $short;
$gameService = new GameService();
$_POST['download_ways'] = $gameService->getDownLoadWaysValue($downloadWays);
$game = D(self::model_name);//M('$this->$model_name','tab_');
$res = $game->update();
if (!$res) {
@ -338,15 +352,18 @@ class GameController extends ThinkController
exit;
}
if ($_POST['beta_status'] == 1 && empty($_POST['beta_url'])) {
return $this->error("请在Beta按钮开启的情况填写Beta链接");
}
if (!empty($_POST['beta_url']) && !preg_match("/^((https|http|itms-beta)?:\/\/)[^\s]+/i", $_POST['beta_url'])) {
return $this->error("请填写正确的Beta链接");
$downloadWays = $_POST['download_ways'] ?? [];
if (in_array(GameService::DOWNLOAD_BETA, $downloadWays)) {
if (empty($_POST['beta_url'])) {
return $this->error("请在Beta按钮开启的情况填写Beta链接");
}
if (!preg_match("/^((https|http|itms-beta)?:\/\/)[^\s]+/i", $_POST['beta_url'])) {
return $this->error("请填写正确的Beta链接");
}
}
/*if($_POST['apply_status']==0&&$_POST['game_status']==1){
$this->error('游戏未审核不允许显示');//游戏添加完成
}*/
}*/
$_POST['introduction'] = str_replace(array("\r\n", "\r", "\n"), "~~", $_POST['introduction']);
if (!empty($_POST['display_site'])) {
@ -360,7 +377,10 @@ class GameController extends ThinkController
$_POST['discount'] == '' ? $_POST['discount'] = 10 : $_POST['discount'];
$_POST['detail_content'] = $content;
$_POST['pay_config'] = json_encode($_POST['pay_config']);
$gameService = new GameService();
$_POST['download_ways'] = $gameService->getDownLoadWaysValue($downloadWays);
$res = $game->update();
$id = $res["id"];
$sibling = D("Game")->find($id);
$map['relation_game_id'] = $sibling['relation_game_id'];
@ -395,9 +415,6 @@ class GameController extends ThinkController
$phone['back_map'] = $sibling['back_map'];
$phone['flooring_page_video'] = $sibling['flooring_page_video'];
$phone['flooring_page_video_cover'] = $sibling['flooring_page_video_cover'];
$phone['supersign_status'] = $sibling['supersign_status'];
$phone['beta_url'] = $_POST['beta_url'];
$phone['beta_status'] = $_POST['beta_status'];
M('Game', 'tab_')->data($phone)->where(array('id' => $another['id']))->save();
//同时修改代充游戏折扣
$set_fidel['status'] = 1;

@ -96,6 +96,9 @@ class PromoteController extends ThinkController
if (I("promote_level")) {
$map['level'] = I("promote_level");
}
if (strlen(I('company_belong'))) {
$map['company_belong'] = I("company_belong");
}
$this->m_title = '推广员列表';
$this->assign('commonset', M('Kuaijieicon')->where(['url'=>'Promote/lists/type/1','status'=>1])->find());
if (isset($_REQUEST['row'])) {
@ -221,6 +224,10 @@ class PromoteController extends ThinkController
if ($this->accountExist($account)) {
$this->error('该账号已存在');
}
$res = M('promote', 'tab_')->where(['mobile_phone' => $mobile_phone])->field('id')->find();
if ($res) {
$this->error('该手机号已存在');
}
$company_belong = $_REQUEST['company_belong'] ?? 0;
$company_relation = $_REQUEST['company_relation'] ?? 0;
$data = array(
@ -1205,6 +1212,10 @@ class PromoteController extends ThinkController
$map['p.account'] = array('like','%'.I('account').'%');
}
if (!is_null(I('can_view_recharge', null))) {
$map['pb.can_view_recharge'] = I('can_view_recharge');
}
$this->m_title = '推广公会归属管理';
$this->assign('commonset', M('Kuaijieicon')->where(['url'=>'Promote/belong','status'=>1])->find());
if (isset($_REQUEST['row'])) {
@ -1235,7 +1246,7 @@ class PromoteController extends ThinkController
$this->display();
}
public function belong_add($promote_id=null, $company_belong = null, $company_relation = null, $remark = null)
public function belong_add($promote_id=null, $company_belong = null, $company_relation = null, $remark = null, $can_view_recharge = null)
{
if (IS_POST) {
if (empty($promote_id)) {
@ -1245,6 +1256,7 @@ class PromoteController extends ThinkController
'promote_id' => $promote_id,
'company_belong' => $company_belong,
'company_relation' => $company_relation,
'can_view_recharge' => $can_view_recharge,
'verify_status' => 0,
'remark' => $remark,
'applicant_id' => getAdmin(),
@ -1271,7 +1283,7 @@ class PromoteController extends ThinkController
}
}
public function belong_edit($promote_id=null, $company_belong = null, $company_relation = null, $remark = null)
public function belong_edit($promote_id=null, $company_belong = null, $company_relation = null, $remark = null, $can_view_recharge = null)
{
if (IS_POST) {
if (empty($promote_id)) {
@ -1281,6 +1293,7 @@ class PromoteController extends ThinkController
'promote_id' => $promote_id,
'company_belong' => $company_belong,
'company_relation' => $company_relation,
'can_view_recharge' => $can_view_recharge,
'verify_status' => 0,
'remark' => $remark,
'applicant_id' => getAdmin(),
@ -1320,7 +1333,8 @@ class PromoteController extends ThinkController
foreach ($promote_belongs as $promote_belong) {
$update = [
'company_belong' => $promote_belong['company_belong'],
'company_relation' => $promote_belong['company_relation']
'company_relation' => $promote_belong['company_relation'],
'can_view_recharge' => $promote_belong['can_view_recharge'],
];
$res = M("promote", "tab_")
->where("chain like '%/{$promote_belong['promote_id']}/%' or id={$promote_belong['promote_id']} ")

@ -28,7 +28,7 @@ class PromoteGameRatioController extends ThinkController
$page = $params['p'] ? intval($params['p']) : 1;
$row = $params['row'] ? intval($params['row']) : 10;
$map['_string'] = '1 = 1';
$map['_string'] = 'game_id = relation_game_id';
if ($promoteId) {
$map['promote_id'] = intval($promoteId);
}
@ -43,11 +43,13 @@ class PromoteGameRatioController extends ThinkController
if ($group == 1) {
$query = D(self::MODEL_NAME)->field($field, true)
->where($map)
->group('promote_id, relation_game_id')
->order('update_time desc, id desc');
$metaTitle = $csvTitle = '公会分成管理';
} else {
$query = M(self::MODEL_NAME . '_log', 'tab_')->field($field, true)
->where($map)
->group('promote_id, relation_game_id, create_time')
->order('create_time desc, id desc');
$metaTitle = $csvTitle = '公会分成申请记录';
}
@ -56,7 +58,10 @@ class PromoteGameRatioController extends ThinkController
}
$promoteGameRatios = $query->select();
if (I('export', 0) != 1) {
$count = D(self::MODEL_NAME)->where($map)->count();
$count = count(D(self::MODEL_NAME)->where($map)
->group('promote_id, relation_game_id')
->order('update_time desc, id desc')
->select());
}
$records = [];
@ -64,7 +69,7 @@ class PromoteGameRatioController extends ThinkController
$promoteIds = array_column($promoteGameRatios, 'promote_id');
$gameIds = array_column($promoteGameRatios, 'game_id');
$promoteFiled = 'id, account, mobile_phone, create_time, status, ver_status';
$gameFiled = 'id, game_name, ratio';
$gameFiled = 'id, relation_game_name, ratio';
$promotes = M('promote', 'tab_')->where(array('id' => ['in', $promoteIds]))->getField($promoteFiled, true);
$games = M('game', 'tab_')->where(array('id' => ['in', $gameIds]))->getField($gameFiled, true);
@ -103,7 +108,7 @@ class PromoteGameRatioController extends ThinkController
$thisPromoteVerStatus = getPromoteVerStatus($promotes[$thisPromoteId]['ver_status'], 2);
}
if ($issetGame) {
$thisGameName = $games[$thisGameId]['game_name'];
$thisGameName = $games[$thisGameId]['relation_game_name'];
$thisGameRatio = $games[$thisGameId]['ratio'];
$thisGameRatio = ($thisGameRatio ?? '0.00') . '%';
}
@ -161,7 +166,7 @@ class PromoteGameRatioController extends ThinkController
$this->assign('group', $group);
$this->assign('records', $records);
$this->assign('count', $count);
$this->assign('gameList', getAllGameList());
$this->assign('gameList', getAllGameList(true));
$this->assign('promoteList', getPromoteByLevel(1));
$this->assign('statusList', self::$statusList);
$this->assign('reviewRule', $reviewRule);
@ -232,6 +237,7 @@ class PromoteGameRatioController extends ThinkController
$save['remark'] = $params['remark'] ?? '';
$save['status'] = 0;
$save['update_time'] = $time;
$model = new PromoteGameRatioModel();
if (!empty($params['id'])) {//修改
$promoteGameRatio = D(self::MODEL_NAME)->find($params['id']);
if (empty($promoteGameRatio)) {
@ -245,13 +251,25 @@ class PromoteGameRatioController extends ThinkController
$save['last_ratio'] = $promoteGameRatio['ratio'];
$save['last_ratio_status'] = 1;
}
$save['id'] = intval($params['id']);
$result = D(self::MODEL_NAME)->save($save);
$saveMap['relation_game_id'] = $promoteGameRatio['relation_game_id'];
$result = D(self::MODEL_NAME)->where($saveMap)->save($save);
$logResult = $result;
} else {
$result = true;
$logResult = false;
}
if ($result === false) {
$this->error('保存失败');
}
if ($logResult) {
$promoteGameRatioIds = D(self::MODEL_NAME)->where(array('relation_game_id' => $promoteGameRatio['relation_game_id']))->getField('id', true);
if (!empty($promoteGameRatioIds)) {
foreach ($promoteGameRatioIds as $promoteGameRatioId) {
$model->addLog($promoteGameRatioId);
}
}
}
} else {//新增
if (empty($params['promote_id'])) {
$this->error('请选择会长账号');
@ -261,6 +279,14 @@ class PromoteGameRatioController extends ThinkController
}
$promoteId = intval($params['promote_id']);
$gameId = intval($params['game_id']);
$relationGameId = D('game')->where(array('id' => $gameId))->getField('relation_game_id');
if (empty($relationGameId)) {
$this->error('数据异常');
}
$gameIds = D('game')->where(array('relation_game_id' => $relationGameId))->getField('id', true);
if (empty($gameIds)) {
$this->error('数据异常');
}
$promote = M('promote', 'tab_')->find($promoteId);
if (empty($promote) || $promote['level'] != 1) {
@ -270,36 +296,35 @@ class PromoteGameRatioController extends ThinkController
$this->isWithdraw($promoteId, $save['begin_time']);
$map['promote_id'] = $promoteId;
$map['game_id'] = $gameId;
$promoteGameRatio = D(self::MODEL_NAME)->where($map)->find();
if ($promoteGameRatio) {
$this->error('网络异常');
}
$save['promote_id'] = $promoteId;
$save['game_id'] = $gameId;
$save['last_turnover_ratio'] = '';
$save['applicant_id'] = is_login();
$save['create_time'] = $time;
$result = D(self::MODEL_NAME)->add($save);
$logResult = $result;
}
if ($result === false) {
$this->error('保存失败');
} else {
if ($logResult) {
if (empty($params['id'])) {
$promoteGameRatioId = $result;
} else {
$promoteGameRatioId = $params['id'];
M()->startTrans();
foreach ($gameIds as $gameId) {
$map['game_id'] = $gameId;
$promoteGameRatio = D(self::MODEL_NAME)->where($map)->find();
if ($promoteGameRatio) {
$this->error('网络异常');
}
$model = new PromoteGameRatioModel();
$model->addLog($promoteGameRatioId);
}
$save['game_id'] = $gameId;
$save['relation_game_id'] = $relationGameId;
$result = D(self::MODEL_NAME)->add($save);
$logResult = $result;
$this->success('保存成功', U('lists'));
if ($result === false) {
M()->rollback();
$this->error('保存失败');
}
if ($logResult) {
$model->addLog($result);
}
}
M()->commit();
}
$this->success('保存成功', U('lists'));
} else {
$params = I('get.');
$id = $params['id'] ?? 0;
@ -326,7 +351,7 @@ class PromoteGameRatioController extends ThinkController
$this->assign('lastRatio', $lastRatio);
}
$this->assign('gameList', getAllGameList());
$this->assign('gameList', getAllGameList(true));
$this->assign('promoteList', getPromoteByLevel(1));
$this->meta_title = $metaTitle;
$this->display();
@ -365,8 +390,11 @@ class PromoteGameRatioController extends ThinkController
$this->error('操作失败');
}
$promoteGameRatioMap['id'] = ['in', $ids];
$relationGameIds = D(self::MODEL_NAME)->where($promoteGameRatioMap)->getField('relation_game_id', true);
$time = time();
$map['id'] = ['in', $ids];
$map['relation_game_id'] = ['in', $relationGameIds];
$map['status'] = 0;
$save['status'] = $status;
$save['reviewer_id'] = is_login();
@ -378,17 +406,16 @@ class PromoteGameRatioController extends ThinkController
$result = D(self::MODEL_NAME)->where($map)->save($save);
if ($result) {
$model = new PromoteGameRatioModel();
foreach ($ids as $id) {
$model->addLog($id);
if ($status == 1) {
$promoteGameRatio = D(self::MODEL_NAME)->find($id);
if (!empty($promoteGameRatio)) {
$promoteGameRatios = D(self::MODEL_NAME)->where(array('relation_game_id' => ['in', $relationGameIds]))->select();
if (!empty($promoteGameRatios)) {
foreach ($promoteGameRatios as $promoteGameRatio) {
$promoteId = $promoteGameRatio['promote_id'];
$promoteMap['chain'] = ['like', "/{$promoteId}/%"];
$promoteIds = M('promote', 'tab_')->where($promoteMap)->getField('id', true);
$promoteIds[] = $promoteId;
$model->addLog($promoteGameRatio['id']);
if ($status == 1) {
if ($promoteGameRatio['begin_time'] <= strtotime(date('Y-m-d', time()))) {
$promoteId = $promoteGameRatio['promote_id'];
$promoteMap['chain'] = ['like', "/{$promoteId}/%"];
$promoteIds = M('promote', 'tab_')->where($promoteMap)->getField('id', true);
$promoteIds[] = $promoteId;
$spendMap['promote_id'] = ['in', $promoteIds];
$spendMap['game_id'] = $promoteGameRatio['game_id'];
if ($promoteGameRatio['end_time'] > 0) {

@ -4,6 +4,7 @@ namespace Admin\Controller;
use User\Api\UserApi;
use Com\Wechat;
use Com\WechatAuth;
use Base\Tool\TaskClient;
/**
* 后台首页控制器
@ -78,7 +79,9 @@ class PublicController extends \Think\Controller
if (IS_POST) {
/* 检测验证码 TODO: */
$this->checksafecode($mobile, $verify, false);
if (!$this->checksafecode($mobile, $verify)) {
$this->error('验证码错误');
}
$promote = M('promote', 'tab_')->where([
'mobile_phone' => $mobile,
'level' => 1,
@ -341,41 +344,31 @@ class PublicController extends \Think\Controller
*/
public function telsafecode($phone = '', $delay = 10, $flag = true)
{
$result = R('Common/Sms/send_sms_code', array($phone, $delay, false));
if ($result['code'] == 200) {
$taskClient = new TaskClient();
$result = $taskClient->sendSms($phone, get_client_ip());
$data = [];
if ($result['code'] == TaskClient::SUCCESS) {
$data['status'] = 1;
$data['data'] = $result['data'];
} else {
$data['status'] = 0;
}
$data['msg'] = $result['msg'];
$data['msg'] = $result['message'];
echo json_encode($data);
exit;
}
/**
* 手机安全码验证
* @param bool $flag true 用于直接异步请求 false 用于方法调用
* @param [type] $vcode [description]
*/
public function checksafecode($phone, $vcode, $flag = true)
public function checksafecode($phone, $code)
{
$result = R('Common/Sms/verify_sms_code', array($phone, $vcode, false));
if ($result['code'] == 200) {
$data['status'] = 1;
if ($flag) {
echo json_encode($data);
exit;
}
$taskClient = new TaskClient();
$result = $taskClient->checkSms($phone, $code);
$data = [];
if ($result && $result['code'] == TaskClient::SUCCESS) {
return true;
} else {
$data['status'] = 0;
$data['msg'] = $result['msg'];
echo json_encode($data);
exit;
return false;
}
}

@ -1470,14 +1470,17 @@ class QueryController extends ThinkController
}
if ($_REQUEST['device']) {
$map['game_name'] = ['like','%'.$_REQUEST['device'].'%'];
}
// $map['tab_spend.sdk_version'] = $_REQUEST['device'];
$spendMap['tab_spend.sdk_version'] = $_REQUEST['device'];
}
$spendMap['tab_spend.pay_status'] = 1;
//获取spend表中的数据同时根据会长id进行group分类
$data = M('Spend','tab_')
->field("FROM_UNIXTIME(pay_time,'%Y-%m') as my_time,sum(pay_amount) as pay_amount,game_id,game_name,SUBSTRING_INDEX(`game_name`,\"(\",1) as game_names,promote_id,promote_account,company_relation,company_belong,CASE WHEN SUBSTRING_INDEX(SUBSTRING_INDEX(`chain`,\"/\",2),\"/\",-1)='' THEN promote_id ELSE SUBSTRING_INDEX(SUBSTRING_INDEX(`chain`,\"/\",2),\"/\",-1) END as root_id ")
->field("FROM_UNIXTIME(pay_time,'%Y-%m') as my_time,sum(pay_amount) as pay_amount,game_id,tab_spend.game_name,SUBSTRING_INDEX(tab_spend.`game_name`,\"(\",1) as game_names,promote_id,promote_account,company_relation,company_belong,CASE WHEN SUBSTRING_INDEX(SUBSTRING_INDEX(`chain`,\"/\",2),\"/\",-1)='' THEN promote_id ELSE SUBSTRING_INDEX(SUBSTRING_INDEX(`chain`,\"/\",2),\"/\",-1) END as root_id,tab_game.ratio,tab_game.relation_game_id ")
->join("left join tab_promote on promote_id = tab_promote.id")
->where(['pay_status'=>1])
->join("left join tab_game on tab_game.id=tab_spend.game_id")
->where($spendMap)
->group("my_time,game_names,root_id")
->order("my_time Desc")
->select(false);
@ -1493,9 +1496,9 @@ class QueryController extends ThinkController
//关联表获取会长账号名
$data = M()->table('('.$data.') as a')
->field("my_time,pay_amount,a.game_id,game_name,game_names,a.promote_id,a.promote_account,a.company_relation,a.company_belong,CASE WHEN root_id is null THEN 0 ELSE root_id END as root_id,CASE WHEN account is null THEN '官方渠道' ELSE account END as account,tab_ratio.ratio as ratio,turnover_ratio")
->field("my_time,pay_amount,a.game_id,game_name,game_names,a.promote_id,a.promote_account,a.company_relation,a.company_belong,CASE WHEN root_id is null THEN 0 ELSE root_id END as root_id,CASE WHEN account is null THEN '官方渠道' ELSE account END as account,tab_ratio.ratio as ratio,turnover_ratio,a.ratio as game_ratio")
->join("left join tab_promote on root_id = tab_promote.id")
->join("left join tab_promote_game_ratio as tab_ratio on tab_ratio.game_id = a.game_id and tab_ratio.promote_id=root_id")
->join("left join tab_promote_game_ratio as tab_ratio on tab_ratio.game_id = a.relation_game_id and tab_ratio.promote_id=root_id")
// ->join("left join tab_cp_game_ratio as game_ratio on game_ratio.game_id = a.game_id")
->page($page,$row)
->where($map)
@ -1520,10 +1523,9 @@ class QueryController extends ThinkController
if ($value['ratio']) {
$data[$key]['downstream'] = $value['pay_amount'] * ($value['ratio']*0.01);
} else {
$data[$key]['downstream'] = $value['pay_amount'] * 0;
$data[$key]['downstream'] = $value['pay_amount'] * ($value['game_ratio']*0.01);
}
$value['turnover_ratio'] = json_decode($value['turnover_ratio'],true);
// dd($value);
@ -1575,14 +1577,22 @@ class QueryController extends ThinkController
$map['my_time'] = $_REQUEST['count_date'];
}
// if ($_REQUEST['device']) {
// $map['game_name'] = ['like','%'.$_REQUEST['device'].'%'];
// }
if ($_REQUEST['device']) {
$map['game_name'] = ['like','%'.$_REQUEST['device'].'%'];
// $map['tab_spend.sdk_version'] = $_REQUEST['device'];
$spendMap['tab_spend.sdk_version'] = $_REQUEST['device'];
}
$spendMap['tab_spend.pay_status'] = 1;
//获取spend表中的数据同时根据会长id进行group分类
$data = M('Spend','tab_')
->field("FROM_UNIXTIME(pay_time,'%Y-%m') as my_time,sum(pay_amount) as pay_amount,game_id,game_name,SUBSTRING_INDEX(`game_name`,\"(\",1) as game_names,promote_id,promote_account,company_relation,company_belong,CASE WHEN SUBSTRING_INDEX(SUBSTRING_INDEX(`chain`,\"/\",2),\"/\",-1)='' THEN promote_id ELSE SUBSTRING_INDEX(SUBSTRING_INDEX(`chain`,\"/\",2),\"/\",-1) END as root_id,pay_way ")
->join("left join tab_promote on promote_id = tab_promote.id")
->where(['pay_status'=>1])
->where($spendMap)
->group("my_time,game_names,root_id,pay_way")
->order("my_time Desc")
->select(false);

@ -48,7 +48,6 @@ class StatementMangementController extends ThinkController
// var_dump($data);die();
foreach ($data as $key => $value) {
$data[$key]['order'] = json_decode($value['second_party_info'],true)['order_type'];
var_dump($data[$key]['order']);
}
$sumData = M("statement","tab_")

@ -415,7 +415,7 @@ class PromoteModel extends Model{
foreach ($result as $key => $value) {
$parseData[$key] = $value;
$parseData[$key]['company_belong_str'] = $value['company_belong'] ? '外团' : '内团';
$parseData[$key]['company_relation_str'] = $value['company_belong'] ? '只维护' : '自主开发及维护';
$parseData[$key]['company_relation_str'] = $value['company_relation'] ? '只维护' : '自主开发及维护';
}
return $parseData;
}

@ -226,7 +226,7 @@ class WithdrawModel extends Model{
return 1;
}
//月结
//月结
public function promoteWithdrawPerMonthByPromote($promote, $initial = false, $data = [])
{
$promoteIds = $this->getPromoteChildren($promote);

@ -408,16 +408,39 @@
<tr>
<td class="l">超级签Token</td>
<td class="r" >
<input type="text" class="txt " name="supersign_token" value="" placeholder="请输入超级签Token" >
</td>
<td class="l">超级签Token</td>
<td class="r" >
<input type="text" class="txt " name="supersign_token" value="" placeholder="请输入超级签Token" >
</td>
</tr>
<tr>
<td class="l">超级签URL</td>
<td class="r" >
<input type="text" class="txt " name="supersign_url" value="" placeholder="请输入超级签URL" >
</td>
<td class="l">超级签URL</td>
<td class="r" >
<input type="text" class="txt " name="supersign_url" value="" placeholder="请输入超级签URL" >
</td>
</tr>
<tr class="ios-display" style="display: none;">
<td class="l" >Beta版本链接</td>
<td class="r" colspan="3">
<input type="text" class="txt " name="beta_url" value="" placeholder="请输入Bata版本下载链接">
</td>
</tr>
<tr class="ios-display" style="display: none;">
<td class="l">下载方式</td>
<td class="r" >
<span class="form_radio table_btn">
<label>
<input type="checkbox" class="inp_radio" value="1" name="download_ways[]"> 至尊下载
</label>
<label>
<input type="checkbox" class="inp_radio" value="2" name="download_ways[]"> beta版下载
</label>
<label>
<input type="checkbox" class="inp_radio" value="4" name="download_ways[]"> 普通下载
</label>
</span>
</td>
</tr>
</tbody>
</table>
@ -1284,9 +1307,11 @@
$("input[name='appstatus'][value=1]").prop("disabled",true);
$("input[name='appstatus'][value=0]").prop("disabled",true);
$("input[name='appstatus'][value=0]").prop("checked",true);
$('.ios-display').hide();
}else{
$("input[name='appstatus'][value=1]").removeAttr("disabled");
$("input[name='appstatus'][value=0]").removeAttr("disabled");
$('.ios-display').show();
}
})

@ -447,28 +447,6 @@
</if>
</tr>
<tr>
<td class="l" >Beta版本链接</td>
<td class="r" colspan="3">
<input type="text" class="txt " name="beta_url" value="{$data['beta_url']}" placeholder="请输入Bata版本下载链接">
</td>
</tr>
<tr>
<td class="l">Beta版本是否开启</td>
<td class="r" >
<span class="form_radio table_btn">
<label>
<input type="radio" class="inp_radio" value="0" name="beta_status" <?php if ($data['beta_status'] == 0):?>checked='checked'<?php endif;?> > 关闭
</label>
<label>
<input type="radio" class="inp_radio" value="1" name="beta_status" <?php if ($data['beta_status'] == 1):?>checked='checked'<?php endif;?> > 开启
</label>
</span>
</td>
</tr>
<notempty name="data.accredit_img">
<tr class="picbox">
<td class="l noticeinfo">知识产权</td>
@ -570,6 +548,7 @@
<td class="r"><input type="text" class="txt2" id="game_address_size" value="{$data['game_address_size']}" name="game_address_size" placeholder="请输入第三方原包大小"> </td>
</tr>
<?php if($data['sdk_version'] == 2):?>
<tr>
<td class="l">超级签Token</td>
<td class="r" >
@ -582,32 +561,29 @@
<input type="text" class="txt " name="supersign_url" value="{$data['supersign_url']}" placeholder="请输入超级签URL" >
</td>
</tr>
<tr>
<td class="l">超级签状态:</td>
<if condition="$data['supersign_status'] eq 1">
<td class="r" >
<span class="form_radio table_btn">
<label>
<input type="radio" class="inp_radio" value="0" name="supersign_status" > 关闭
</label>
<label>
<input type="radio" class="inp_radio" value="1" name="supersign_status" checked="checked"> 开启
</label></span>
</td>
<else/>
<td class="r" >
<span class="form_radio table_btn">
<label>
<input type="radio" class="inp_radio" value="0" name="supersign_status" checked="checked"> 关闭
</label>
<label>
<input type="radio" class="inp_radio" value="1" name="supersign_status" > 开启
</label></span>
</td>
</if>
<td class="l" >Beta版本链接</td>
<td class="r" colspan="3">
<input type="text" class="txt " name="beta_url" value="{$data['beta_url']}" placeholder="请输入Bata版本下载链接">
</td>
</tr>
<tr>
<td class="l">下载方式</td>
<td class="r" >
<span class="form_radio table_btn">
<label>
<input type="checkbox" class="inp_radio" value="4" name="download_ways[]" <?php if(($data['download_ways'] & 4) == 4):?>checked<?php endif;?>> 至尊下载
</label>
<label>
<input type="checkbox" class="inp_radio" value="2" name="download_ways[]" <?php if(($data['download_ways'] & 2) == 2):?>checked<?php endif;?>> beta版下载
</label>
<label>
<input type="checkbox" class="inp_radio" value="1" name="download_ways[]" <?php if(($data['download_ways'] & 1) == 1):?>checked<?php endif;?>> 普通下载
</label>
</span>
</td>
</tr>
<?php endif;?>
</tbody>
</table>
</div>

@ -73,7 +73,13 @@
<option value="2">审核未通过</option>
</select>
</div>
<div class="input-list input-list-channelstatus">
<select name="can_view_recharge">
<option value="">充值信息权限</option>
<option value="0">禁止</option>
<option value="1">开放</option>
</select>
</div>
<input type="hidden" name="" value="" class="sortBy">
<input type="hidden" name="type" value="{$_GET['type']}">
<div class="input-list">
@ -100,6 +106,7 @@
<th>身份状态</th>
<th>内外团</th>
<th>归属状态</th>
<th>充值信息权限</th>
<th>申请时间</th>
<th>备注</th>
<th>审核</th>
@ -181,6 +188,14 @@
<span>只维护</span>
<?php }?>
</td>
<td>
<?php if($data['can_view_recharge'] == 0) {?>
<span>禁止</span>
<?php }?>
<?php if(intval($data['can_view_recharge']) == 1) {?>
<span>开放</span>
<?php }?>
</td>
<td>{:set_show_time($data['applicant_time'])}</td>
<td>{$data['remark']}</td>
<td>
@ -208,9 +223,9 @@
</div>
<div class="page">
<if condition="$is_admin eq true ">
<!-- <if condition="$is_admin eq true ">
<a class="sch-btn" href="{:U('Export/promote_list',array_merge(['xlsname'=>'推广员管理_推广员列表'.((I('type',1)==2)?'_混服申请':'_推广员列表')],I('get.')))}">导出</a>
</if>
</if>-->
{$_page|default=''}
</div>

@ -89,6 +89,22 @@
<!-- <span class="notice-text"></span>-->
</td>
</tr>
<tr id="can_view_recharge">
<td class="l">充值信息查看权限:</td>
<td class="r table_radio">
<span class="form_radio table_btn">
<label >
<input type="radio" value="0" name="can_view_recharge" checked="checked"> 禁止
</label >
<label >
<input type="radio" value="1" name="can_view_recharge" > 开放
</label>
</span>
<!-- <span class="notice-text"></span>-->
</td>
</tr>
<tr>
<td class="l">备注:</td>
<td> <textarea name="remark" class="" placeholder="备注" ></textarea></td>

@ -100,6 +100,26 @@
</td>
</tr>
<tr id="can_view_recharge">
<td class="l">充值信息查看权限:</td>
<td class="r table_radio">
<span class="form_radio table_btn">
<label >
<input type="radio" value="0" name="can_view_recharge" <?php if($data['can_view_recharge'] ==0):?>
checked="checked"
<?php endif?>
> 禁止
</label >
<label >
<input type="radio" value="1" name="can_view_recharge" <?php if($data['can_view_recharge'] ==1):?>
checked="checked"
<?php endif?>> 开放
</label>
</span>
<!-- <span class="notice-text"></span>-->
</td>
</tr>
<tr>
<td class="l">备注:</td>
<td> <textarea name="remark" class="" placeholder="备注" >{$data['remark']}</textarea></td>

@ -134,6 +134,14 @@
<option value="0">未关联</option>
</select>
</div>
<div class="input-list input-list-channelstatus">
<select name="company_belong">
<option value="">内外团</option>
<option value="0">内团</option>
<option value="1">外团</option>
</select>
</div>
<else/>
<div class="input-list input-list-channelstatus">
<select name="url_type">
@ -156,6 +164,7 @@
<option value="0">未关联</option>
</select>
</div>
</empty>
<input type="hidden" name="" value="" class="sortBy">
<input type="hidden" name="type" value="{$_GET['type']}">

@ -105,11 +105,11 @@
<option value="">游戏名称</option>
<empty name="record">
<volist name="gameList" id="vo">
<option value="{$vo.id}">{$vo.game_name}</option>
<option value="{$vo.id}">{$vo.relation_game_name}</option>
</volist>
<else/>
<volist name="gameList" id="vo">
<option value="{$vo.id}" <if condition="$vo['id'] eq $record['game_id']">selected</if> >{$vo.game_name}</option>
<option value="{$vo.id}" <if condition="$vo['id'] eq $record['game_id']">selected</if> >{$vo.relation_game_name}</option>
</volist>
</empty>
</select>

@ -111,8 +111,8 @@
<div class="input-list input-list-game search_label_rehab">
<select name="device" class="select_gallery">
<option value="">设备类型</option>
<option value="安卓版">安卓</option>
<option value="苹果版">IOS</option>
<option value="1">安卓</option>
<option value="2">IOS</option>
</select>
</div>
<input type="hidden" name="" value="" class="sortBy">

@ -200,6 +200,14 @@
<script type="text/javascript">
$(function(){
var CHECK = {
number: /^\d+(\.{1}\d+)?$/,
mobile:/^1[3456789]\d{9}$/,
BankNo:/^([1-9]{1})(\d{15}|\d{18})$/,
money:/((^[1-9]\d*)|^0)(\.\d{0,2}){0,1}$/
}
var queryData = [];
var statement = [];
var key = 0;
@ -211,6 +219,7 @@
//搜索功能
$("#ext_field").change(function(){
key = 0;
var ext_field = $("#ext_field").val();
console.log(ext_field);
$("tbody").empty();
@ -259,7 +268,7 @@
console.log(data)
for (var i in data){
if (data[i].company_id) {
add += "<option company_id='" + data[i].company_id + "' value='" + data[i].company_id + "' " + ('selected') + ">" + data[i].company_name + "</option>"
add += "<option company_id='" + data[i].company_id + "' value='" + data[i].company_name + "' " + ('selected') + ">" + data[i].company_name + "</option>"
}
}
$("#company_name").empty();
@ -334,6 +343,7 @@
//搜索功能
$("#company_name").change(function(){
key = 0;
var ext_field = $("#company_name option:selected").attr('company_id');
console.log(ext_field);
$("tbody").empty();
@ -462,6 +472,12 @@
function eventnew(){
$(".tax").off("blur");
$(".tax").on("blur", function() {
if (!CHECK.number.test($(this).val())) {
layer.msg("结算单的罚款与税率必须是数字且不能为空");
$(this).val('0');
}
var lastNum = (parseFloat($(this).parent().next().text())).toFixed(2);
$(this).parent().next().text(($(this).parent().next().attr('data-value')*(1-$(this).val()/100)).toFixed(2));
var nowNum = (parseFloat($(this).parent().next().text())).toFixed(2);
@ -471,8 +487,15 @@
$(".forfeit").off("blur");
$(".forfeit").on("blur", function() {
var lastNumber = $(this).parent().next().next().next().text();
if(!$(this).val()||!CHECK.number.test($(this).val())) {
layer.msg("结算单的罚款与税率必须是数字且不能为空");
$(this).val(lastNumber);
return;
}
$(this).parent().next().next().next().text(parseFloat($(this).val()).toFixed(2));
$(".sumAmount").text($(".sumAmount").attr("data-value")-$(this).val());

@ -52,7 +52,7 @@
</div>
<div class="input-list input-list-promote search_label_rehab" style="width: 50%">
银行账号:
<input type="text" readonly id="bank_card" name="bank_card" class="" value="" placeholder="银行账号" style="width: 50%"/>
<input type="text" id="bank_card" name="bank_card" class="" value="" placeholder="银行账号" style="width: 50%"/>
</div>
<div class="input-list input-list-promote search_label_rehab" style="width: 50%">
@ -177,6 +177,13 @@
var statement = [];
var key = 0;
var CHECK = {
number: /^\d+(\.{1}\d+)?$/,
mobile:/^1[3456789]\d{9}$/,
BankNo:/^([1-9]{1})(\d{15}|\d{18})$/,
money:/((^[1-9]\d*)|^0)(\.\d{0,2}){0,1}$/
}
//搜索功能
$("#ext_field").change(function(){
var ext_field = $("#ext_field").val();
@ -204,7 +211,7 @@
success:function(data){
console.log($("#company_name option:selected").attr('company-type'))
$("#company_name").val(data.data.company_name);
$("#company_name").append("<option value='"+data.data.company_name+"' selected='selected'>"+data.data.company_name+"</option>");
$("#settlement_type").text(data.data.settlement_type);
$("#bank_card").val(data.data.bank_card);
$("#account_openin").val(data.data.account_openin);
@ -287,6 +294,12 @@
$(".tax").off("blur");
$(".tax").on("blur", function() {
var lastNum = (parseFloat($(this).parent().next().text())).toFixed(2);
if (!CHECK.number.test($(this).val())) {
layer.msg("结算单的罚款与税率必须是数字且不能为空");
$(this).val('0');
}
$(this).parent().next().text(($(this).parent().next().attr('data-value')*(1-$(this).val()/100)).toFixed(2));
var nowNum = (parseFloat($(this).parent().next().text())).toFixed(2);
console.log((nowNum-lastNum))
@ -297,6 +310,12 @@
$(".forfeit").on("blur", function() {
var lastNumber = $(this).parent().next().next().next().text();
if(!$(this).val()||!CHECK.number.test($(this).val())) {
layer.msg("结算单的罚款与税率必须是数字且不能为空");
$(this).val(lastNumber);
return;
}
$(this).parent().next().next().next().text(parseFloat($(this).val()).toFixed(2));
$(".sumAmount").text(($(".sumAmount").attr("data-value")-$(this).val()).toFixed(2));

@ -139,7 +139,7 @@
</td>
</tr>
</volist>
<tr><td>合计</td><td colspan="10">公司对账金额合计:{$sum[0]}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cp对账金额合计{$sum[1]}</td></tr>
<tr><td>合计</td><td colspan="10">公司对账金额合计:{$sum[1]}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;cp对账金额合计{$sum[0]}</td></tr>
</notemtpy>
</tbody>
</table>

@ -0,0 +1,19 @@
<?php
namespace Base\Service;
use Base\Facade\Request;
class GameService {
const DOWNLOAD_SUPER = 4;
const DOWNLOAD_BETA = 2;
const DOWNLOAD_NORMAL = 1;
public function getDownLoadWaysValue(array $downloadWays)
{
$value = 0;
foreach ($downloadWays as $downloadWay) {
$value |= $downloadWay;
}
return $value;
}
}

@ -0,0 +1,40 @@
<?php
namespace Base\Tool;
use GuzzleHttp\Client;
class TaskClient
{
const SUCCESS = '0000';
protected $client;
public function __construct()
{
$this->client = new Client([
'base_uri' => C('TASK_URL'),
'timeout' => 10.0,
]);
}
protected function post($uri, $data)
{
$response = $this->client->post($uri, [
'verify' => false,
'form_params' => $data
]);
$result = (string)$response->getBody();
return json_decode($result, true);
}
public function sendSms($mobile, $clientIp, $type = 'common')
{
return $this->post('/message/sms-send', ['mobile' => $mobile, 'type' => $type, 'client_ip' => $clientIp]);
}
public function checkSms($mobile, $code)
{
return $this->post('/message/sms-check', ['mobile' => $mobile, 'code' => $code]);
}
}

@ -1,5 +1,6 @@
<?php
namespace Common\Controller;
use Think\Controller;
use Org\XiguSDK\Xigu;
use Think\Exception;

@ -1623,8 +1623,6 @@ class ApplyController extends BaseController
$promotes = getAllPromoteListByType($promoteType);
M('apply', 'tab_')->where(array('game_id' => $gameId, 'promote_id' => $value['id'], 'offline_status' => 0))->count('id');
$newPromoteData = [];
if (count($promotes) > 0) {
@ -1636,13 +1634,6 @@ class ApplyController extends BaseController
$newPromoteData[] = $promote;
}
}
/* foreach ($promoteIds as $value) {
$thisPromote = M('apply', 'tab_')->where(array('game_id' => $gameId, 'promote_id' => $value['id'], 'offline_status' => 0))->count('id');
if (!$thisPromote) {
$newPromoteData[] = $value;
}
} */
}
$data['game_data'] = $gameData;

@ -3,10 +3,23 @@
namespace Home\Controller;
use Think\Controller;
use Base\Service\PromoteService;
class BaseController extends HomeController
{
protected $promotePermissions;
protected $loginPromote = null;
protected $canViewUserRecharge = true;
protected $permControlUrls = [
'Home/Query/recharge',
'Home/Players/playAction',
'Home/Query/userRecharges',
'Home/Query/arpu',
'Home/Finance/index',
'Home/Finance/settlementDtl',
'Home/Finance/withdrawRecord',
];
protected function _initialize()
{
@ -15,7 +28,7 @@ class BaseController extends HomeController
$this->login();
$loginer = $this->getLoginPromote();
$this->certifiCation();
// $this->certifiCation();
$pid = is_login_promote();
define('PLEVEL', $loginer['parent_id']);
define('PID', $pid);
@ -33,9 +46,13 @@ class BaseController extends HomeController
define('G_SETTLEMENT_GRADE', 'sub_status,third_status');
}
$this->canViewUserRecharge = $this->promoteCan('view-user-recharge');
$this->checkUrlPermission();
$this->assign('loginer', $loginer);
$this->assign("parent_id", $loginer['parent_id']);
$this->assign("grand_id", $loginer['grand_id']);
$this->assign('canViewUserRecharge', $this->canViewUserRecharge);
$result = M('site_apply', 'tab_')->where("promote_id=$pid")->getField('status');
if ($result['status'] == 1) {
@ -342,4 +359,37 @@ class BaseController extends HomeController
break;
}
}
public function checkUrlPermission()
{
$currentUrl = MODULE_NAME . '/' . CONTROLLER_NAME . '/' . ACTION_NAME;
if (!$this->canViewUserRecharge) {
foreach ($this->permControlUrls as $url) {
if (strtolower($currentUrl) == strtolower($url)) {
$this->error('无权限查看');
}
}
}
}
public function promoteCan($permission)
{
$promote = $this->getLoginPromote();
if (!$promote) {
return false;
}
if ($permission == 'recharge') {
if ($promote['level'] == 1) {
return true;
}
}
if ($permission == 'view-user-recharge') {
$promoteService = new PromoteService();
$topPromote = $promoteService->getTopPromote($promote);
if ($topPromote['can_view_recharge'] == 1) {
return true;
}
}
return false;
}
}

@ -90,14 +90,7 @@ class CoinOrderController extends BaseController
//创建订单
public function order_add(){
$status = promoteCan(session('promote_auth.pid'), function($level) {
if ($level == 1) {
return true;
} else {
return false;
}
});
$status = $this->promoteCan('recharge');
if (!$status) {
if (IS_POST) {
$this->ajaxReturn(array('status' => 0, 'msg'=>'无权限操作'));

@ -2023,24 +2023,25 @@ class DownloadController extends BaseController {
public function summaryExcelInfo($id,$map) {
$xlsName = "数据汇总";
$xlsCell = array(
array('game_name','游戏名称'),
array('sdk_version','平台'),
array('role_num','创角数'),
array('user_num','创建用户'),
array('new_user_num','新创角用户'),
array('new_device_num','新创角设备'),
array('new_ip_num','新增创角ip'),
array('login_user_num','登陆用户数'),
array('spend_user_num','充值人数'),
array('spend_num','充值次数'),
array('spend_all_amount','充值总额'),
array('spend_cash','现金充值'),
array('spend_generic','通用币充值'),
array('spend_binding','绑定币充值'),
array('spend_discount','折扣币充值'),
array('spend_voucher','代金券使用'),
);
array('game_name','游戏名称'),
array('sdk_version','平台'),
array('role_num','创角数'),
array('user_num','创建用户'),
array('new_user_num','新创角用户'),
array('new_device_num','新创角设备'),
array('new_ip_num','新增创角ip'),
array('login_user_num','登陆用户数'),
);
if($this->canViewUserRecharge) {
$xlsCell[] = array('spend_user_num','充值人数');
$xlsCell[] = array('spend_num','充值次数');
$xlsCell[] = array('spend_all_amount','充值总额');
$xlsCell[] = array('spend_cash','现金充值');
$xlsCell[] = array('spend_generic','通用币充值');
$xlsCell[] = array('spend_binding','绑定币充值');
$xlsCell[] = array('spend_discount','折扣币充值');
$xlsCell[] = array('spend_voucher','代金券使用');
}
if(!empty($map['tab_apply.promote_id'][1])) {
$params['promote_ids'] = $map['tab_apply.promote_id'][1];
}
@ -2135,20 +2136,33 @@ class DownloadController extends BaseController {
$allData['new_user_num'] = $userRepository->getNewCreateRoleUserCountByGame($params);//新创角用户
$allData['new_device_num'] = $userRepository->getNewCreateRoleDeviceCountByGame($params);//新创角设备
$allData['new_ip_num'] = $userRepository->getNewCreateRoleIpCountByGame($params);//新创角IP
$allData['login_user_num'] = $userRepository->getLoginCountGroupByGame($params);//登录用户数
$allData['spend_user_num'] = $spendRepository->getPayUserCountByGame($params);//充值人数
$allData['spend_num'] = $spendRepository->getPayCountByGame($params);//充值次数
unset($params['pay_way']);
$allData['spend_all_amount'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//充值总额
$params['pay_way'] = ['in', '1,2,3,4,5,6'];
$allData['spend_cash'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//现金充值
$params['pay_way'] = 0;
$allData['spend_generic'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//通用币充值
$params['pay_way'] = -1;
$allData['spend_binding'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//绑定币充值
$allData['spend_discount'] = '0.00';
$allData['spend_voucher'] = '0.00';
$records[] = $allData;
$allData['login_user_num'] = $userRepository->getLoginCountGroupByGame($params);//登录用户数
if($this->canViewUserRecharge) {
$record['spend_user_num'] = $spendUserNumList[$gameId];
$record['spend_num'] = $spendNumList[$gameId];
$record['spend_all_amount'] = $spendAllAmountList[$gameId];
$record['spend_cash'] = $spendCashList[$gameId];
$record['spend_generic'] = $spendGenericList[$gameId];
$record['spend_binding'] = $spendBindingList[$gameId];
$record['spend_discount'] = 0;
$record['spend_voucher'] = 0;
$allData['spend_user_num'] = $spendRepository->getPayUserCountByGame($params);//充值人数
$allData['spend_num'] = $spendRepository->getPayCountByGame($params);//充值次数
unset($params['pay_way']);
$allData['spend_all_amount'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//充值总额
$params['pay_way'] = ['in', '1,2,3,4,5,6'];
$allData['spend_cash'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//现金充值
$params['pay_way'] = 0;
$allData['spend_generic'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//通用币充值
$params['pay_way'] = -1;
$allData['spend_binding'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//绑定币充值
$allData['spend_discount'] = '0.00';
$allData['spend_voucher'] = '0.00';
}
$records[] = $record;
$records[] = $allData;
}
}
@ -2199,10 +2213,11 @@ class DownloadController extends BaseController {
if($value1['status'] == 2) {
$value1['promotestatus'] = "冻结中";
}
$value1['account'] = substr_replace($value1['account'],'****',2);
$realname = mb_strlen($value1['real_name'],'utf-8') == 2 ? mb_substr($value1['real_name'],0,1,'utf-8').'*':mb_substr($value1['real_name'],0,1,'utf-8').'**';
$value1['real_name'] = $realname;
$value1['idcard'] = substr_replace($value1['idcard'],'************',3,12);
$value1['create_time'] = date('Y-m-d H:i:s',$value1['create_time']);
$xlsData[] = $value1;
$value1['create_time'] = date('Y-m-d H:i:s',$value1['create_time']);
$xlsData[] = $value1;
}
$this->exportExcel($xlsName, $xlsCell, $xlsData,$id);
}
@ -2887,23 +2902,26 @@ class DownloadController extends BaseController {
public function dailysummaryExcelInfo($id,$map) {
$xlsName = "每日概况";
$xlsCell = array(
array('day','日期'),
array('role_num','创角数'),
array('user_num','创角用户'),
array('new_user_num','新创角用户'),
array('new_device_num','新创角设备'),
array('new_ip_num','新增创角IP'),
array('login_user_num','登陆用户数'),
array('spend_user_num','充值人数'),
array('spend_num','充值次数'),
array('spend_all_amount','充值总额'),
array('spend_cash','现金充值'),
array('spend_generic','通用币充值'),
array('spend_binding','绑定币充值'),
array('spend_discount','折扣币充值'),
array('spend_voucher','代金劵使用'),
);
array('day','日期'),
array('role_num','创角数'),
array('user_num','创角用户'),
array('new_user_num','新创角用户'),
array('new_device_num','新创角设备'),
array('new_ip_num','新增创角IP'),
array('login_user_num','登陆用户数'),
);
if ($this->canViewUserRecharge) {
$xlsCell[] = array('spend_user_num','充值人数');
$xlsCell[] = array('spend_num','充值次数');
$xlsCell[] = array('spend_all_amount','充值总额');
$xlsCell[] = array('spend_cash','现金充值');
$xlsCell[] = array('spend_generic','通用币充值');
$xlsCell[] = array('spend_binding','绑定币充值');
$xlsCell[] = array('spend_discount','折扣币充值');
$xlsCell[] = array('spend_voucher','代金劵使用');
}
$nowTime = date('Y-m-d');
$initBegTime = date('Y-m-d', strtotime('-6 day', strtotime($nowTime)));
$initBegTime = empty(I('begtime')) ? $initBegTime : I('begtime');
@ -2932,7 +2950,6 @@ class DownloadController extends BaseController {
}
$params['dayList'] = $map["dayList"];
$summaryData = [];
$records = [];
if (intval($endTime - $begTime) / (24 * 3600) <= 30) {
$userRepository = new UserRepository();
$spendRepository = new SpendRepository();
@ -2957,14 +2974,16 @@ class DownloadController extends BaseController {
$allData['new_device_num'] = 0;
$allData['new_ip_num'] = 0;
$allData['login_user_num'] = 0;
$allData['spend_user_num'] = 0;
$allData['spend_num'] = 0;
$allData['spend_all_amount'] = 0;
$allData['spend_cash'] = 0;
$allData['spend_generic'] = 0;
$allData['spend_binding'] = 0;
$allData['spend_discount'] = 0;
$allData['spend_voucher'] = 0;
if($this->canViewUserRecharge) {
$allData['spend_user_num'] = 0;
$allData['spend_num'] = 0;
$allData['spend_all_amount'] = 0;
$allData['spend_cash'] = 0;
$allData['spend_generic'] = 0;
$allData['spend_binding'] = 0;
$allData['spend_discount'] = 0;
$allData['spend_voucher'] = 0;
}
foreach ($params['dayList'] as $day) {
$date = date('Ymd', strtotime($day));
$records[] = [
@ -2990,15 +3009,26 @@ class DownloadController extends BaseController {
$allData['new_device_num'] += $newDeviceNumList[$day];
$allData['new_ip_num'] += $newIpNumList[$day];
$allData['login_user_num'] += $loginUserNumList[$day];
$allData['spend_user_num'] += $spendUserNumList[$day];
$allData['spend_num'] += $spendNumList[$day];
$allData['spend_all_amount'] = bcadd($allData['spend_all_amount'], $spendAllAmountList[$day], 2);
$allData['spend_cash'] = bcadd($allData['spend_cash'], $spendCashList[$day], 2);
$allData['spend_generic'] = bcadd($allData['spend_generic'], $spendGenericList[$day], 2);
$allData['spend_binding'] = bcadd($allData['spend_binding'], $spendBindingList[$day], 2);
$allData['spend_discount'] = bcadd($allData['spend_discount'], 0, 2);
$allData['spend_voucher'] = bcadd($allData['spend_voucher'], 0, 2);
if ($this->canViewUserRecharge) {
$record['spend_user_num'] = $spendUserNumList[$day];
$record['spend_num'] = $spendNumList[$day];
$record['spend_all_amount'] = $$spendAllAmountList[$day];
$record['spend_cash'] = $spendCashList[$day];
$record['spend_generic'] = $spendGenericList[$day];
$record['spend_binding'] = $spendBindingList[$day];
$record['spend_discount'] = 0;
$record['spend_voucher'] = 0;
$allData['spend_user_num'] += $spendUserNumList[$day];
$allData['spend_num'] += $spendNumList[$day];
$allData['spend_all_amount'] = bcadd($allData['spend_all_amount'], $spendAllAmountList[$day], 2);
$allData['spend_cash'] = bcadd($allData['spend_cash'], $spendCashList[$day], 2);
$allData['spend_generic'] = bcadd($allData['spend_generic'], $spendGenericList[$day], 2);
$allData['spend_binding'] = bcadd($allData['spend_binding'], $spendBindingList[$day], 2);
$allData['spend_discount'] = bcadd($allData['spend_discount'], 0, 2);
$allData['spend_voucher'] = bcadd($allData['spend_voucher'], 0, 2);
}
$records[] = $record;
}
$allData['day'] = '合计';
$records[] = $allData;
@ -3016,22 +3046,22 @@ class DownloadController extends BaseController {
public function achievementExcelInfo($tid,$map) {
$xlsName = "推广员业绩";
$xlsCell = array(
array('account','账号'),
array('real_name','姓名'),
array('create_role_count','创角数'),
array('create_role_user_count','创角用户'),
array('new_create_role_user_count','新创角用户'),
array('new_create_role_ip_count','新创角ip'),
array('login_user_count','登陆用户数'),
array('recharge_user_count','充值人数'),
array('recharge_count','充值次数'),
array('recharge_amount','充值总额'),
array('recharge_by_ban_coin','绑定币充值'),
array('recharge_by_coin','通用币充值'),
array('recharge_by_cash','现金充值'),
);
array('account','账号'),
array('real_name','姓名'),
array('create_role_count','创角数'),
array('create_role_user_count','创角用户'),
array('new_create_role_user_count','新创角用户'),
array('new_create_role_ip_count','新创角ip'),
array('login_user_count','登陆用户数'),
);
if ($this->canViewUserRecharge) {
$xlsCell[] = array('recharge_user_count','充值人数');
$xlsCell[] = array('recharge_count','充值次数');
$xlsCell[] = array('recharge_amount','充值总额');
$xlsCell[] = array('recharge_by_ban_coin','绑定币充值');
$xlsCell[] = array('recharge_by_coin','通用币充值');
$xlsCell[] = array('recharge_by_cash','现金充值');
}
$params['isContainSubs'] = $map['isContainSubs'];
$params['basicPromotes'] = json_decode($map['basicPromotes'],TRUE);
$ids = $map['ids'];
@ -3067,9 +3097,16 @@ class DownloadController extends BaseController {
$newCreateRoleDeviceCountList = $promoteRepository->getNewCreateRoleDeviceCountByIds($ids, $params);
$newCreateRoleIpCountList = $promoteRepository->getNewCreateRoleIpCountByIds($ids, $params);
$loginUserCountList = $promoteRepository->getLoginUserCountByIds($ids, $params);
$rechargeCountList = $promoteRepository->getRechargeCountByIds($ids, $params);
$rechargeUserCountList = $promoteRepository->getRechargeUserCountByIds($ids, $params);
$rechargeAmountList = $promoteRepository->getRechargeAmountByIds($ids, $params);
$rechargeCountList = [];
$rechargeUserCountList = [];
$rechargeAmountList = [];
if ($this->canViewUserRecharge) {
$rechargeCountList = $promoteRepository->getRechargeCountByIds($ids, $params);
$rechargeUserCountList = $promoteRepository->getRechargeUserCountByIds($ids, $params);
$rechargeAmountList = $promoteRepository->getRechargeAmountByIds($ids, $params);
}
$records = [];
if (I('p', 1) == 1) {
$selfParams = $params;
@ -3079,15 +3116,11 @@ class DownloadController extends BaseController {
$selfNewCreateRoleUserCountList = $promoteRepository->getNewCreateRoleUserCountByIds([$parent['id']], $selfParams);
// $selfNewCreateRoleDeviceCountList = $promoteRepository->getNewCreateRoleDeviceCountByIds([$parent['id']], $selfParams);
$selfNewCreateRoleIpCountList = $promoteRepository->getNewCreateRoleIpCountByIds([$parent['id']], $selfParams);
$selfLoginUserCountList = $promoteRepository->getLoginUserCountByIds([$parent['id']], $selfParams);
$selfRechargeCountList = $promoteRepository->getRechargeCountByIds([$parent['id']], $selfParams);
$selfRechargeUserCountList = $promoteRepository->getRechargeUserCountByIds([$parent['id']], $selfParams);
$selfRechargeAmountList = $promoteRepository->getRechargeAmountByIds([$parent['id']], $selfParams);
$records[] = [
$record = [
'id' => $parent['id'],
'account' => $parent['account'],
'real_name' => $parent['real_name'],
'real_name' => mb_strlen($parent['real_name'],'utf-8') == 2 ? mb_substr($parent['real_name'],0,1,'utf-8').'*':mb_substr($parent['real_name'],0,1,'utf-8').'**',
'level' => $parent['level'],
'create_role_count' => $selfCreateRoleCountList[$parent['id']],
'create_role_user_count' => $selfCreateRoleUserCountList[$parent['id']],
@ -3095,21 +3128,27 @@ class DownloadController extends BaseController {
// 'new_create_role_device_count' => $selfNewCreateRoleDeviceCountList[$parent['id']],
'new_create_role_ip_count' => $selfNewCreateRoleIpCountList[$parent['id']],
'login_user_count' => $selfLoginUserCountList[$parent['id']],
'recharge_count' => $selfRechargeCountList[$parent['id']],
'recharge_user_count' => $selfRechargeUserCountList[$parent['id']],
'recharge_amount' => $selfRechargeAmountList[$parent['id']]['ban_coin'] + $selfRechargeAmountList[$parent['id']]['coin'] + $selfRechargeAmountList[$parent['id']]['cash'],
'recharge_by_ban_coin' => $selfRechargeAmountList[$parent['id']]['ban_coin'],
'recharge_by_coin' => $selfRechargeAmountList[$parent['id']]['coin'],
'recharge_by_cash' => $selfRechargeAmountList[$parent['id']]['cash'],
'current_display' => $currentDisplay,
];
if ($this->canViewUserRecharge) {
$selfRechargeCountList = $promoteRepository->getRechargeCountByIds([$parent['id']], $selfParams);
$selfRechargeUserCountList = $promoteRepository->getRechargeUserCountByIds([$parent['id']], $selfParams);
$selfRechargeAmountList = $promoteRepository->getRechargeAmountByIds([$parent['id']], $selfParams);
$record['recharge_count'] = $selfRechargeCountList[$parent['id']];
$record['recharge_user_count'] = $selfRechargeUserCountList[$parent['id']];
$record['recharge_amount'] = $selfRechargeAmountList[$parent['id']]['ban_coin'] + $selfRechargeAmountList[$parent['id']]['coin'] + $selfRechargeAmountList[$parent['id']]['cash'];
$record['recharge_by_ban_coin'] = $selfRechargeAmountList[$parent['id']]['ban_coin'];
$record['recharge_by_coin'] = $selfRechargeAmountList[$parent['id']]['coin'];
$record['recharge_by_cash'] = $selfRechargeAmountList[$parent['id']]['cash'];
}
$records[] = $record;
}
foreach ($promotes as $promote) {
$id = $promote['id'];
$records[] = [
$record = [
'id' => $id,
'account' => $promote['account'],
'real_name' => $promote['real_name'],
'real_name' => mb_strlen($promote['real_name'],'utf-8') == 2 ? mb_substr($promote['real_name'],0,1,'utf-8').'*':mb_substr($promote['real_name'],0,1,'utf-8').'**',
'level' => $promote['level'],
'create_role_count' => $createRoleCountList[$id],
'create_role_user_count' => $createRoleUserCountList[$id],
@ -3117,14 +3156,17 @@ class DownloadController extends BaseController {
'new_create_role_device_count' => $newCreateRoleDeviceCountList[$id],
'new_create_role_ip_count' => $newCreateRoleIpCountList[$id],
'login_user_count' => $loginUserCountList[$id],
'recharge_count' => $rechargeCountList[$id],
'recharge_user_count' => $rechargeUserCountList[$id],
'recharge_amount' => $rechargeAmountList[$id]['ban_coin'] + $rechargeAmountList[$id]['coin'] + $rechargeAmountList[$id]['cash'],
'recharge_by_ban_coin' => $rechargeAmountList[$id]['ban_coin'],
'recharge_by_coin' => $rechargeAmountList[$id]['coin'],
'recharge_by_cash' => $rechargeAmountList[$id]['cash'],
'current_display' => '',
];
if ($this->canViewUserRecharge) {
$record['recharge_count'] = $rechargeCountList[$id];
$record['recharge_user_count'] = $rechargeUserCountList[$id];
$record['recharge_amount'] = $rechargeAmountList[$id]['ban_coin'] + $rechargeAmountList[$id]['coin'] + $rechargeAmountList[$id]['cash'];
$record['recharge_by_ban_coin'] = $rechargeAmountList[$id]['ban_coin'];
$record['recharge_by_coin'] = $rechargeAmountList[$id]['coin'];
$record['recharge_by_cash'] = $rechargeAmountList[$id]['cash'];
}
$records[] = $record;
}
$xlsData = [];
foreach ($records as $key1 => $value1) {

@ -529,7 +529,7 @@ class FinanceController extends BaseController
if ($withdrawId == 0) {
$this->error('参数异常');
}
$withdraw = $model->field('promote_id,status')->where(array('id' => $withdrawId))->find();
$withdraw = $model->where(array('id' => $withdrawId))->find();
if (empty($withdraw) || $withdraw['promote_id'] != $this->loginPromote['id']) {
$this->error('参数异常');
}
@ -544,7 +544,18 @@ class FinanceController extends BaseController
$parameter['user_account'] = $userAccount;
$parameter['pay_order_number'] = $payOrderNumber;
$map['withdraw_id'] = $withdrawId;
if ($withdraw['settlement_type'] == 3) {
if (empty($withdraw['game_ratio'])) {
$map['_string'] = '1 = 2';
} else {
$gameRatios = json_decode($withdraw['game_ratio'], true);
$gameIds = array_keys($gameRatios);
$map['game_id'] = ['in', $gameIds];
$map['pay_time'] = ['between', [$withdraw['settlement_begin_time'], $withdraw['settlement_end_time']]];
}
} else {
$map['withdraw_id'] = $withdrawId;
}
if (!empty($gameId)) {
$map['game_id'] = $gameId;
}
@ -613,20 +624,40 @@ class FinanceController extends BaseController
if (empty($withdraw) || $withdraw['promote_id'] != $this->loginPromote['id']) {
$this->error('参数异常');
}
$settlementBeginTime = $withdraw['settlement_begin_time'];
$settlementEndTime = $withdraw['settlement_end_time'];
$withdraw['create_time'] = date('Y-m-d H:i:s', $withdraw['create_time']);
$withdraw['settlement_end_time'] = date('Y-m-d H:i:s', $withdraw['settlement_end_time']);
$withdraw['status'] = FinanceController::$withdrawStatus[$withdraw['status']];
$map['withdraw_id'] = $withdrawId;
if (empty($withdraw['game_ratio'])) {
$map['_string'] = '1 = 2';
} else {
$gameRatios = json_decode($withdraw['game_ratio'], true);
$gameIds = array_keys($gameRatios);
$map['game_id'] = ['in', $gameIds];
$map['pay_time'] = ['between', [$settlementBeginTime, $settlementEndTime]];
}
if ($withdraw['settlement_type'] != 3) {
$map['withdraw_id'] = $withdrawId;
}
$data = M('spend', 'tab_')
->field('game_name,if(selle_ratio >= 0,selle_ratio,0) as selle_ratio,pay_way,sum(pay_amount) as pay_amount_all,sum(if(selle_ratio > 0,pay_amount * selle_ratio,0)) as income')
->field('game_id,game_name,if(selle_ratio >= 0,selle_ratio,0) as selle_ratio,pay_way,sum(pay_amount) as pay_amount_all,sum(if(selle_ratio > 0,pay_amount * selle_ratio,0)) as income')
->where($map)
->group('game_id')
->order('game_id')
->select();
if (!empty($data)) {
foreach ($data as &$list) {
$list['income'] = bcdiv($list['income'], 100, 2);
$list['income'] = '0.00';
if (isset($gameRatios[$list['game_id']])) {
foreach ($gameRatios[$list['game_id']] as $gameIncome) {
$income = bcdiv(bcmul($gameIncome['sum_amount'], $gameIncome['selle_ratio'], 2), 100, 2);
$list['income'] = bcadd($list['income'], $income, 2);
}
}
}
}

@ -187,10 +187,9 @@ class HomeController extends Controller
'introduction',
'flooring_page_video',
'flooring_page_video_cover',
'supersign_status',
'ios_video_top',
'beta_status',
'beta_url',
'download_ways'
];
$map = ['id' => intval($gameId)];
$game = M('game', 'tab_')->field($columns)->where($map)->find();

@ -87,7 +87,7 @@ class PackageController extends Controller
} else if (Request::isIOS()) {
$plistUrl = substr($packageUrl, 1, strlen($packageUrl));
header("HTTP/1.1 303 See Other");
header("Location: "."itms-services://?action=download-manifest&url=" . Request::getHost() . "/" . $plistUrl);
header("Location: "."itms-services://?action=download-manifest&url=" . C('DOMAIN_DOWNLOAD') . '/' . ltrim($plistUrl, '/'));
} else {
$this->gotoPkgUrl($packageUrl);
}

@ -557,6 +557,17 @@ class PromoteController extends BaseController
->where("qmn.status=0")
->order("qmn.id asc")
->select();
if (!$this->canViewUserRecharge) {
foreach ($data_list as $key => $item) {
foreach ($this->permControlUrls as $url) {
if (stripos($item['url'], $url) !== false) {
unset($data_list[$key]);
}
}
}
}
$this->assign("data_list", $data_list);
$this->meta_title = "快捷菜单";
$this->display();
@ -972,6 +983,8 @@ class PromoteController extends BaseController
list($records, $pagination, $count) = $this->paginate($query);
foreach ($records as $key => $value) {
$realname = mb_strlen($value['real_name'],'utf-8') == 2 ? mb_substr($value['real_name'],0,1,'utf-8').'*':mb_substr($value['real_name'],0,1,'utf-8').'**';
$records[$key]['real_name'] = $realname;
$records[$key]['idcard'] = encryption($value['idcard']);
$records[$key]['mobile_phone'] = encryption($value['mobile_phone']);
}

@ -1128,15 +1128,17 @@ class QueryController extends BaseController
$newDeviceNumList = $userRepository->getNewCreateRoleDeviceCountByDay($params);//新创角设备
$newIpNumList = $userRepository->getNewCreateRoleIpCountByDay($params);//新创角IP
$loginUserNumList = $userRepository->getLoginCountGroupByDayNew($params);//登录用户数
$spendUserNumList = $spendRepository->getPayUserCountGroupByDayNew($params);//充值人数
$spendNumList = $spendRepository->getPayCountGroupByDay($params);//充值次数
$spendAllAmountList = $spendRepository->getPayAmountGroupByDayAndType($params);//充值总额
$params['pay_way'] = ['in', '1,2,3,4,5,6'];
$spendCashList = $spendRepository->getPayAmountGroupByDayAndType($params);//现金充值
$params['pay_way'] = 0;
$spendGenericList = $spendRepository->getPayAmountGroupByDayAndType($params);//通用币充值
$params['pay_way'] = -1;
$spendBindingList = $spendRepository->getPayAmountGroupByDayAndType($params);//绑定币充值
if ($this->canViewUserRecharge) {
$spendUserNumList = $spendRepository->getPayUserCountGroupByDayNew($params);//充值人数
$spendNumList = $spendRepository->getPayCountGroupByDay($params);//充值次数
$spendAllAmountList = $spendRepository->getPayAmountGroupByDayAndType($params);//充值总额
$params['pay_way'] = ['in', '1,2,3,4,5,6'];
$spendCashList = $spendRepository->getPayAmountGroupByDayAndType($params);//现金充值
$params['pay_way'] = 0;
$spendGenericList = $spendRepository->getPayAmountGroupByDayAndType($params);//通用币充值
$params['pay_way'] = -1;
$spendBindingList = $spendRepository->getPayAmountGroupByDayAndType($params);//绑定币充值
}
$allData['role_num'] = 0;
$allData['user_num'] = 0;
@ -1144,17 +1146,19 @@ class QueryController extends BaseController
$allData['new_device_num'] = 0;
$allData['new_ip_num'] = 0;
$allData['login_user_num'] = 0;
$allData['spend_user_num'] = 0;
$allData['spend_num'] = 0;
$allData['spend_all_amount'] = 0;
$allData['spend_cash'] = 0;
$allData['spend_generic'] = 0;
$allData['spend_binding'] = 0;
$allData['spend_discount'] = 0;
$allData['spend_voucher'] = 0;
if ($this->canViewUserRecharge) {
$allData['spend_user_num'] = 0;
$allData['spend_num'] = 0;
$allData['spend_all_amount'] = 0;
$allData['spend_cash'] = 0;
$allData['spend_generic'] = 0;
$allData['spend_binding'] = 0;
$allData['spend_discount'] = 0;
$allData['spend_voucher'] = 0;
}
foreach ($dayList as $day) {
$date = date('Ymd', strtotime($day));
$records[] = [
$record = [
'day' => $date,
'role_num' => $roleNumList[$day],
'user_num' => $userNumList[$day],
@ -1162,14 +1166,6 @@ class QueryController extends BaseController
'new_device_num' => $newDeviceNumList[$day],
'new_ip_num' => $newIpNumList[$day],
'login_user_num' => $loginUserNumList[$day],
'spend_user_num' => $spendUserNumList[$day],
'spend_num' => $spendNumList[$day],
'spend_all_amount' => $spendAllAmountList[$day],
'spend_cash' => $spendCashList[$day],
'spend_generic' => $spendGenericList[$day],
'spend_binding' => $spendBindingList[$day],
'spend_discount' => 0,
'spend_voucher' => 0,
];
$allData['role_num'] += $roleNumList[$day];
@ -1178,14 +1174,27 @@ class QueryController extends BaseController
$allData['new_device_num'] += $newDeviceNumList[$day];
$allData['new_ip_num'] += $newIpNumList[$day];
$allData['login_user_num'] += $loginUserNumList[$day];
$allData['spend_user_num'] += $spendUserNumList[$day];
$allData['spend_num'] += $spendNumList[$day];
$allData['spend_all_amount'] = bcadd($allData['spend_all_amount'], $spendAllAmountList[$day], 2);
$allData['spend_cash'] = bcadd($allData['spend_cash'], $spendCashList[$day], 2);
$allData['spend_generic'] = bcadd($allData['spend_generic'], $spendGenericList[$day], 2);
$allData['spend_binding'] = bcadd($allData['spend_binding'], $spendBindingList[$day], 2);
$allData['spend_discount'] = bcadd($allData['spend_discount'], 0, 2);
$allData['spend_voucher'] = bcadd($allData['spend_voucher'], 0, 2);
if ($this->canViewUserRecharge) {
$record['spend_user_num'] = $spendUserNumList[$day];
$record['spend_num'] = $spendNumList[$day];
$record['spend_all_amount'] = $spendAllAmountList[$day];
$record['spend_cash'] = $spendCashList[$day];
$record['spend_generic'] = $spendGenericList[$day];
$record['spend_binding'] = $spendBindingList[$day];
$record['spend_discount'] = 0;
$record['spend_voucher'] = 0;
$allData['spend_user_num'] += $spendUserNumList[$day];
$allData['spend_num'] += $spendNumList[$day];
$allData['spend_all_amount'] = bcadd($allData['spend_all_amount'], $spendAllAmountList[$day], 2);
$allData['spend_cash'] = bcadd($allData['spend_cash'], $spendCashList[$day], 2);
$allData['spend_generic'] = bcadd($allData['spend_generic'], $spendGenericList[$day], 2);
$allData['spend_binding'] = bcadd($allData['spend_binding'], $spendBindingList[$day], 2);
$allData['spend_discount'] = bcadd($allData['spend_discount'], 0, 2);
$allData['spend_voucher'] = bcadd($allData['spend_voucher'], 0, 2);
}
$records[] = $record;
}
foreach ($dayListReverse as $day) {
$date = date('Ymd', strtotime($day));
@ -1194,8 +1203,10 @@ class QueryController extends BaseController
$summaryData['user_num'][] = $userNumList[$day];
$summaryData['new_user_num'][] = $newUserNumList[$day];
$summaryData['new_device_num'][] = $newDeviceNumList[$day];
$summaryData['spend_user_num'][] = $spendUserNumList[$day];
$summaryData['spend_all_amount'][] = $spendAllAmountList[$day];
if ($this->canViewUserRecharge) {
$summaryData['spend_user_num'][] = $spendUserNumList[$day];
$summaryData['spend_all_amount'][] = $spendAllAmountList[$day];
}
}
}
@ -1314,18 +1325,20 @@ class QueryController extends BaseController
$newDeviceNumList = $userRepository->getNewCreateRoleDeviceCountByGame($params);//新创角设备
$newIpNumList = $userRepository->getNewCreateRoleIpCountByGame($params);//新创角IP
$loginUserNumList = $userRepository->getLoginCountGroupByGame($params);//登录用户数
$spendUserNumList = $spendRepository->getPayUserCountGroupByGame($params);//充值人数
$spendNumList = $spendRepository->getPayCountGroupByGame($params);//充值次数
$spendAllAmountList = $spendRepository->getPayAmountGroupByGameAndType($params);//充值总额
$params['pay_way'] = ['in', '1,2,3,4,5,6'];
$spendCashList = $spendRepository->getPayAmountGroupByGameAndType($params);//现金充值
$params['pay_way'] = 0;
$spendGenericList = $spendRepository->getPayAmountGroupByGameAndType($params);//通用币充值
$params['pay_way'] = -1;
$spendBindingList = $spendRepository->getPayAmountGroupByGameAndType($params);//绑定币充值
if ($this->canViewUserRecharge) {
$spendUserNumList = $spendRepository->getPayUserCountGroupByGame($params);//充值人数
$spendNumList = $spendRepository->getPayCountGroupByGame($params);//充值次数
$spendAllAmountList = $spendRepository->getPayAmountGroupByGameAndType($params);//充值总额
$params['pay_way'] = ['in', '1,2,3,4,5,6'];
$spendCashList = $spendRepository->getPayAmountGroupByGameAndType($params);//现金充值
$params['pay_way'] = 0;
$spendGenericList = $spendRepository->getPayAmountGroupByGameAndType($params);//通用币充值
$params['pay_way'] = -1;
$spendBindingList = $spendRepository->getPayAmountGroupByGameAndType($params);//绑定币充值
}
foreach ($data as &$list) {
$gameId = $list['game_id'];
$records[] = [
$record = [
'game_id' => $gameId,
'game_name' => $list['game_name'],
'sdk_version' => $list['sdk_version'],
@ -1335,15 +1348,19 @@ class QueryController extends BaseController
'new_device_num' => $newDeviceNumList[$gameId],
'new_ip_num' => $newIpNumList[$gameId],
'login_user_num' => $loginUserNumList[$gameId],
'spend_user_num' => $spendUserNumList[$gameId],
'spend_num' => $spendNumList[$gameId],
'spend_all_amount' => $spendAllAmountList[$gameId],
'spend_cash' => $spendCashList[$gameId],
'spend_generic' => $spendGenericList[$gameId],
'spend_binding' => $spendBindingList[$gameId],
'spend_discount' => 0,
'spend_voucher' => 0,
];
if ($this->canViewUserRecharge) {
$record['spend_user_num'] = $spendUserNumList[$gameId];
$record['spend_num'] = $spendNumList[$gameId];
$record['spend_all_amount'] = $spendAllAmountList[$gameId];
$record['spend_cash'] = $spendCashList[$gameId];
$record['spend_generic'] = $spendGenericList[$gameId];
$record['spend_binding'] = $spendBindingList[$gameId];
$record['spend_discount'] = 0;
$record['spend_voucher'] = 0;
}
$records[] = $record;
}
$params['all_data'] = 1;
$params['game_ids'] = $allGameIs;
@ -1353,18 +1370,20 @@ class QueryController extends BaseController
$allData['new_device_num'] = $userRepository->getNewCreateRoleDeviceCountByGame($params);//新创角设备
$allData['new_ip_num'] = $userRepository->getNewCreateRoleIpCountByGame($params);//新创角IP
$allData['login_user_num'] = $userRepository->getLoginCountGroupByGame($params);//登录用户数
$allData['spend_user_num'] = $spendRepository->getPayUserCountByGame($params);//充值人数
$allData['spend_num'] = $spendRepository->getPayCountByGame($params);//充值次数
unset($params['pay_way']);
$allData['spend_all_amount'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//充值总额
$params['pay_way'] = ['in', '1,2,3,4,5,6'];
$allData['spend_cash'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//现金充值
$params['pay_way'] = 0;
$allData['spend_generic'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//通用币充值
$params['pay_way'] = -1;
$allData['spend_binding'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//绑定币充值
$allData['spend_discount'] = '0.00';
$allData['spend_voucher'] = '0.00';
if ($this->canViewUserRecharge) {
$allData['spend_user_num'] = $spendRepository->getPayUserCountByGame($params);//充值人数
$allData['spend_num'] = $spendRepository->getPayCountByGame($params);//充值次数
unset($params['pay_way']);
$allData['spend_all_amount'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//充值总额
$params['pay_way'] = ['in', '1,2,3,4,5,6'];
$allData['spend_cash'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//现金充值
$params['pay_way'] = 0;
$allData['spend_generic'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//通用币充值
$params['pay_way'] = -1;
$allData['spend_binding'] = null_to_0($spendRepository->getPayAmountByGameAndType($params));//绑定币充值
$allData['spend_discount'] = '0.00';
$allData['spend_voucher'] = '0.00';
}
}
}
@ -2093,9 +2112,15 @@ class QueryController extends BaseController
// $newCreateRoleDeviceCountList = $promoteRepository->getNewCreateRoleDeviceCountByIds($ids, $params);
$newCreateRoleIpCountList = $promoteRepository->getNewCreateRoleIpCountByIds($ids, $params);
$loginUserCountList = $promoteRepository->getLoginUserCountByIds($ids, $params);
$rechargeCountList = $promoteRepository->getRechargeCountByIds($ids, $params);
$rechargeUserCountList = $promoteRepository->getRechargeUserCountByIds($ids, $params);
$rechargeAmountList = $promoteRepository->getRechargeAmountByIds($ids, $params);
$rechargeCountList = [];
$rechargeUserCountList = [];
$rechargeAmountList = [];
if ($this->canViewUserRecharge) {
$rechargeCountList = $promoteRepository->getRechargeCountByIds($ids, $params);
$rechargeUserCountList = $promoteRepository->getRechargeUserCountByIds($ids, $params);
$rechargeAmountList = $promoteRepository->getRechargeAmountByIds($ids, $params);
}
if (I('p', 1) == 1) {
$selfParams = $params;
@ -2106,13 +2131,10 @@ class QueryController extends BaseController
// $selfNewCreateRoleDeviceCountList = $promoteRepository->getNewCreateRoleDeviceCountByIds([$parent['id']], $selfParams);
$selfNewCreateRoleIpCountList = $promoteRepository->getNewCreateRoleIpCountByIds([$parent['id']], $selfParams);
$selfLoginUserCountList = $promoteRepository->getLoginUserCountByIds([$parent['id']], $selfParams);
$selfRechargeCountList = $promoteRepository->getRechargeCountByIds([$parent['id']], $selfParams);
$selfRechargeUserCountList = $promoteRepository->getRechargeUserCountByIds([$parent['id']], $selfParams);
$selfRechargeAmountList = $promoteRepository->getRechargeAmountByIds([$parent['id']], $selfParams);
$records[] = [
$record = [
'id' => $parent['id'],
'account' => $parent['account'],
'real_name' => $parent['real_name'],
'real_name' => mb_strlen($parent['real_name'],'utf-8') == 2 ? mb_substr($parent['real_name'],0,1,'utf-8').'*':mb_substr($parent['real_name'],0,1,'utf-8').'**',
'level' => $parent['level'],
'create_role_count' => $selfCreateRoleCountList[$parent['id']],
'create_role_user_count' => $selfCreateRoleUserCountList[$parent['id']],
@ -2120,21 +2142,27 @@ class QueryController extends BaseController
// 'new_create_role_device_count' => $selfNewCreateRoleDeviceCountList[$parent['id']],
'new_create_role_ip_count' => $selfNewCreateRoleIpCountList[$parent['id']],
'login_user_count' => $selfLoginUserCountList[$parent['id']],
'recharge_count' => $selfRechargeCountList[$parent['id']],
'recharge_user_count' => $selfRechargeUserCountList[$parent['id']],
'recharge_amount' => $selfRechargeAmountList[$parent['id']]['ban_coin'] + $selfRechargeAmountList[$parent['id']]['coin'] + $selfRechargeAmountList[$parent['id']]['cash'],
'recharge_by_ban_coin' => $selfRechargeAmountList[$parent['id']]['ban_coin'],
'recharge_by_coin' => $selfRechargeAmountList[$parent['id']]['coin'],
'recharge_by_cash' => $selfRechargeAmountList[$parent['id']]['cash'],
'current_display' => $currentDisplay,
];
if ($this->canViewUserRecharge) {
$selfRechargeCountList = $promoteRepository->getRechargeCountByIds([$parent['id']], $selfParams);
$selfRechargeUserCountList = $promoteRepository->getRechargeUserCountByIds([$parent['id']], $selfParams);
$selfRechargeAmountList = $promoteRepository->getRechargeAmountByIds([$parent['id']], $selfParams);
$record['recharge_count'] = $selfRechargeCountList[$parent['id']];
$record['recharge_user_count'] = $selfRechargeUserCountList[$parent['id']];
$record['recharge_amount'] = $selfRechargeAmountList[$parent['id']]['ban_coin'] + $selfRechargeAmountList[$parent['id']]['coin'] + $selfRechargeAmountList[$parent['id']]['cash'];
$record['recharge_by_ban_coin'] = $selfRechargeAmountList[$parent['id']]['ban_coin'];
$record['recharge_by_coin'] = $selfRechargeAmountList[$parent['id']]['coin'];
$record['recharge_by_cash'] = $selfRechargeAmountList[$parent['id']]['cash'];
}
$records[] = $record;
}
foreach ($promotes as $promote) {
$id = $promote['id'];
$records[] = [
$record = [
'id' => $id,
'account' => $promote['account'],
'real_name' => $promote['real_name'],
'real_name' => mb_strlen($promote['real_name'],'utf-8') == 2 ? mb_substr($promote['real_name'],0,1,'utf-8').'*':mb_substr($promote['real_name'],0,1,'utf-8').'**',
'level' => $promote['level'],
'create_role_count' => $createRoleCountList[$id],
'create_role_user_count' => $createRoleUserCountList[$id],
@ -2142,14 +2170,17 @@ class QueryController extends BaseController
// 'new_create_role_device_count' => $newCreateRoleDeviceCountList[$id],
'new_create_role_ip_count' => $newCreateRoleIpCountList[$id],
'login_user_count' => $loginUserCountList[$id],
'recharge_count' => $rechargeCountList[$id],
'recharge_user_count' => $rechargeUserCountList[$id],
'recharge_amount' => $rechargeAmountList[$id]['ban_coin'] + $rechargeAmountList[$id]['coin'] + $rechargeAmountList[$id]['cash'],
'recharge_by_ban_coin' => $rechargeAmountList[$id]['ban_coin'],
'recharge_by_coin' => $rechargeAmountList[$id]['coin'],
'recharge_by_cash' => $rechargeAmountList[$id]['cash'],
'current_display' => '',
];
if ($this->canViewUserRecharge) {
$record['recharge_count'] = $rechargeCountList[$id];
$record['recharge_user_count'] = $rechargeUserCountList[$id];
$record['recharge_amount'] = $rechargeAmountList[$id]['ban_coin'] + $rechargeAmountList[$id]['coin'] + $rechargeAmountList[$id]['cash'];
$record['recharge_by_ban_coin'] = $rechargeAmountList[$id]['ban_coin'];
$record['recharge_by_coin'] = $rechargeAmountList[$id]['coin'];
$record['recharge_by_cash'] = $rechargeAmountList[$id]['cash'];
}
$records[] = $record;
}
} else {
$timeout = 1;

@ -207,6 +207,11 @@ class SafeController extends BaseController{
$this->error("手机号码格式不合法");
return false;
}
$telInfo = M('promote','tab_')->field('id')->where(['mobile_phone'=>$tel])->find();
if(!empty($telInfo)) {
$this->error("手机号码已存在");
return false;
}
if(empty($id_card)) {
$this->error("身份证号码不能为空");
return false;
@ -325,7 +330,7 @@ class SafeController extends BaseController{
$promoteInfo['personalstatus'] = true;
$promoteInfo['complanystatus'] = false;
}
if(!empty(json_decode($address))) {
if(!empty(json_decode($address)) && count(json_decode($address)) >= 2) {
$addressArr = explode(',', json_decode($address)[0]);
$promoteInfo['addressdata'] = $addressArr;
$this->assign('addr',json_decode($address)[1]);
@ -344,21 +349,18 @@ class SafeController extends BaseController{
$id = get_pid();
$rs = M("promote","tab_")->field('anothpic,ver_status,real_name,bank_card,mobile_phone,email,address,idcard')->where(['id'=>$id])->find();
$anothpic = $rs['anothpic'];
/* if(!empty($anothpic)) {
$idcarpicArr = explode(',', $anothpic);
foreach ($idcarpicArr as $key => $value) {
$promoteInfo['valuedata'][$key] = $value;
}
} */
$promoteInfo = "";
$address = json_decode($rs['address'],false)[1];
$realname = mb_strlen($rs['real_name'],'utf-8') == 2 ? mb_substr($rs['real_name'],0,1,'utf-8').'*':mb_substr($rs['real_name'],0,1,'utf-8').'**';
$this->assign('addr',$address);
$this->assign('ver_status',$rs['ver_status']);
$this->assign('rs',$rs);
$this->assign('idcard',encryption($rs['idcard']));
$this->assign('real_name',$realname);
$this->assign('promoteInfo',$promoteInfo);
$this->assign('tel',$rs['mobile_phone']);
$this->assign('tel',encryption($rs['mobile_phone']));
$this->display();
}
}
public function edit() {
$id = get_pid();
@ -377,6 +379,11 @@ class SafeController extends BaseController{
$this->error("手机号码格式不合法");
return false;
}
$telInfo = M('promote','tab_')->field('id')->where(['mobile_phone'=>$tel])->find();
if(!empty($telInfo)) {
$this->error("手机号码已存在");
return false;
}
if(empty($address1)) {
$this->error("地址不能为空");

@ -141,11 +141,11 @@
<th>游戏名称</th>
<th>流水</th>
<th>现金分成基数</th>
<th>现金分成比例</th>
<!-- <th>现金分成比例</th>-->
<th>平台币分成基数</th>
<th>平台币分成比例</th>
<!-- <th>平台币分成比例</th>-->
<th>绑定币分成基数</th>
<th>绑定币分成比例</th>
<!-- <th>绑定币分成比例</th>-->
<th>合作方分成金额</th>
</tr>
<if condition="true eq empty($listData) or $withdraw.status eq -1">
@ -165,19 +165,19 @@
<else/>
<td>0</td>
</if>
<td>{$vo.selle_ratio}%</td>
<!-- <td>{$vo.selle_ratio}%</td>-->
<if condition="$vo.pay_way eq 0">
<td>{$vo.pay_amount_all}</td>
<else/>
<td>0</td>
</if>
<td>{$vo.selle_ratio}%</td>
<!-- <td>{$vo.selle_ratio}%</td>-->
<if condition="$vo.pay_way eq -1">
<td>{$vo.pay_amount_all}</td>
<else/>
<td>0</td>
</if>
<td>{$vo.selle_ratio}%</td>
<!-- <td>{$vo.selle_ratio}%</td>-->
<td>{$vo.income}</td>
</tr>
</volist>

@ -134,13 +134,13 @@
<th>玩家账号</th>
<th>订单总额</th>
<th>现金分成基数</th>
<th>现金分成比例</th>
<!-- <th>现金分成比例</th>-->
<th>平台币分成基数</th>
<th>平台币分成比例</th>
<!-- <th>平台币分成比例</th>-->
<th>绑定币分成基数</th>
<th>绑定币分成比例</th>
<!-- <th>绑定币分成比例</th>-->
<th>现金支付通道</th>
<th>收益</th>
<!-- <th>收益</th>-->
<th>订单状态</th>
<th>充值时间</th>
</tr>
@ -164,21 +164,21 @@
<else/>
<td>0</td>
</if>
<td>{$vo.selle_ratio}%</td>
<!-- <td>{$vo.selle_ratio}%</td>-->
<if condition="$vo.pay_way eq 0">
<td>{$vo.pay_amount}</td>
<else/>
<td>0</td>
</if>
<td>{$vo.selle_ratio}%</td>
<!-- <td>{$vo.selle_ratio}%</td>-->
<if condition="$vo.pay_way eq -1">
<td>{$vo.pay_amount}</td>
<else/>
<td>0</td>
</if>
<td>{$vo.selle_ratio}%</td>
<!-- <td>{$vo.selle_ratio}%</td>-->
<td>{$vo.pay_way_name}</td>
<td>{$vo.income}</td>
<!-- <td>{$vo.income}</td>-->
<td>{$status}</td>
<td>{$vo.pay_time}</td>
</tr>

@ -109,11 +109,11 @@
<div class="form-group normal_space">
<label class="form-title select-title" style="position: relative;">交易时间:</label>
<div class="select-time">
<input type="text" readonly id="sdate" class="txt" name="begtime" placeholder="开始时间" value="{$initBegTime}">
<input type="text" id="sdate" class="txt" name="begtime" placeholder="开始时间" value="{$initBegTime}">
</div>
<label class="form-title select-title zhi_color">&nbsp;&nbsp;</label>
<div class="select-time">
<input type="text" readonly id="edate" class="txt" name="endtime" placeholder="结束时间" value="{$initEndTime}">
<input type="text" id="edate" class="txt" name="endtime" placeholder="结束时间" value="{$initEndTime}">
</div>
</div>
@ -237,7 +237,7 @@
<script type="text/javascript">
$().ready(function () {
setValue('row', '{:I("get.row",10)}');
setValue('settlement_type', '{:I("get.settlement_type",0)}');
setValue('settlement_type', '{:I("get.settlement_type","")}');
var date = "{$setdate}";
$('#sdate').datetimepicker({
format: 'yyyy-mm-dd',

@ -33,7 +33,6 @@
<input type="hidden" name="desc" value="{$game['features']}">
<input type="hidden" name="isIOS13" value="<?php if($isIOS13):?>1<?php else:?>0<?php endif;?>">
<input type="hidden" name="isNewIos" value="<?php if($isNewIos):?>1<?php else:?>0<?php endif;?>">
<input type="hidden" name="supersign_status" value="{$game['supersign_status']}" id="supersign_status">
<input type="hidden" name="betaUrl" value="{$game['beta_url']}">
<?php if ($isWechat):?>
@ -104,11 +103,7 @@
<div>{$game['relation_game_name']}</div>
<div>{$game['features']}</div>
<div>
<?php if ($downloadUrl == 'https://'.$_SERVER['HTTP_HOST']) :?>
<div class="download">免费安装</div>
<?php else :?>
<div class="download">免费安装</div>
<?php endif ;?>
<div class="download" data-downloadable="<?= ($game['dow_status'] != 1 || $game['download_ways'] == 0) ? 0 : 1 ?>">免费安装</div>
<img src="__IMG__/wenhao.png" class="doubt" alt="">
</div>
</div>
@ -259,31 +254,41 @@
<div class="window" style="display: none;z-index: 1000">
<div class="containner">
<div class="containner-box">
<div class="text"> 购买至尊下载赠送限量至尊超级礼包价值100元</div>
<div class="text">• 至尊下载:永不闪退、不丢数据稳定有保障</div>
<div class="text"> • 同一设备安装一次可在一年内无限次下载重装</div>
<img src="__IMG__/landing_bg2.png" alt="" style="width: 100%;height: 2.8rem;">
<div class="text-wrapper">
<div style="padding: 0 0.39rem 0.15rem 0.36rem;">
<?php if (($game['download_ways'] & 2) == 2):?>
<div class="text">beta版下载免费下载解决您频繁掉签的烦恼</div>
<?php endif;?>
<?php if (($game['download_ways'] & 4) == 4):?>
<div class="text">至尊下载10元购买永不闪退、不丢数据稳定与保障。同意设备安装一次可在一年内无限次下载重装并赠送限量至尊超级礼包</div>
<?php endif;?>
<?php if (($game['download_ways'] & 1) == 1):?>
<div class="text">普通下载:免费下载,畅游手游世界!</div>
<?php endif;?>
<?php if ($game['dow_status'] ==1):?>
<?php if ($game['dow_status'] ==1):?>
<?php if ($game['supersign_status'] ==1):?>
<div class="blue-btn" onclick="location.href='mobile.php/Ssg/pay/game_id/{$game[\'id\']}/promote_id/{$promoteId}'">¥10至尊下载</div>
<?php else:?>
<div class="blue-btn" onclick="layer.msg('已售空,我们正在努力上货中~');">¥10至尊下载</div>
<?php endif;?>
<?php if ($game['beta_status'] == 1):?>
<div class="blue-btn stabilization" data-url="{$game['beta_url']}">beta版下载</div>
<?php else:?>
<div class="blue-btn" onclick="layer.msg('已售空,我们正在努力上货中~');">beta版下载</div>
<?php endif;?>
<div class="blue-btn down-link" down-link="{$downloadUrl}">普通下载</div>
<?php else:?>
<div class="blue-btn" onclick="layer.msg('该游戏已关闭下载');">¥10至尊下载</div>
<div class="blue-btn" onclick="layer.msg('该游戏已关闭下载');">beta版下载</div>
<div class="blue-btn down-link" onclick="layer.msg('该游戏已关闭下载');return false;" down-link="{$downloadUrl}">普通下载</div>
<?php endif;?>
<?php if (($game['download_ways'] & 2) == 2):?>
<div class="blue-btn stabilization" data-url="{$game['beta_url']}">beta版下载</div>
<?php endif;?>
<?php if (($game['download_ways'] & 4) == 4):?>
<div class="blue-btn" onclick="location.href='mobile.php/Ssg/pay/game_id/{$game[\'id\']}/promote_id/{$promoteId}'">¥10至尊下载</div>
<?php endif;?>
<?php if (($game['download_ways'] & 1) == 1):?>
<div class="blue-btn down-link" down-link="{$downloadUrl}">普通下载</div>
<?php endif;?>
<?php else:?>
<div class="blue-btn" onclick="layer.msg('该游戏已关闭下载');">¥10至尊下载</div>
<div class="blue-btn" onclick="layer.msg('该游戏已关闭下载');">beta版下载</div>
<div class="blue-btn down-link" onclick="layer.msg('该游戏已关闭下载');return false;" down-link="{$downloadUrl}">普通下载</div>
<?php endif;?>
</div>
</div>
</div>
</div>
</div>
@ -1076,11 +1081,16 @@ var PhoneObj = {
};
swiperGet();
$(".download").click(function(){
var isTipSafari = is_tip_safari();
if (isTipSafari) {
$('.safari').show();
return;
}
var downloadable = $(this).attr('data-downloadable');
if (downloadable == 0) {
return layer.msg('暂无下载');
}
$(".window").show();
document.body.style.overflow = 'hidden';
});

@ -4,6 +4,7 @@
</block>
<block name="body">
<div class="page-overview promote-index-overview index-overview clearfix poll">
<?php if($canViewUserRecharge):?>
<ul>
<li><div class="icon"><span class="placeholder-graphic"><img src="__IMG__/20180207/icon_chongzhi1.png"/></span></div> <div class="text text2"><p>推广总用户</p><span>{$data.count}</span></div> </li>
<li><div class="icon"><span class="placeholder-graphic"><img src="__IMG__/20180207/icon_chongzhi2.png"/></span></div> <div class="text text1"><p>推广总充值</p><span>¥{$spendData.sum_count}</span></div> </li>
@ -16,6 +17,13 @@
<li><div class="icon"><span class="placeholder-graphic"><img src="__IMG__/20180207/icon_chongzhi3.png"/></span></div> <div class="text text3"><p>今日注册用户</p><span>{$data.today}</span></div> </li>
<li><div class="icon"><span class="placeholder-graphic"><img src="__IMG__/20180207/icon_chongzhi5.png"/></span></div> <div class="text text5"><p>今日充值金额</p><span>¥{$spendData.sum_today}</span></div> </li>
</ul>
<?php else:?>
<ul>
<li><div class="icon"><span class="placeholder-graphic"><img src="__IMG__/20180207/icon_chongzhi1.png"/></span></div> <div class="text text2"><p>推广总用户</p><span>{$data.count}</span></div> </li>
<li><div class="icon"><span class="placeholder-graphic"><img src="__IMG__/20180207/icon_chongzhi1.png"/></span></div> <div class="text text2"><p>昨日注册用户</p><span>{$data.yesterday}</span></div> </li>
<li><div class="icon"><span class="placeholder-graphic"><img src="__IMG__/20180207/icon_chongzhi3.png"/></span></div> <div class="text text3"><p>今日注册用户</p><span>{$data.today}</span></div> </li>
</ul>
<?php endif;?>
</div>
<div class="index-tab-list">
<ul>

@ -52,25 +52,30 @@
</div>
<?php endif;?>
<?php
$isOpenQuery = true;
?>
$isOpenQuery = true;
?>
<?php if($isOpenQuery):?>
<div class="subNav jssubNav"><i class="prev_icon icon_shujvi"></i><span>数据管理</span><i class="arrow_icon"></i></div>
<div class="navContent jsnavContent">
<a href="{:U('Query/dailySummary')}" class="<if condition='CONTROLLER_NAME eq Query and ACTION_NAME eq dailySummary '>active</if> ">每日概况</a>
<a href="{:U('Query/summary')}" class="<if condition='CONTROLLER_NAME eq Query and ACTION_NAME eq summary '>active</if> ">数据汇总</a>
<?php if($canViewUserRecharge):?>
<a href="{:U('Query/recharge')}" class="<if condition='CONTROLLER_NAME eq Query and (ACTION_NAME eq recharge or ACTION_NAME eq viewSpendDetailed) '>active</if> ">订单查询</a>
<?php endif;?>
<a href="{:U('Query/register')}" class="<if condition='CONTROLLER_NAME eq Query and (ACTION_NAME eq register or ACTION_NAME eq viewRole) '>active</if> ">注册明细</a>
<?php if($canViewUserRecharge):?>
<a href="{:U('Query/arpu')}" class="<if condition='CONTROLLER_NAME eq Query and ACTION_NAME eq arpu '>active</if> ">ARPU统计</a>
<?php endif;?>
<!-- <a href="{:U('Query/retention_analysis')}" class="<if condition='CONTROLLER_NAME eq Query and ACTION_NAME eq retention_analysis '>active</if> ">留存统计</a> -->
<a href="{:U('Query/userRoles')}" class="<if condition='CONTROLLER_NAME eq Query and ACTION_NAME eq userRoles '>active</if> ">角色查询</a>
<?php if($canViewUserRecharge):?>
<a href="{:U('Query/userRecharges')}" class="<if condition='CONTROLLER_NAME eq Query and ACTION_NAME eq userRecharges '>active</if> ">充值玩家</a>
<?php endif;?>
<a href="{:U('Query/achievement')}" class="<if condition='CONTROLLER_NAME eq Query and ACTION_NAME eq achievement '>active</if> ">团队/推广员业绩</a>
</div>
<?php endif;?>
<?php if ($loginer['level'] == 1) :?>
<?php if ($canViewUserRecharge && $loginer['level'] == 1) :?>
<div class="subNav jssubNav"><i class="prev_icon icon_caiwu"></i><span>财务管理</span><i class="arrow_icon"></i></div>
<div class="navContent jsnavContent">
<a href="{:U('Finance/index')}" class="<if condition='CONTROLLER_NAME eq Finance and ACTION_NAME eq index '>active</if> ">结算中心</a>
@ -128,10 +133,12 @@
<?php endif;?>
</div>
<?php if($canViewUserRecharge):?>
<div class="subNav jssubNav"><i class="prev_icon icon_fuli"></i><span>玩家管理</span><i class="arrow_icon"></i></div>
<div class="navContent jsnavContent">
<a href="{:U('Players/playAction')}" class="<if condition='CONTROLLER_NAME eq Players and (ACTION_NAME eq playAction)'>active</if> ">行为日志</a>
</div>
<?php endif;?>
</div>
</div>
@ -139,7 +146,11 @@
<div class="trunk_con">
<!--头部个人信息-->
<div class="header">
<if condition="$loginer['level'] eq 1 and $loginer['company_belong'] eq 1">
<div style="position: absolute;padding-left: 1.5%;">
<span class="pinfo" style="color: #1239f2">市场总监联系方式:<span>13637338237(李总监)</span></span>
</div>
</if>
<div class="header-right">
<span class="pinfo jstime">今天是:<span></span></span>
<span class="pinfo">您好!{:session('promote_auth.account')}</span>

@ -83,12 +83,14 @@
<!-- <th>新创角设备</th> -->
<th>新创角IP</th>
<th>登录用户数</th>
<?php if($canViewUserRecharge):?>
<th>充值人数</th>
<th>充值次数</th>
<th>充值总额</th>
<th>现金充值</th>
<th>通用币充值</th>
<th>绑定币充值</th>
<?php endif;?>
<?php if($parent['level'] < 4):?>
<th>操作</th>
<?php endif;?>
@ -109,12 +111,14 @@
<!-- <td>{$record.new_create_role_device_count}</td> -->
<td>{$record.new_create_role_ip_count}</td>
<td>{$record.login_user_count}</td>
<?php if($canViewUserRecharge):?>
<td>{$record.recharge_user_count}</td>
<td>{$record.recharge_count}</td>
<td>{$record.recharge_amount}</td>
<td>{$record.recharge_by_cash}</td>
<td>{$record.recharge_by_coin}</td>
<td>{$record.recharge_by_ban_coin}</td>
<?php endif;?>
<?php if($parent['level'] < 4):?>
<td>
<?php if($record['current_display'] == '' && $record['level'] < 4):?>

@ -158,9 +158,11 @@
<p>新创角用户|设备</p>
</div>
<?php if ($canViewUserRecharge) :?>
<div class="btn btn-role btn-role-border" data-type="3">
<p>充值人数|充值总额</p>
</div>
<?php endif ;?>
</div>
</div>
</div>
@ -179,6 +181,7 @@
</th>
<th class="pointer-hand" title="新增创角IP统计时间范围内首次创建角色IP总数去重">新增创角IP</th>
<th class="pointer-hand" title="登录用户数:统计时间范围内,登录的用户数(去重)">登录用户数</th>
<?php if ($canViewUserRecharge) :?>
<th class="pointer-hand" title="充值人数当日24小时在游戏内充值成功的订单的用户数去重">充值人数</th>
<th class="pointer-hand" title="充值次数当日24小时在游戏内充值成功的订单数量">充值次数</th>
<th class="pointer-hand spend-btn" title="充值总额当日24小时在游戏内充值成功的订单金额总和" style="width: 200px;">充值总额<i
@ -192,6 +195,7 @@
<th class="pointer-hand spend-element th-hide" title="代金券使用:统计时间范围内,在游戏内充值成功的订单,使用代金券总和,该部分不参与结算">
代金劵使用
</th>
<?php endif ;?>
</tr>
<empty name="listData">
<tr class="num2">
@ -208,6 +212,7 @@
<td>{$allData.new_user_num}|{$allData.new_device_num}</td>
<td>{$allData.new_ip_num}</td>
<td>{$allData.login_user_num}</td>
<?php if ($canViewUserRecharge) :?>
<td>{$allData.spend_user_num}</td>
<td>{$allData.spend_num}</td>
<td>{$allData.spend_all_amount}</td>
@ -216,6 +221,7 @@
<td class="spend-element th-hide">{$allData.spend_binding}</td>
<td class="spend-element th-hide">{$allData.spend_discount}</td>
<td class="spend-element th-hide">{$allData.spend_voucher}</td>
<?php endif ;?>
</tr>
<volist name="listData" id="vo">
<tr class="num2">
@ -225,6 +231,7 @@
<td>{$vo.new_user_num}|{$vo.new_device_num}</td>
<td>{$vo.new_ip_num}</td>
<td>{$vo.login_user_num}</td>
<?php if ($canViewUserRecharge) :?>
<td>{$vo.spend_user_num}</td>
<td>{$vo.spend_num}</td>
<td>{$vo.spend_all_amount}</td>
@ -233,6 +240,7 @@
<td class="spend-element th-hide">{$vo.spend_binding}</td>
<td class="spend-element th-hide">{$vo.spend_discount}</td>
<td class="spend-element th-hide">{$vo.spend_voucher}</td>
<?php endif ;?>
</tr>
</volist>
</empty>
@ -323,10 +331,12 @@
dataName2 = '新创角设备';
break;
case 3:
<?php if ($canViewUserRecharge) :?>
data1 = spendUserNum;
data2 = spendAllAmount;
dataName1 = '充值人数';
dataName2 = '充值总额';
<?php endif ;?>
break;
}

@ -146,6 +146,7 @@
</th>
<th class="pointer-hand" title="新增创角IP统计时间范围内首次创建角色IP总数去重">新增创角IP</th>
<th class="pointer-hand" title="登录用户数:统计时间范围内,登录的用户数(去重)">登录用户数</th>
<?php if ($canViewUserRecharge) :?>
<th class="pointer-hand" title="充值人数当日24小时在游戏内充值成功的订单的用户数去重">充值人数</th>
<th class="pointer-hand" title="充值次数当日24小时在游戏内充值成功的订单数量">充值次数</th>
<th class="pointer-hand spend-btn" title="充值总额当日24小时在游戏内充值成功的订单金额总和" style="width: 200px;">充值总额<i
@ -159,6 +160,7 @@
<th class="pointer-hand spend-element th-hide" title="代金券使用:统计时间范围内,在游戏内充值成功的订单,使用代金券总和,该部分不参与结算">
代金劵使用
</th>
<?php endif ;?>
</tr>
<empty name="listData">
<tr class="num2">
@ -177,6 +179,7 @@
<td>{$vo.new_user_num}|{$vo.new_device_num}</td>
<td>{$vo.new_ip_num}</td>
<td>{$vo.login_user_num}</td>
<?php if ($canViewUserRecharge) :?>
<td>{$vo.spend_user_num}</td>
<td>{$vo.spend_num}</td>
<td>{$vo.spend_all_amount|default=0}</td>
@ -185,6 +188,7 @@
<td class="spend-element th-hide">{$vo.spend_binding|default=0}</td>
<td class="spend-element th-hide">{$vo.spend_discount|default=0}</td>
<td class="spend-element th-hide">{$vo.spend_voucher|default=0}</td>
<?php endif ;?>
</tr>
</volist>
<tr class="num2">
@ -195,6 +199,7 @@
<td>{$allData.new_user_num}|{$allData.new_device_num}</td>
<td>{$allData.new_ip_num}</td>
<td>{$allData.login_user_num}</td>
<?php if ($canViewUserRecharge) :?>
<td>{$allData.spend_user_num}</td>
<td>{$allData.spend_num}</td>
<td>{$allData.spend_all_amount}</td>
@ -203,6 +208,7 @@
<td class="spend-element th-hide">{$allData.spend_binding}</td>
<td class="spend-element th-hide">{$allData.spend_discount}</td>
<td class="spend-element th-hide">{$allData.spend_voucher}</td>
<?php endif ;?>
</tr>
</empty>
</table>

@ -121,10 +121,10 @@
<div class="zizhi">
<div class="line_title">资质认证</div>
<div class="line_text">
真实姓名: {$rs['real_name']}
真实姓名: {$real_name}
</div>
<div class="line_text">
身份证号码: {$rs['idcard']}
身份证号码: {$idcard}
</div>
<div class="line_text">
身份证扫描: <span style="color:#449acb">已认证<span>

@ -4,6 +4,7 @@ use Org\Ipa365SDK\Ipa365;
use User\Api\MemberApi;
use Think\Log;
use Base\Service\ApplyService;
use Base\Tool\TaskClient;
class CommonController extends BaseController {
const USER_NOT_ILLEGAL = -1; //用户名不合法
@ -105,7 +106,9 @@ class CommonController extends BaseController {
$gameId = $params['game_id'] ?? 0;
#验证短信验证码
$this->smsVerify($params['account'], $params['verify_code']);
if (!$this->smsVerify($params['account'], $params['verify_code'])) {
$this->respondError('验证失败');
}
$res = $this->doRegister($params['account'], $params['password'], $params['account'], $promoteId, 4, 2, $gameId);
if(empty($res)){
@ -126,7 +129,9 @@ class CommonController extends BaseController {
if (empty($params)) {
$this->respondError('基础信息不能为空');
}
$this->smsVerify($params['account'], $params['verify_code']);
if (!$this->smsVerify($params['account'], $params['verify_code'])) {
$this->respondError('验证失败');
}
//更新密码
$userApi = new MemberApi();
$userInfo = M("user", "tab_")->where("account = '".$params['account']."'")->find();
@ -213,36 +218,26 @@ class CommonController extends BaseController {
//发送验证码
public function sendPhoneCode()
{
$phone = I("phone");
$result = R('Common/Sms/send_sms_code', [$phone, 10, false]);
if ($result['code'] == 200) {
$this->setData($result['data'])->respondSuccess('发送成功');
$phone = I('phone');
$taskClient = new TaskClient();
$result = $taskClient->sendSms($phone, get_client_ip());
$data = [];
if ($result['code'] == TaskClient::SUCCESS) {
$this->respondSuccess('发送成功');
} else {
$this->respondError('发送失败');
}
}
public function smsVerify($phone="" , $code="", $type=2){
$result = R('Common/Sms/verify_sms_code', [$phone, $code, false]);
if($result['code'] == 200) {
if($type==1){
$this->respondSuccess('正确');
}else{
return true;
}
public function smsVerify($phone = '' , $code = '')
{
$taskClient = new TaskClient();
$result = $taskClient->checkSms($phone, $code);
$data = [];
if ($result['code'] == TaskClient::SUCCESS) {
return true;
} else {
switch ($result['code']) {
case 1021:{
$this->respondError('验证码已失效,请重新获取');
};break;
case 1022:{
$this->respondError('验证码不正确,请重新输入');
};break;
default:
$this->respondError($result['msg']);
}
return false;
}
}
}

@ -3,7 +3,9 @@ namespace Mobile\Controller;
use Org\Ipa365SDK\Ipa365;
use Org\WeixinSDK\Weixin;
use User\Api\MemberApi;
use Base\Tool\TaskClient;
use Think\Log;
use Base\Service\GameService;
class SsgController extends BaseController {
const USER_NOT_ILLEGAL = -1; //用户名不合法
@ -180,7 +182,9 @@ class SsgController extends BaseController {
$this -> set_message(1001, "fail", "注册数据不能为空");
}
#验证短信验证码
$this -> sms_verify($user['account'], $user['code']);
if (!$this->sms_verify($user['account'], $user['code'])) {
$this->set_message(1000, "fail", '验证失败');
}
$res = $this -> doRegister($user['account'],$user['password'],$user['account'],$promoteId,4,2, $game_id);
if(empty($res)){
@ -200,7 +204,9 @@ class SsgController extends BaseController {
if (empty($user)) {
$this -> set_message(1001, "fail", "基础信息不能为空");
}
$this -> sms_verify($user['account'], $user['code']);
if (!$this->sms_verify($user['account'], $user['code'])) {
$this->set_message(1000, "fail", '验证失败');
}
//更新密码
$userApi = new MemberApi();
$userInfo = M("user","tab_")->where("account = '".$user['account']."'")->find();
@ -320,12 +326,16 @@ class SsgController extends BaseController {
}
$map["sdk_version"] = 2;
$map["game_status"] = 1;
$map["supersign_status"] = 1;
$game_list = M("game", "tab_")->field("*, id as game_id")->where($map)->select();
for ($i=0; $i < count($game_list); $i++) {
$game_list[$i]["game_icon"] = get_cover($game_list[$i]["icon"], 'path');
$games = [];
foreach ($game_list as $game) {
if (($game['download_ways'] & GameService::DOWNLOAD_SUPER) != GameService::DOWNLOAD_SUPER) {
continue;
}
$game["game_icon"] = get_cover($game["icon"], 'path');
$games[] = $game;
}
$res = array("list"=>$game_list);
$res = array("list"=>$games);
if($type == 1){
$map['user_id']= $user['user_id'];
$map['pay_status'] = 1;
@ -398,24 +408,24 @@ class SsgController extends BaseController {
session("user_auth",null);
redirect(U("ssg/login"));
}
//发送验证码
public function sendPhoneCode()
{
$phone = I("phone");
$result = R('Common/Sms/send_sms_code', array($phone, 10, false));
if ($result['code'] == 200) {
$phone = I('phone');
$taskClient = new TaskClient();
$result = $taskClient->sendSms($phone, get_client_ip());
$data = [];
if ($result['code'] == TaskClient::SUCCESS) {
$data['status'] = 1;
$data['data'] = $result['data'];
} else {
$data['status'] = 0;
}
$data['msg'] = $result['msg'];
$data['msg'] = $result['message'];
echo json_encode($data);
exit;
}
public function timediffs($begin_time, $end_time) {
if ($begin_time < $end_time) {
$starttime = $begin_time;
@ -439,29 +449,17 @@ class SsgController extends BaseController {
$res = array("day" => $days, "hour" => $hours, "min" => $mins, "sec" => $secs);
return $res;
}
public function sms_verify($phone="" ,$code="",$type=2){
$result = R('Common/Sms/verify_sms_code',array($phone,$code,false));
if($result['code']==200) {
if($type==1){
$this->set_message(200,"success","正确");
}else{
return true;
}
public function sms_verify($phone , $code)
{
$taskClient = new TaskClient();
$result = $taskClient->checkSms($phone, $code);
$data = [];
if ($result['code'] == TaskClient::SUCCESS) {
return true;
} else {
switch ($result['code']) {
case 1021:{
$this->set_message(1010,"fail","验证码已失效,请重新获取");
};break;
case 1022:{
$this->set_message(1022,"fail","验证码不正确,请重新输入");
};break;
default:
$this->set_message($result['code'],"fail",$result['msg']);
}
return false;
}
}
/**

@ -8,6 +8,7 @@ use Org\UcenterSDK\Ucservice;
use User\Api\MemberApi;
use Admin\Model\PointTypeModel;
use Think\Log;
use Base\Tool\TaskClient;
class UserController extends BaseController
{
@ -337,7 +338,9 @@ class UserController extends BaseController
$password = $safeinfo['password'];
$sex = $safeinfo['sex'];
$this->checksafecode($phone, $safecode, false);
if (!$this->checksafecode($phone, $safecode)) {
return $this->ajaxReturn(array('status' => 0, 'msg' => '验证失败'));
}
/**是否开启ucenter**/
@ -577,17 +580,15 @@ class UserController extends BaseController
*/
public function telsafecode($phone = '', $delay = 10, $flag = true)
{
$result = R('Common/Sms/send_sms_code', array($phone, $delay, false));
if ($result['code'] == 200) {
$taskClient = new TaskClient();
$result = $taskClient->sendSms($phone, get_client_ip());
$data = [];
if ($result['code'] == TaskClient::SUCCESS) {
$data['status'] = 1;
$data['data'] = $result['data'];
} else {
$data['status'] = 0;
}
$data['msg'] = $result['msg'];
$data['msg'] = $result['message'];
echo json_encode($data);
exit;
}
@ -614,24 +615,16 @@ class UserController extends BaseController
/**
* 手机安全码验证
* @param bool $flag true 用于直接异步请求 false 用于方法调用
* @param [type] $vcode [description]
*/
public function checksafecode($phone, $vcode, $flag = true)
public function checksafecode($phone, $code)
{
$result = R('Common/Sms/verify_sms_code', array($phone, $vcode, false));
if ($result['code'] == 200) {
$data['status'] = 1;
if ($flag) {
echo json_encode($data);
exit;
}
$taskClient = new TaskClient();
$result = $taskClient->checkSms($phone, $code);
$data = [];
if ($result && $result['code'] == TaskClient::SUCCESS) {
return true;
} else {
$data['status'] = 0;
$data['msg'] = $result['msg'];
echo json_encode($data);
exit;
return false;
}
}
@ -645,8 +638,11 @@ class UserController extends BaseController
if (IS_POST) {
$phone = $_POST['phone'];
$code = $_REQUEST['code'];
$this->checksafecode($phone, $_REQUEST['code'], false);
if (!$this->checksafecode($phone, $code)) {
return $this->ajaxReturn(array('status' => 0, 'msg' => '验证失败'));
}
$this->success('验证成功', U('User/forget1', array('phone' => $phone)));
@ -662,8 +658,16 @@ class UserController extends BaseController
if (IS_POST) {
$new_pwd = $_REQUEST['new_pwd'];
$u_uid['phone'] = $_REQUEST['phone'];
$code = $_REQUEST['code'];
//验证短信验证码
$this->checksafecode($u_uid['phone'], $_REQUEST['code'], false);
if (!$this->checksafecode($u_uid['phone'], $code)) {
$this->error("验证失败");
}
$user = M('user', 'tab_')->where($u_uid)->find();
if (!$user) {
$this->error("账号不存在");
}
$result = M('user', 'tab_')->where($u_uid)->setField('password', think_ucenter_md5($new_pwd, UC_AUTH_KEY));
if ($result != false) {
$this->success("修改成功", U('User/login'));
@ -700,7 +704,6 @@ class UserController extends BaseController
exit;
}
$result = $this->telsafecode($account);
}
/**
@ -880,7 +883,10 @@ class UserController extends BaseController
if (IS_POST) {
$code = I("post.scode");
$phone = I("post.phone");
$this->checksafecode($phone, $code, false);
if (!$this->checksafecode($phone, $code)) {
echo json_encode(array('status' => 0, 'msg' => '验证失败'));
exit();
}
if (!$user['phone']) {
$where['account'] = $phone;
$where['phone'] = $phone;

@ -124,7 +124,7 @@
code:$("#code").val(),
new_pwd:new_pwd
},
success:function(result){
success:function(result) {
if(result.status == 1){
pmsg.msg("修改成功");
setTimeout(function () {

@ -1074,7 +1074,6 @@ CREATE TABLE `sys_document_pop_rules` (
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=9 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin;
--广--
CREATE TABLE `tab_sociaty_games` (
@ -1089,4 +1088,32 @@ CREATE TABLE `tab_sociaty_games` (
----
ALTER TABLE `tab_game`
ADD COLUMN `apply_auth` INT(11) NULL DEFAULT '1' COMMENT '申请权限(1为全部可申请2为部分会长可申请)' AFTER `game_detail_cover`;
ADD COLUMN `apply_auth` INT(11) NULL DEFAULT '1' COMMENT '申请权限(1为全部可申请2为部分会长可申请)' AFTER `game_detail_cover`;
-- 2020-01-14
-- cxj
ALTER TABLE `tab_promote_game_ratio`
MODIFY COLUMN `turnover_ratio` varchar(2000) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NOT NULL DEFAULT '' COMMENT '流水分成比例' AFTER `last_ratio_status`,
MODIFY COLUMN `last_turnover_ratio` varchar(2000) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NOT NULL DEFAULT '' COMMENT '上次流水分成比例';
UPDATE tab_spend SET selle_ratio = 0.00 where selle_ratio is null
ALTER TABLE `tab_promote_game_ratio`
ADD COLUMN `relation_game_id` int(11) NOT NULL DEFAULT 0 COMMENT '关联游戏id' AFTER `game_id`;
ALTER TABLE `tab_promote_game_ratio_log`
ADD COLUMN `relation_game_id` int(11) NOT NULL DEFAULT 0 COMMENT '关联游戏id' AFTER `game_id`;
ALTER TABLE `tab_spend`
MODIFY COLUMN `selle_status` int(11) NOT NULL DEFAULT 0 COMMENT '渠道结算 0未结算1 结算',
MODIFY COLUMN `selle_ratio` double(5, 2) DEFAULT 0.00 COMMENT '渠道分成比例';
ALTER TABLE `tab_game`
ADD COLUMN `download_ways` tinyint(3) NOT NULL DEFAULT 0 COMMENT '下载方式' AFTER `beta_url`;
-- 是否需要修复旧数据
ALTER TABLE `tab_promote`
ADD COLUMN `can_view_recharge` tinyint(1) NOT NULL default 0 COMMENT '是否显示充值数据 0否 1是';
ALTER TABLE `tab_promote_belong`
ADD COLUMN `can_view_recharge` tinyint(1) NOT NULL default 0 COMMENT '是否显示充值数据 0否 1是';

@ -405,24 +405,37 @@
}
.containner{
width: 5.50rem;
height: 7.82rem;
background: url(../images/landing_bg.png) no-repeat;
background-size: 100% 100%;
display: flex;
justify-content: flex-end;
/* height: 9.20rem; */
/* background: url(../images/landing_bg.png) no-repeat; */
/* background-size: 100% 100%; */
/* background-color: #fff; */
/* display: flex;
justify-content: flex-end; */
}
.containner-box{
padding: 0 0.39rem 0.15rem 0.36rem;
/* padding: 0 0.39rem 0.15rem 0.36rem; */
display: flex;
flex-direction: column;
align-items: center;
justify-content: flex-end;
}
.containner-box .text-wrapper {
display: flex;
flex-direction: column;
align-items: flex-end;
justify-content: center;
background-color: #fff;
width: 100%;
border-bottom-left-radius: 0.2rem;
border-bottom-right-radius: 0.2rem;
}
.containner-box .text{
font-size:0.24rem;
font-weight:400;
color:rgba(41,41,41,1);
line-height:0.36rem;
width: 100%;
}
.blue-btn{
width: 4.40rem;

Binary file not shown.

After

Width:  |  Height:  |  Size: 33 KiB

Loading…
Cancel
Save