예제 #1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                dtTerm = CB.SelectAllTerm();
                ddl_Term.DataTextField = "tterm";
                ddl_Term.DataSource    = dtTerm;
                ddl_Term.DataBind();
                ddl_Term.Items.Add(new ListItem("انتخاب کنید", "0"));
                ddl_Term.Items[ddl_Term.Items.Count - 1].Selected = true;
                if (Request.QueryString["Term"] != null)
                {
                    ddl_Term.SelectedValue = Request.QueryString["Term"].ToString();
                }
                int iddanesh = 0;
                if (Session["RoleID"].ToString() == "51" || Session["RoleID"].ToString() == "17")
                {
                    iddanesh = 1;
                }
                if (Session["RoleID"].ToString() == "52" || Session["RoleID"].ToString() == "16")
                {
                    iddanesh = 3;
                }
                if (Session["RoleID"].ToString() == "53" || Session["RoleID"].ToString() == "15")
                {
                    iddanesh = 2;
                }


                dtGroup = FRB.GetAllGroup(iddanesh);
                ddl_CodeGroup.DataTextField  = "namegroup";
                ddl_CodeGroup.DataValueField = "id";
                ddl_CodeGroup.DataSource     = dtGroup;
                ddl_CodeGroup.DataBind();
                ddl_CodeGroup.Items.Add(new ListItem("انتخاب کنید", "0"));
                ddl_CodeGroup.Items[ddl_CodeGroup.Items.Count - 1].Selected = true;
                if (Request.QueryString["Departman"] != null)
                {
                    ddl_CodeGroup.SelectedValue = Request.QueryString["Departman"].ToString();
                }
                dtDars = ERB.GetListDorus();
                ddl_CodeDras.DataTextField  = "namedars";
                ddl_CodeDras.DataValueField = "dcode";
                ddl_CodeDras.DataSource     = dtDars;
                ddl_CodeDras.DataBind();
                ddl_CodeDras.Items.Add(new ListItem("انتخاب کنید", "0"));
                ddl_CodeDras.Items[ddl_CodeDras.Items.Count - 1].Selected = true;
                if (Request.QueryString["Lesson"] != null)
                {
                    ddl_CodeDras.SelectedValue = Request.QueryString["Lesson"].ToString();
                }
            }
            if (Session["code_ostad"] != null)
            {
                txt_CodeOstad.Text = Session["code_ostad"].ToString();
            }
        }
        protected void Page_Load(object sender, EventArgs e)
        {
            StiWebViewer1.Visible = false;
            if (!IsPostBack)
            {
                //
                string   mId    = Request.QueryString["id"].ToString();
                string[] id     = mId.ToString().Split(new char[] { '@' });
                string   menuId = "";
                for (int i = 0; i < id[1].Length; i++)
                {
                    string s = id[1].Substring(i + 1, 1);
                    if (s != "-")
                    {
                        menuId += s;
                    }
                    else
                    {
                        break;
                    }
                    Session[sessionNames.menuID] = menuId;
                }
                AccessControl1.MenuId = Session[sessionNames.menuID].ToString();
                AccessControl1.UserId = Session[sessionNames.userID_Karbar].ToString();
                //
                dtTerm = CB.SelectAllTerm();
                ddl_Term.DataTextField = "tterm";
                ddl_Term.DataSource    = dtTerm;
                ddl_Term.DataBind();
                ddl_Term.Items.Add(new ListItem("انتخاب کنید", "0"));
                ddl_Term.Items[ddl_Term.Items.Count - 1].Selected = true;
                int iddanesh = 0;
                if (Session["RoleID"].ToString() == "51" || Session["RoleID"].ToString() == "17")
                {
                    iddanesh = 1;
                }
                if (Session["RoleID"].ToString() == "52" || Session["RoleID"].ToString() == "16")
                {
                    iddanesh = 3;
                }
                if (Session["RoleID"].ToString() == "53" || Session["RoleID"].ToString() == "15")
                {
                    iddanesh = 2;
                }


                dtGroup = FRB.GetAllGroup(iddanesh);
                ddl_EducationGroup.DataTextField  = "namegroup";
                ddl_EducationGroup.DataValueField = "id";
                ddl_EducationGroup.DataSource     = dtGroup;
                ddl_EducationGroup.DataBind();
                ddl_EducationGroup.Items.Add(new ListItem("انتخاب کنید", "0"));
                ddl_EducationGroup.Items[ddl_EducationGroup.Items.Count - 1].Selected = true;
                //dtCooperation = FRB.GetCooperation();
                //ddl_Cooperation.DataTextField = "name_nahveh";
                //ddl_Cooperation.DataValueField = "nahveh_hamk";
                //ddl_Cooperation.DataSource = dtCooperation;
                //ddl_Cooperation.DataBind();
                //ddl_Cooperation.Items.Add(new ListItem("انتخاب کنید","0"));
                //ddl_Cooperation.Items[ddl_Cooperation.Items.Count - 1].Selected = true;
                ddl_Cooperation.Items.Add(new ListItem("تمام وقت 32 ساعت", "1"));
                ddl_Cooperation.Items.Add(new ListItem("نیمه وقت", "2"));
                ddl_Cooperation.Items.Add(new ListItem("ساعتی-حق التدریس", "3"));
                ddl_Cooperation.Items.Add(new ListItem("تمام وقت طرح مشمولان", "4"));
                ddl_Cooperation.Items.Add(new ListItem("بورسیه دکترا", "5"));
                ddl_Cooperation.Items.Add(new ListItem("کارمند", "6"));
                ddl_Cooperation.Items.Add(new ListItem("تمام وقت 44 ساعت", "7"));
                ddl_Cooperation.Items.Add(new ListItem("انتخاب کنید", "0"));
                ddl_Cooperation.Items[ddl_Cooperation.Items.Count - 1].Selected = true;
            }
        }
