Exemplo n.º 1
0
    protected void grv_v2renke_DataBound(object sender, EventArgs e)
    {
        string username = ((FormsIdentity)HttpContext.Current.User.Identity).Ticket.Name;

        if (!TeacherInfo.IsSuperManager(username))
        {
            string guanlixibuid = TeacherInfo.managerXibu(username);
            if (guanlixibuid != ddl_v2xibu.SelectedValue)
            {
                grv_v2renke.Columns[3].Visible = false;
            }
        }
    }
Exemplo n.º 2
0
    protected void DropDownList1_DataBound(object sender, EventArgs e)
    {
        string username = ((FormsIdentity)HttpContext.Current.User.Identity).Ticket.Name;

        if (!TeacherInfo.IsSuperManager(username))
        {
            string guanlixibuid = TeacherInfo.managerXibu(username);
            if (guanlixibuid != "0")
            {
                DropDownList1.SelectedValue = guanlixibuid;
                DropDownList1.Enabled       = false;
            }
        }
    }
Exemplo n.º 3
0
    protected void GridView1_DataBound(object sender, EventArgs e)
    {
        string username = ((FormsIdentity)HttpContext.Current.User.Identity).Ticket.Name;

        if (TeacherInfo.IsSuperManager(username))
        {
            GridView1.Columns[1].Visible = true;
        }
        else
        {
            string guanlixibuid = TeacherInfo.managerXibu(username);
            if (guanlixibuid == DropDownList3.SelectedValue)
            {
                GridView1.Columns[1].Visible = true;
            }
            else
            {
                GridView1.Columns[1].Visible = false;
            }
        }
    }