推广公司新增部门

master
chenzhi 3 years ago
parent cce6721de6
commit 8a24fb37aa

@ -145,10 +145,10 @@ class PromoteCompanyController extends ThinkController
$payWays = PresidentDepositService::$payWays;
$payTypes = PresidentDepositService::$payTypes;
$statusList = PresidentDepositService::$statusList;
//获取公司信息
if(!empty($companyres)){
$companyIds = array_column($companyres, 'id') ;
$depositList = M('president_deposit', 'tab_')->field(['company_id', 'pay_type', 'amount', 'status'])->where(['company_id' => ['in', $companyIds]])->select();
$depositList = index_by_column('company_id', $depositList);
@ -221,9 +221,9 @@ class PromoteCompanyController extends ThinkController
// dump($game);
}
}
// die();
//公司及会长数量统计
$companycount = $model->field("id")->where($map)->select();
$count = count($companycount);
@ -231,7 +231,6 @@ class PromoteCompanyController extends ThinkController
$promotemap['p.company_id']=["in",$companyallids];
$promotemap['p.level']=1;
$promotecount = M("Promote","tab_")->alias('p')->where($promotemap)->count();
// dd($companyres);
$this->assign('listData', $companyres);
$this->assign('count', $count);
$this->assign('promotecount', $promotecount);
@ -1609,6 +1608,7 @@ class PromoteCompanyController extends ThinkController
return $senddata;
}
protected function getPromoteGameRadio($company_id,$ratio,$p_map = false){
$departmentName = A("Market",'Event')->getDepartmentNameByMarketType('nickname');
//获取会长信息
$rdata = [];
$promotemap['p.company_id']=$company_id;
@ -1634,6 +1634,7 @@ class PromoteCompanyController extends ThinkController
foreach ($promoteres as $k => &$v) {
$admin = isset($adminList[$v['id']]) && $adminList[$v['id']]['admin'] ? $adminList[$v['id']]['admin'] : null;
$v['market_admin_username'] = $admin ? ($admin['real_name'] ? $admin['real_name'] : $admin['username']) : '无';
$v['market_admin_department'] =$departmentName[$admin['username']] ?? '无';
if($ratio == false || empty($v['game_ids'])){
$v['row']=1;

@ -198,6 +198,7 @@
<th>会长账号</th>
<th>市场专员</th>
<th>所属市场部</th>
<!-- <th>押金</th> -->
<th>原包名</th>
<th>现包名</th>
@ -231,6 +232,7 @@
<notempty name="data.list">
<td rowspan="{$data['list'][0]['row']}">{$data['list'][0]['account']|default="--"}</td>
<td rowspan="{$data['list'][0]['row']}">{$data['list'][0]['market_admin_username']|default="--"}</td>
<td rowspan="{$data['list'][0]['row']}">{$data['list'][0]['market_admin_department']|default="--"}</td>
<!-- <td rowspan="{$data['list'][0]['row']}">{$data['list'][0]['pay_type']|default="--"}</td> -->
<notempty name="data['list'][0]['list']">

Loading…
Cancel
Save