예제 #3
0
        protected void Page_Load(object sender, EventArgs e)
        {
            StiWebViewer1.Visible = false;
            if (!IsPostBack)
            {
                //
                string   mId    = Request.QueryString["id"].ToString();
                string[] id     = mId.ToString().Split(new char[] { '@' });
                string   menuId = "";
                for (int i = 0; i < id[1].Length; i++)
                {
                    string s = id[1].Substring(i + 1, 1);
                    if (s != "-")
                    {
                        menuId += s;
                    }
                    else
                    {
                        break;
                    }
                    Session[sessionNames.menuID] = menuId;
                }
                AccessControl1.MenuId = Session[sessionNames.menuID].ToString();
                AccessControl1.UserId = Session[sessionNames.userID_Karbar].ToString();
                //
                dtTerm = CB.SelectAllTerm();
                ddl_Term.DataTextField = "tterm";
                ddl_Term.DataSource    = dtTerm;
                ddl_Term.DataBind();
                ddl_Term.Items.Add(new ListItem("انتخاب کنید", "0"));
                ddl_Term.Items[ddl_Term.Items.Count - 1].Selected = true;
                if (Request.QueryString["Term"] != null)
                {
                    ddl_Term.SelectedValue = Request.QueryString["Term"].ToString();
                }
                int iddanesh = 0;
                if (Session["RoleID"].ToString() == "51" || Session["RoleID"].ToString() == "17")
                {
                    iddanesh = 1;
                }
                if (Session["RoleID"].ToString() == "52" || Session["RoleID"].ToString() == "16")
                {
                    iddanesh = 3;
                }
                if (Session["RoleID"].ToString() == "53" || Session["RoleID"].ToString() == "15")
                {
                    iddanesh = 2;
                }


                dtGroup = FRB.GetAllGroup(iddanesh);
                ddl_GroupOstad.DataTextField  = "namegroup";
                ddl_GroupOstad.DataValueField = "id";
                ddl_GroupOstad.DataSource     = dtGroup;
                ddl_GroupOstad.DataBind();
                ddl_GroupOstad.Items.Add(new ListItem("انتخاب کنید", "0"));
                ddl_GroupOstad.Items[ddl_GroupOstad.Items.Count - 1].Selected = true;
                if (Request.QueryString["Departman"] != null)
                {
                    ddl_GroupOstad.SelectedValue = Request.QueryString["Departman"].ToString();
                }
                dtDaneshkade = CB.SelectAllDaneshkade();
                ddl_Daneshkade.DataTextField  = "namedanesh";
                ddl_Daneshkade.DataValueField = "id";
                ddl_Daneshkade.DataSource     = dtDaneshkade;
                ddl_Daneshkade.DataBind();
                ddl_Daneshkade.Items.Add(new ListItem("انتخاب کنید", "0"));
                ddl_Daneshkade.Items[ddl_Daneshkade.Items.Count - 1].Selected = true;
                if (Request.QueryString["Daneshkade"] != null)
                {
                    ddl_Daneshkade.SelectedValue = Request.QueryString["Daneshkade"].ToString();
                }
                if (Request.QueryString["AzD"] != null)
                {
                    txt_FromDate.Text = Request.QueryString["AzD"].ToString();
                }
                if (Request.QueryString["TaD"] != null)
                {
                    txt_ToDate.Text = Request.QueryString["TaD"].ToString();
                }
                if (Request.QueryString["AzJ"] != null)
                {
                    txt_AzJobrani.Text = Request.QueryString["AzJ"].ToString();
                }
                if (Request.QueryString["TaJ"] != null)
                {
                    txt_ToJobrani.Text = Request.QueryString["TaJ"].ToString();
                }
                if (Request.QueryString["NumberAbsence"] != null)
                {
                    txt_NumberAbsence.Text = Request.QueryString["NumberAbsence"].ToString();
                }
            }

            if (Session["code_ostad"] != null)
            {
                txt_CodeOstad.Text = Session["code_ostad"].ToString();
            }
        }
