private void BindDataLog()
 {
     try
     {
         if (PageType == "new" && GroupTypeID == 4108)
         {
             int totalCount = 0;
             int StartIndex = AspNetPager1.StartRecordIndex - 1;
             int EndIndex   = AspNetPager1.PageSize;
             int type       = 65;
             List <OperateRecordEntity> list = new OperateRecordBLL().GetDataList(StartIndex, EndIndex, type, ref totalCount);
             if (totalCount == 0)
             {
                 BtnExportLog.Visible = false;
             }
             this.Repeater1.DataSource = list;
             this.Repeater1.DataBind();
             AspNetPager1.RecordCount = totalCount;
             AspNetPager1.DataBind();
         }
     }
     catch (Exception)
     {
         throw;
     }
 }
Exemple #2
0
        private void BindData(int pageIndex)
        {
            int    pressID   = ConvertHelper.ToInt32(hidPressID.Value);
            string bookGuID  = txtBookGuidLink.Value;
            string timestart = textTimeStart.Text;
            string timeend   = textTimeEnd.Text;
            int    serialId  = ConvertHelper.ToInt32(bookType.SelectedValue);

            if (string.IsNullOrEmpty(timestart))
            {
                timestart          = DateTime.Now.AddDays(-7).ToString("yyyy-MM-dd");
                textTimeStart.Text = DateTime.Now.AddDays(-7).ToString("yyyy-MM-dd");
            }
            if (string.IsNullOrEmpty(timeend))
            {
                timeend          = DateTime.Now.ToString("yyyy-MM-dd");
                textTimeEnd.Text = DateTime.Now.ToString("yyyy-MM-dd");
            }
            if (pageIndex <= 0)
            {
                pageIndex = 1;
            }
            int             recordCount      = 0;
            int             totalPersonCount = 0;
            long            totalTimeLength  = 0;
            int             totalReadCount   = 0;
            BookCountAccess data             = new BookCountAccess();

            DataTable dt = data.GetBookReadCountData(pageIndex, 10, serialId, pressID, bookGuID, timestart, timeend, userId, ref recordCount, ref totalPersonCount, ref totalTimeLength, ref totalReadCount);

            num.Value = recordCount.ToString();
            AspNetPager1.CurrentPageIndex = pageIndex;
            AspNetPager1.RecordCount      = recordCount;
            AspNetPager1.DataBind();
        }
        private void BindData(int pageIndex)
        {
            int    type      = ConvertHelper.ToInt32(CountType.Text);
            string startDate = textTimeStart.Text;
            string endDate   = textTimeEnd.Text;

            if (pageIndex <= 0)
            {
                pageIndex = 1;
            }
            if (string.IsNullOrEmpty(startDate))
            {
                startDate          = DateTime.Now.AddDays(-7).ToString("yyyy-MM-dd");
                textTimeStart.Text = DateTime.Now.AddDays(-7).ToString("yyyy-MM-dd");
            }
            if (string.IsNullOrEmpty(endDate))
            {
                endDate          = DateTime.Now.ToString("yyyy-MM-dd");
                textTimeEnd.Text = DateTime.Now.ToString("yyyy-MM-dd");
            }
            int recordCount = 0;
            T_User_MXZ_History dataAccess = new T_User_MXZ_History();
            int       totalPersonCount    = 0;
            int       totalCoinCount      = 0;
            DataTable dt = dataAccess.GetMXZOrderCountTable(pageIndex, 10, type, startDate, endDate, ref totalPersonCount, ref totalCoinCount, ref recordCount);

            AspNetPager1.CurrentPageIndex = pageIndex;
            AspNetPager1.RecordCount      = recordCount;
            AspNetPager1.DataBind();
        }
Exemple #4
0
 protected void Button1_Click(object src, EventArgs e)
 {
     try
     {
         int pageindex = int.Parse(tb_pageindex.Text);
         AspNetPager1.GoToPage(pageindex);
     }
     catch (FormatException)
     {
         lbl_error.Text = "invalid page index";
     }
 }
Exemple #5
0
        private void BindDataLog()
        {
            int totalCount = 0;

            int StartIndex = AspNetPager1.StartRecordIndex - 1;
            int EndIndex   = AspNetPager1.PageSize;

            List <OperateRecordEntity> list = new OperateRecordBLL().GetDataList(StartIndex, EndIndex, actype, ref totalCount);

            this.Repeater1.DataSource = list;
            this.Repeater1.DataBind();
            AspNetPager1.RecordCount = totalCount;
            AspNetPager1.DataBind();
        }
Exemple #6
0
        private void BindData(int pageIndex)
        {
            int    type = ConvertHelper.ToInt32(TypeChoose.Text);
            string name = Name.Text;

            if (pageIndex <= 0)
            {
                pageIndex = 1;
            }
            int recordCount = 0;
            T_CountToolResource dataAccess = new T_CountToolResource();
            DataTable           dt         = dataAccess.GetResourceData(pageIndex, 10, type, name, ref recordCount);

            num.Value = recordCount.ToString();
            AspNetPager1.CurrentPageIndex = pageIndex;
            AspNetPager1.RecordCount      = recordCount;
            AspNetPager1.DataBind();
        }
        private void BindData(int pageIndex)
        {
            int codeid = 0;

            if (txtBookGuidLink.Value == "")
            {
                codeid = 0;
            }
            else
            {
                codeid = Convert.ToInt32(txtBookGuidLink.Value);
            }
            string startDate = textTimeStart.Text;
            string endDate   = textTimeEnd.Text;

            if (pageIndex <= 0)
            {
                pageIndex = 1;
            }
            if (string.IsNullOrEmpty(startDate))
            {
                startDate          = DateTime.Now.AddDays(-7).ToString("yyyy-MM-dd");
                textTimeStart.Text = DateTime.Now.AddDays(-7).ToString("yyyy-MM-dd");
            }
            if (string.IsNullOrEmpty(endDate))
            {
                endDate          = DateTime.Now.ToString("yyyy-MM-dd");
                textTimeEnd.Text = DateTime.Now.ToString("yyyy-MM-dd");
            }
            int recordCount = 0;
            T_CountToolResource dataAccess = new T_CountToolResource();
            DataTable           dt         = dataAccess.GetWayCountData(pageIndex, 10, startDate, endDate, codeid, ref recordCount);

            num.Value          = recordCount.ToString();
            repData.DataSource = dt;
            repData.DataBind();

            AspNetPager1.CurrentPageIndex = pageIndex;
            AspNetPager1.RecordCount      = recordCount;
            AspNetPager1.DataBind();
        }