权限控制

master
sunke 5 years ago
parent 84b36e2d78
commit 2e37b23f2b

@ -239,7 +239,7 @@ class DownloadController extends BaseController {
$queryPromote = $this->getQueryPromote($levelPromote); $queryPromote = $this->getQueryPromote($levelPromote);
$loginPromote = $this->getLoginPromote(); $loginPromote = $this->getLoginPromote();
$map1['chain'] = ['like','%'.PID.'/'.'%']; $map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select(); $rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
$childPromoteIds = ''; $childPromoteIds = '';
if(empty($rs)) { if(empty($rs)) {
@ -508,7 +508,7 @@ class DownloadController extends BaseController {
* @author sunke * @author sunke
*/ */
public function testresource_data_export() { public function testresource_data_export() {
$map1['chain'] = ['like','%'.PID.'/'.'%']; $map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select(); $rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
$childPromoteIds = ''; $childPromoteIds = '';
if(empty($rs)) { if(empty($rs)) {
@ -574,7 +574,7 @@ class DownloadController extends BaseController {
* @author sunke * @author sunke
*/ */
public function testresourcelists_data_export() { public function testresourcelists_data_export() {
$map1['chain'] = ['like','%'.PID.'/'.'%']; $map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select(); $rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
$childPromoteIds = ''; $childPromoteIds = '';
if(empty($rs)) { if(empty($rs)) {
@ -644,7 +644,7 @@ class DownloadController extends BaseController {
* @author sunke * @author sunke
*/ */
public function supportNumberList_data_export() { public function supportNumberList_data_export() {
$map1['chain'] = ['like','%'.PID.'/'.'%']; $map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select(); $rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
$childPromoteIds = ''; $childPromoteIds = '';
if(empty($rs)) { if(empty($rs)) {
@ -710,7 +710,7 @@ class DownloadController extends BaseController {
$gameId = I('game_id', 0); $gameId = I('game_id', 0);
$serverId = I('server_id', 0); $serverId = I('server_id', 0);
$map1['chain'] = ['like','%'.PID.'/'.'%']; $map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select(); $rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
$childPromoteIds = ''; $childPromoteIds = '';
if(empty($rs)) { if(empty($rs)) {
@ -800,7 +800,7 @@ class DownloadController extends BaseController {
*/ */
public function regist_data_export() { public function regist_data_export() {
$map1['chain'] = ['like','%'.PID.'/'.'%']; $map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select(); $rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
$childPromoteIds = ''; $childPromoteIds = '';
if(empty($rs)) { if(empty($rs)) {
@ -877,11 +877,11 @@ class DownloadController extends BaseController {
public function children_data_export() { public function children_data_export() {
$promoteType = intval(I('promote_type', 0)); $promoteType = intval(I('promote_type', 0));
$loginer = $this->getLoginPromote(); $loginer = $this->getLoginPromote();
$map1['chain'] = ['like','%'.PID.'/'.'%']; $map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select(); $rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
$childPromoteIds = ''; $childPromoteIds = '';
if(empty($rs)) { if(empty($rs)) {
$map['promote_id'] = PID; $map['id'] = PID;
}else { }else {
foreach ($rs as $rsKey => $rsValue) { foreach ($rs as $rsKey => $rsValue) {
$id = $rsValue['id']; $id = $rsValue['id'];
@ -889,7 +889,7 @@ class DownloadController extends BaseController {
} }
$childPromoteIds = rtrim($childPromoteIds, ','); $childPromoteIds = rtrim($childPromoteIds, ',');
$childPromoteIds .= ',' . PID; $childPromoteIds .= ',' . PID;
$map['promote_id'] = ['in', $childPromoteIds]; $map['id'] = ['in', $childPromoteIds];
} }
if ($promoteType == 0) { if ($promoteType == 0) {
@ -942,7 +942,7 @@ class DownloadController extends BaseController {
* @author sunke * @author sunke
*/ */
public function coinrecord_data_export() { public function coinrecord_data_export() {
$map1['chain'] = ['like','%'.PID.'/'.'%']; $map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select(); $rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
$childPromoteIds = ''; $childPromoteIds = '';
if(empty($rs)) { if(empty($rs)) {
@ -1105,7 +1105,7 @@ class DownloadController extends BaseController {
* @author sunke * @author sunke
*/ */
public function mycoin_data_export() { public function mycoin_data_export() {
$map1['chain'] = ['like','%'.PID.'/'.'%']; $map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select(); $rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
$childPromoteIds = ''; $childPromoteIds = '';
if(empty($rs)) { if(empty($rs)) {
@ -1167,7 +1167,7 @@ class DownloadController extends BaseController {
*/ */
public function recharge_data_export() { public function recharge_data_export() {
$map1['chain'] = ['like','%'.PID.'/'.'%']; $map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select(); $rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
$childPromoteIds = ''; $childPromoteIds = '';
if(empty($rs)) { if(empty($rs)) {
@ -1259,7 +1259,7 @@ class DownloadController extends BaseController {
$promoteId = I('promote_id', 0); $promoteId = I('promote_id', 0);
$sdkVersion = I('sdk_version', 0); $sdkVersion = I('sdk_version', 0);
$headmanPromoteId = I('headman_promote_id', 0); $headmanPromoteId = I('headman_promote_id', 0);
$map1['chain'] = ['like','%'.PID.'/'.'%']; $map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select(); $rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
$childPromoteIds = ''; $childPromoteIds = '';
if(empty($rs)) { if(empty($rs)) {
@ -1436,7 +1436,7 @@ class DownloadController extends BaseController {
$headmanPromoteId = I('headman_promote_id', 0); $headmanPromoteId = I('headman_promote_id', 0);
$playTime = I('play_time', ''); $playTime = I('play_time', '');
$promote = $this->getLoginPromote(); $promote = $this->getLoginPromote();
$map1['chain'] = ['like','%'.PID.'/'.'%']; $map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select(); $rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
$childPromoteIds = ''; $childPromoteIds = '';
if(empty($rs)) { if(empty($rs)) {
@ -1558,7 +1558,7 @@ class DownloadController extends BaseController {
$begtime = I('begtime',''); $begtime = I('begtime','');
$endtime = I('endtime',''); $endtime = I('endtime','');
// $childPromoteIds = getAllChildPromoteList(3); // $childPromoteIds = getAllChildPromoteList(3);
$map1['chain'] = ['like','%'.PID.'/'.'%']; $map1['chain'] = ['like','%'.'/'.PID.'/'.'%'];
$rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select(); $rs = M('promote','tab_')->where($map1)->field('id,account,nickname')->select();
$childPromoteIds = ''; $childPromoteIds = '';
if(empty($rs)) { if(empty($rs)) {

@ -77,8 +77,10 @@
</table> </table>
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" href="{:U('download/financeindex_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get"> <a id="sch-btn" href="{:U('download/financeindex_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">
导出</a> 导出</a>
<?php endif ;?>
{$_page} {$_page}
</div> </div>
</div> </div>

@ -155,7 +155,9 @@
</table> </table>
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" data-href="{:U('download/settlementDtl_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">导出</a> <a id="sch-btn" data-href="{:U('download/settlementDtl_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">导出</a>
<?php endif ;?>
{$_page} {$_page}
</div> </div>
</div> </div>

@ -188,7 +188,9 @@
</table> </table>
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" data-href="{:U('download/withdrawDtl_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">导出</a> <a id="sch-btn" data-href="{:U('download/withdrawDtl_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">导出</a>
<?php endif ;?>
{$_page} {$_page}
</div> </div>
</div> </div>

@ -182,7 +182,9 @@
</table> </table>
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" data-href="{:U('download/withdrawRecord_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">导出</a> <a id="sch-btn" data-href="{:U('download/withdrawRecord_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">导出</a>
<?php endif ;?>
{$_page} {$_page}
</div> </div>
</div> </div>

@ -123,7 +123,9 @@
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" href="{:U('download/children_data_export',array_merge(['promote_type'=>I('promote_type')],I('post.')))}" class="ajax-get" >导出</a> <a id="sch-btn" href="{:U('download/children_data_export',array_merge(['promote_type'=>I('promote_type')],I('post.')))}" class="ajax-get" >导出</a>
<?php endif ;?>
{$pagination} {$pagination}
</div> </div>
</div> </div>

@ -113,7 +113,9 @@
'p'=>I('p'), 'p'=>I('p'),
'account'=>I('account'),'xlsname'=>'管理中心_'.get_pro_grade_name(PRO_GRADE,1),'row'=>I('request.row') 'account'=>I('account'),'xlsname'=>'管理中心_'.get_pro_grade_name(PRO_GRADE,1),'row'=>I('request.row')
))}" >导出</a>--> ))}" >导出</a>-->
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" data-href="{:U('download/children_data_export',array_merge(['promote_type'=>I('promote_type')],I('post.')))}" class="ajax-get" >导出</a> <a id="sch-btn" data-href="{:U('download/children_data_export',array_merge(['promote_type'=>I('promote_type')],I('post.')))}" class="ajax-get" >导出</a>
<?php endif ;?>
{$_page} {$_page}
</div> </div>
</div> </div>

@ -193,7 +193,9 @@
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<!-- <a class="sch-btn" href="{:U('Export/expUser',array_merge(array('id'=>8,'xlsname'=>'会长福利_平台币入账记录'),I('post.')))}" >导出</a>--> <!-- <a class="sch-btn" href="{:U('Export/expUser',array_merge(array('id'=>8,'xlsname'=>'会长福利_平台币入账记录'),I('post.')))}" >导出</a>-->
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" href="{:U('download/mycoin_data_export',array_merge(['promote_type'=>'xxx'],I('get.')))}" class="ajax-get" >导出</a> <a id="sch-btn" href="{:U('download/mycoin_data_export',array_merge(['promote_type'=>'xxx'],I('get.')))}" class="ajax-get" >导出</a>
<?php endif ;?>
{$_page} {$_page}
</div> </div>
</div> </div>

@ -103,7 +103,9 @@
</table> </table>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" href="{:U('download/coinrecord_data_export',array_merge(['promote_type'=>'xxx'],I('post.')))}" class="ajax-get" >导出</a> <a id="sch-btn" href="{:U('download/coinrecord_data_export',array_merge(['promote_type'=>'xxx'],I('post.')))}" class="ajax-get" >导出</a>
<?php endif ;?>
{$pagination} {$pagination}
</div> </div>
</div> </div>

@ -129,7 +129,9 @@
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" href="{:U('download/achievement_data_export',array_merge(['parent_id'=>$parentid],I('post.')))}" class="ajax-get">导出</a> <a id="sch-btn" href="{:U('download/achievement_data_export',array_merge(['parent_id'=>$parentid],I('post.')))}" class="ajax-get">导出</a>
<?php endif ;?>
{$pagination} {$pagination}
</div> </div>
</div> </div>

@ -207,7 +207,9 @@
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" data-href="{:U('download/arpu_data_export',array_merge(['xlsname'=>'ceshi'],I('post.')))}" class="ajax-get">导出</a> <a id="sch-btn" data-href="{:U('download/arpu_data_export',array_merge(['xlsname'=>'ceshi'],I('post.')))}" class="ajax-get">导出</a>
<?php endif ;?>
</div> </div>
</div> </div>
</div> </div>

@ -239,7 +239,9 @@
</table> </table>
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<p id="sch-btn" data-href="{:U('download/dailysummary_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">导出</p> <?php if ($loginer['level'] == 1) :?>
<p id="sch-btn" data-href="{:U('download/dailysummary_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">导出</p>
<?php endif ;?>
</div> </div>
<div style="margin-bottom: 150px;"> <div style="margin-bottom: 150px;">

@ -220,7 +220,9 @@
</table> </table>
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" data-href="{:U('download/recharge_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">导出</a> <a id="sch-btn" data-href="{:U('download/recharge_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">导出</a>
<?php endif ;?>
{$_page} {$_page}
</div> </div>
</div> </div>

@ -134,7 +134,9 @@
</table> </table>
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" data-href="{:U('download/regist_data_export',array_merge(['xlsname'=>'ceshi'],I('post.')))}" class="ajax-get">导出</a> <a id="sch-btn" data-href="{:U('download/regist_data_export',array_merge(['xlsname'=>'ceshi'],I('post.')))}" class="ajax-get">导出</a>
<?php endif ;?>
{$_page} {$_page}
</div> </div>
</div> </div>

@ -208,7 +208,9 @@
</table> </table>
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" data-href="{:U('download/summary_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">导出</a> <a id="sch-btn" data-href="{:U('download/summary_data_export',array_merge(['xlsname'=>'ceshi'],I('get.')))}" class="ajax-get">导出</a>
<?php endif ;?>
{$_page} {$_page}
</div> </div>
</div> </div>

@ -108,7 +108,9 @@
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" data-href="{:U('download/userRecharge_data_export',array_merge(['xlsname'=>'ceshi'],I('post.')))}" class="ajax-get">导出</a> <a id="sch-btn" data-href="{:U('download/userRecharge_data_export',array_merge(['xlsname'=>'ceshi'],I('post.')))}" class="ajax-get">导出</a>
<?php endif ;?>
{$pagination} {$pagination}
</div> </div>
</div> </div>

@ -107,7 +107,9 @@
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" data-href="{:U('download/userRoles_data_export',array_merge(['xlsname'=>'ceshi'],I('post.')))}" class="ajax-get">导出</a> <a id="sch-btn" data-href="{:U('download/userRoles_data_export',array_merge(['xlsname'=>'ceshi'],I('post.')))}" class="ajax-get">导出</a>
<?php endif ;?>
{$pagination} {$pagination}
</div> </div>
</div> </div>

@ -292,7 +292,9 @@
</div> </div>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" href="{:U('download/testresource_data_export',array_merge(['promote_type'=>'xxx'],I('get.')))}" class="ajax-get" >导出</a> <a id="sch-btn" href="{:U('download/testresource_data_export',array_merge(['promote_type'=>'xxx'],I('get.')))}" class="ajax-get" >导出</a>
<?php endif ;?>
{$_page} {$_page}
</div> </div>

@ -156,7 +156,9 @@
</table> </table>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" href="{:U('download/testresourcelists_data_export',array_merge(['promote_type'=>'xxx'],I('get.')))}" class="ajax-get" >导出</a> <a id="sch-btn" href="{:U('download/testresourcelists_data_export',array_merge(['promote_type'=>'xxx'],I('get.')))}" class="ajax-get" >导出</a>
<?php endif ;?>
{$_page} {$_page}
</div> </div>
</div> </div>

@ -178,7 +178,9 @@
</table> </table>
<div class="pagenation clearfix"> <div class="pagenation clearfix">
<?php if ($loginer['level'] == 1) :?>
<a id="sch-btn" href="{:U('download/supportNumberList_data_export',array_merge(['promote_type'=>'xxx'],I('get.')))}" class="ajax-get" >导出</a> <a id="sch-btn" href="{:U('download/supportNumberList_data_export',array_merge(['promote_type'=>'xxx'],I('get.')))}" class="ajax-get" >导出</a>
<?php endif ;?>
{$_page} {$_page}
</div> </div>
</div> </div>

Loading…
Cancel
Save