예제 #4
0
        protected void Page_Load(object sender, EventArgs e)
        {
            //this.StiWebViewer1.ResetReport();
            StiWebViewer1.Visible = false;
            if (!IsPostBack)
            {
                //
                string   mId    = Request.QueryString["id"].ToString();
                string[] id     = mId.ToString().Split(new char[] { '@' });
                string   menuId = "";
                for (int i = 0; i < id[1].Length; i++)
                {
                    string s = id[1].Substring(i + 1, 1);
                    if (s != "-")
                    {
                        menuId += s;
                    }
                    else
                    {
                        break;
                    }
                    Session[sessionNames.menuID] = menuId;
                }
                AccessControl1.MenuId = Session[sessionNames.menuID].ToString();
                AccessControl1.UserId = Session[sessionNames.userID_Karbar].ToString();
                //
                dtTerm = CB.SelectAllTerm();
                ddl_Term.DataTextField = "tterm";
                ddl_Term.DataSource    = dtTerm;
                ddl_Term.DataBind();
                ddl_Term.Items.Add(new ListItem("انتخاب کنید", "0"));
                ddl_Term.Items[ddl_Term.Items.Count - 1].Selected = true;
                if (Request.QueryString["Term"] != null)
                {
                    ddl_Term.SelectedValue = Request.QueryString["Term"].ToString();
                }
                int iddanesh = 0;
                if (Session[sessionNames.roleID].ToString() == "51" || Session[sessionNames.roleID].ToString() == "17")
                {
                    iddanesh = 1;
                }
                if (Session[sessionNames.roleID].ToString() == "52" || Session[sessionNames.roleID].ToString() == "16")
                {
                    iddanesh = 3;
                }
                if (Session[sessionNames.roleID].ToString() == "53" || Session[sessionNames.roleID].ToString() == "15")
                {
                    iddanesh = 2;
                }



                dtGroup = FRB.GetAllGroup(iddanesh);
                ddl_CodeGroup.DataTextField  = "namegroup";
                ddl_CodeGroup.DataValueField = "id";
                ddl_CodeGroup.DataSource     = dtGroup;
                ddl_CodeGroup.DataBind();
                ddl_CodeGroup.Items.Add(new ListItem("انتخاب کنید", "0"));
                ddl_CodeGroup.Items[ddl_CodeGroup.Items.Count - 1].Selected = true;
                if (Request.QueryString["Departman"] != null)
                {
                    ddl_CodeGroup.SelectedValue = Request.QueryString["Departman"].ToString();
                }
                dtDars = ERB.GetListDorus();
                ddl_CodeDras.DataTextField  = "namedars";
                ddl_CodeDras.DataValueField = "dcode";
                ddl_CodeDras.DataSource     = dtDars;
                ddl_CodeDras.DataBind();
                ddl_CodeDras.Items.Add(new ListItem("انتخاب کنید", "0"));
                ddl_CodeDras.Items[ddl_CodeDras.Items.Count - 1].Selected = true;
                if (Request.QueryString["Lesson"] != null)
                {
                    ddl_CodeDras.SelectedValue = Request.QueryString["Lesson"].ToString();
                }
            }
            if (Session["code_ostad"] != null)
            {
                txt_CodeOstad.Text = Session["code_ostad"].ToString();
            }
        }