示例#1
0
    protected void ShowLogButton_Click(object sender, EventArgs e)
    {
        LogRepeater.DataSource = InternalServices.GetAppRestartLogData();
        LogRepeater.DataBind();

        dataBlock.Visible = true;
    }
示例#2
0
 protected void nextButton(object sender, EventArgs e)
 {
     logPage++;
     LogRepeater.DataSource = BusinessLayers.Business.getLogs(logPage);
     LogRepeater.DataBind();
     LogRepeater.Visible = true;
 }
示例#3
0
 protected void prevButton(object sender, EventArgs e)
 {
     logPage--;
     if (logPage < 0)
     {
         logPage = 0;
     }
     LogRepeater.DataSource = BusinessLayers.Business.getLogs(logPage);
     LogRepeater.DataBind();
     LogRepeater.Visible = true;
 }
示例#4
0
        protected void Next_OnClick(object sender, EventArgs e)
        {
            int currentPage = int.Parse(Session["CurrentPage"].ToString());
            var logs        = _logRepository.GetAll().Skip(currentPage * ItemPerPage).Take(ItemPerPage).ToList();

            if (logs.Any())
            {
                Session["CurrentPage"] = currentPage + 1;
                LogRepeater.DataSource = logs;
                LogRepeater.DataBind();
            }
        }
示例#5
0
        protected void Page_Init(object sender, EventArgs e)
        {
            Session["Active"] = "LogList";

            if (!IsPostBack)
            {
                Session["CurrentPage"] = 1;

                LogRepeater.DataSource = _logRepository.GetAll().Take(ItemPerPage).ToList();
                LogRepeater.DataBind();
            }
        }
示例#6
0
        protected void selectTable_SelectedIndexChanged(object sender, EventArgs e)
        {
            DietitianRepeater.Dispose();
            DietitianRepeater.Visible = false;
            UserRepeater.Dispose();
            UserRepeater.Visible          = false;
            DietRepeater.Visible          = false;
            BlogPostRepeater.Visible      = false;
            PaymentRepeater.Visible       = false;
            MedicalReportRepeater.Visible = false;
            AppointmentRepeater.Visible   = false;
            DietRequestRepeater.Visible   = false;
            DietViewRepeater.Visible      = false;
            DietRepeater.Dispose();
            BlogPostRepeater.Dispose();
            PaymentRepeater.Dispose();
            MedicalReportRepeater.Dispose();
            AppointmentRepeater.Dispose();
            DietRequestRepeater.Dispose();
            DietViewRepeater.Dispose();
            LogRepeater.Visible = false;
            LogRepeater.Dispose();

            DropDownList drp = (DropDownList)sender;

            switch (drp.SelectedIndex)
            {
            case 1:
                UserRepeater.DataBind();
                UserRepeater.Visible = true;
                break;

            case 2:
                DietitianRepeater.DataBind();
                DietitianRepeater.Visible = true;
                break;

            case 3:
                AppointmentRepeater.DataBind();
                AppointmentRepeater.Visible = true;
                break;

            case 4:
                PaymentRepeater.DataBind();
                PaymentRepeater.Visible = true;
                break;

            case 5:
                MedicalReportRepeater.DataBind();
                MedicalReportRepeater.Visible = true;
                break;

            case 6:
                DietRequestRepeater.DataBind();
                DietRequestRepeater.Visible = true;
                break;

            case 7:
                DietRepeater.DataBind();
                DietRepeater.Visible = true;
                break;

            case 8:
                BlogPostRepeater.DataBind();
                BlogPostRepeater.Visible = true;
                break;

            case 9:
                DietViewRepeater.DataBind();
                DietViewRepeater.Visible = true;
                break;

            case 10:
                LogRepeater.DataBind();
                LogRepeater.Visible = true;
                break;
            }
        }