public function index() {

        $param = array(
            'status' => $this->_status,
            'keyword' => $this->_keyword
        );

        $result = $this->_Model->getlist($param);
        $count = $this->_Model->getlistcount($param);
        $pagesize = 10;

        $pageObj = new Page($count, $pagesize);
        $pageObj->parameter = "&" . http_build_query($param);
        $page = $pageObj->show();
        
        $page = new Page2($count, $pagesize);
        $page->quicklySet($this->_p,7);
        $limit = $page->returnlimit();
        $param['limit'] = $limit;

        foreach ($result as &$v) {
            foreach ($v as $key => &$value) {
                if ($key == 'created_at') {
                    $v['created_ats'] = empty($value) ? '' : date('Y-m-d H:i:s', $value);
                }
                if ($key == 'status') {
                    $v['status_name'] = $value == 1 ? '有效' : '无效';
                }
            }
        }

        $this->assign('page', $page->pageArray());
        $this->assign('param', $param);
        $this->assign('result', $result);
        $this->display('Admin.Channel.Channel');
    }
    /**
     * 合伙人审核列表
     */
    public function checkPartnerList() {

        //前端页面默认打开
        if (!empty($this->_openid)) {
            $num = $this->_model->getopenidordernuminpartnerinfo($this->_openid);
            $currentPage = ceil($num / $this->pagesize); //反推 第几页
            $remain = $num % $this->pagesize; //反推某一页的第几条
        }

        $param = array();
        $param['name'] = $this->getParam('name');
        $param['sTime'] = $this->getParam('sTime');
        $param['eTime'] = $this->getParam('eTime');
        $param['state'] = $this->getParam('state');
        $param['sex'] = $this->getParam('sex');

        $param['order'] = " order by id DESC ";
        $param['special'] = " AND state in (0,2) "; //特殊wehere条件
        //获取总记录数
        $count = $this->_Model->getPartnerCount($param);

        $page = new Page2($count, $this->pagesize);
        $page->quicklySet(isset($currentPage) ? $currentPage : $this->_p, 7);
        $limit = $page->returnlimit();

        $param['limit'] = $limit;

        //获取列表
        $partnerList = $this->_Model->getPartnerList($param, 'p.*, ps.par_number');

        unset($param['order']);
        unset($param['limit']);
        unset($param['special']);

        $this->assign('page', $page->pageArray());
        $this->assign('param', $param);
        $this->assign('partnerList', $partnerList);
        $this->display("Admin.Partner.checkPartnerList");
    }
Example #3
0
    /**
     * 卡券补充审核
     *
     */
    public function cardSupAuditList() {
         $status = array(
            '0' => '待审核',
            '1' => '已补充',
            '2' => '拒绝补充'
        );

        $pagesize = 20;
        $param = array(
            'code' => $this->getParam('code'),
            'create_time' => $this->getParam('create_time'),
            'end_time' => $this->getParam('end_time'),
            'sub_status' => $this->getParam('sub_status'),
            'channel' => $this->getParam('channel'),
             'card_type' => $this->getParam('card_type')
               
        );
      
        $list = $this->_Model->querySupList($pagesize, $this->_p, $param);
        $channel = $this->_Model->queryChannel();
        $cardType = $this->_Model->queryCardid();
        $count = isset($list['count']) ? $list['count'] : 0;
        unset($list['count']);
        $page = new Page2($count, $this->pagesize);
        $page->quicklySet(isset($currentPage)?$currentPage:$this->_p,7);
        $limit = $page->returnlimit();
        $this->assign('page', $page->pageArray());
        $this->assign('list', $list['data']);
        $this->assign('channel',$channel);
        $this->assign('cardType',$cardType);
        $this->assign('status',$status);
       
        $this->assign('param', $param);

        $this->display("Admin.Card.cardsupauditlist");
    }
Example #4
0
<?php

require_once "rpcl/rpcl.inc.php";
require_once "MasterPage.php";
//Includes
use_unit("forms.inc.php");
use_unit("extctrls.inc.php");
use_unit("stdctrls.inc.php");
//Class definition
class Page2 extends MasterPage
{
}
global $application;
global $Page2;
//Creates the form
$Page2 = new Page2($application);
//Read from resource file
$Page2->loadResource(__FILE__);
//Shows the form
$Page2->show();
    private function getmyverificdata($p, $param) {
        $pagesize = 5;
        $totalrecord = $this->_Model->getverificlistcount($this->_openId, $param);
        // var_dump($totalrecord);
        $page = new Page2($totalrecord, $pagesize);
        $page->setCurrentPage($p);
        $limit = $page->returnlimit(false);

        $myveric = $this->_Model->getverificlist($limit, $this->_openId, $param);

        return $myveric;
    }
    public function withdrawals(){
        
        $totalrecord = $this->_model->getgetcashlistcount($this->_param);

        $page = new Page2($totalrecord,$this->pagesize);
        $page->quicklySet($this->_p,7);
        $limit = $page->returnlimit();

        $result = $this->_model->getgetcashlist( $this->_param ,$limit);
        
        $partnerModel = loadModel('Admin.Partner');
        if ($result) {
            foreach($result as &$value){
                foreach($value as $k=>&$v){
                    if($k == 'integral'){
                        $res = $partnerModel->getPartnerLevelByScore($v);
                        $value['grade'] = $res['name'];
                    }
                }
            }
        }
        
        $this->assign('levellist', $this->_model->getlevellist());
        $this->assign('channellist', $this->_model->getchannellist());
        
        $this->assign('page', $page->pageArray());
        $this->assign('result', $result?$result:array());
        $this->display('Admin.Rebate.Withdrawals');
    }