Ejemplo n.º 1
0
        protected override void ShowPage()
        {
            pagetitle = "用户控制面板";

            if (!IsLogin())
            {
                return;
            }

            //获取积分支出记录数
            payoutlogcount = PaymentLogs.GetPaymentLogOutRecordCount(userid);
            BindItems(payoutlogcount);
            payloglist = PaymentLogs.GetPayLogOutList(16, pageid, userid);
        }
        protected override void ShowPage()
        {
            pagetitle = "用户控制面板";

            if (userid == -1)
            {
                AddErrLine("你尚未登录");

                return;
            }
            user = Discuz.Forum.Users.GetUserInfo(userid);

            //得到当前用户请求的页数
            pageid = DNTRequest.GetInt("page", 1);
            //获取主题总数
            payoutlogcount = PaymentLogs.GetPaymentLogOutRecordCount(userid);
            //获取总页数
            pagecount = payoutlogcount % pagesize == 0 ? payoutlogcount / pagesize : payoutlogcount / pagesize + 1;
            if (pagecount == 0)
            {
                pagecount = 1;
            }
            //修正请求页数中可能的错误
            if (pageid < 1)
            {
                pageid = 1;
            }
            if (pageid > pagecount)
            {
                pageid = pagecount;
            }

            //获取收入记录并分页显示
            payloglist = PaymentLogs.GetPayLogOutList(pagesize, pageid, userid);

            pagenumbers = Utils.GetPageNumbers(pageid, pagecount, "usercpcreditspayoutlog.aspx", 8);
        }