master
jbrazz 5 years ago
parent 74be3407b1
commit 5e9cfb023f

@ -541,4 +541,19 @@ function getPartnerList($id = 0)
function getPartnerName($id = 0)
{
return M('Partner', 'tab_')->where(array('id' => intval($id)))->getField('partner');
}
function getTopPromote($promote_id)
{
$promoter = M('promote', 'tab_')->where(['id' => $promote_id])->find();
if (!$promoter) {
return [];
}
$chain = trim($promoter['chain'], '/');
if ($chain == '') {
return $promoter;
} else {
$topPromoteId = explode('/', $chain)[0];
return M('promote', 'tab_')->where(['id' => $topPromoteId])->find();
}
}

@ -84,7 +84,7 @@
<empty name='show_status'>
<div class="input-list input-list-parent search_label_rehab">
<select id="parent_id" name="parent_id" class="select_gallery" >
<option value="">上级推广员</option>
<option value="">上级会长</option>
<volist name=":get_all_toppromote()" id="vo">
<option parent-id="{$vo.id}" value="{$vo.id}">{$vo.account}</option>
</volist>
@ -157,7 +157,7 @@
<th ><a class="paixu" data-order='create_time'>注册时间</a></th>
<th ><a class="paixu" data-order='last_login_time'>最后登录时间</a></th>
<th>渠道类型</th>
<th>级会长</th>
<th>线推广员</th>
<th>商务专员</th>
<th>状态</th>
<th>可申请游戏</th>
@ -184,7 +184,7 @@
<td>{:set_show_time($data['create_time'])}</td>
<td>{:set_show_time($data['last_login_time'])}</td>
<td>{:get_promote_levels($data['id'])}</td>
<td><?php echo (new \Base\Service\PromoteService())->getTopPromote($data)['account']?></td>
<td>{:getTopPromote($data['id'])['account']}</td>
<td>{:get_business_affairs_account($data['ba_id'])}</td>
<td><if condition="$data['status'] eq 0">
<span class="preview_status">{:get_info_status($data['status'],3)}</span>

Loading…
Cancel
Save