Exemple #1
0
 protected void lbAuthList_Click(object sender, EventArgs e)
 {
     pnlChangePass.Visible = false;
     if (lbAuthList.Text == "Show: Authorization List")
     {
         //dgVoucher.Visible = true;
         string    criteria = "(convert(nullif(autho_user_type,1))+1) = " + Session["userlevel"].ToString() + " order by value_date desc, vch_sys_no desc";
         DataTable dtTable  = VouchManager.GetVouchMstAuth(criteria);
         dgVoucher.DataSource = dtTable;
         if (dtTable.Rows.Count > 0)
         {
             pnlTask.Visible   = true;
             dgVoucher.Visible = true;
             lbAuthList.Text   = "Hide: Authorization List";
         }
         dgVoucher.DataBind();
     }
     else
     {
         //dgVoucher.Visible = false;
         pnlTask.Visible   = true;
         dgVoucher.Visible = false;
         lbAuthList.Text   = "Show: Authorization List";
     }
 }
Exemple #2
0
    protected void dgVoucher_PageIndexChanging(object sender, GridViewPageEventArgs e)
    {
        pnlTask.Visible   = true;
        dgVoucher.Visible = true;
        string    userLvl  = Session["userlevel"].ToString();
        string    criteria = "(convert(nullif(autho_user_type,1))+1) = " + userLvl + " order by value_date desc";
        DataTable dtTable  = VouchManager.GetVouchMstAuth(criteria);

        dgVoucher.DataSource = dtTable;
        dgVoucher.PageIndex  = e.NewPageIndex;
        dgVoucher.DataBind();
    }