Example #1
0
 protected void Sure_Update_Click(object sender, EventArgs e)
 {
     if (Session["StudentNum"] != null)
     {
         Party_InformationDataContext pidc = new Party_InformationDataContext();
         if (pidc.Update_Data.FirstOrDefault(p => p.Update1 == Session["StudentNum"].ToString() && p.Update_Type == 1 && p.Update_Status == 0) == null)
         {
             Update_Data ud = new Update_Data();
             ud.Update_Type  = 1;
             ud.Update_Theme = "修改个人信息";
             ud.Update1      = StudentNum.Text;
             ud.Update2      = placeOfOrigin1.Value;
             ud.Update3      = telephone1.Value;
             ud.Update4      = Address1.Value;
             ud.Update_Time  = DateTime.Now;
             pidc.Update_Data.InsertOnSubmit(ud);
             pidc.SubmitChanges();
             m.MessageBox(this, "修改已提交");
         }
         else
         {
             m.MessageBox(this, "已经提交过修改个人信息申请");
         }
     }
 }
Example #2
0
    [WebMethod]  //密码申诉的方法
    public static string Password_appeal(string studentnum, string reason, string password)
    {
        Method m = new Method();
        Party_InformationDataContext pidc = new Party_InformationDataContext();
        string result = "true";

        if (studentnum != "" && password != "")
        {
            Update_Data ud = new Update_Data();
            ud.Update1       = studentnum;
            ud.Update_Reason = reason;
            ud.Update3       = m.MD5(password);
            ud.Update_Status = 0;
            ud.Update_Type   = 3;
            ud.Update_Time   = DateTime.Now;
            ud.Update_Theme  = studentnum + "密码申诉";
            pidc.Update_Data.InsertOnSubmit(ud);
            pidc.SubmitChanges();
            result = "true";
        }
        else
        {
            result = "false";
        }

        return(result);
    }
    public override void OnInspectorGUI()
    {
        base.OnInspectorGUI();

        Update_Data Data = (Update_Data)target;

        GUILayout.Space(20f);
        if (GUILayout.Button("Update"))
        {
            Data.Notify();
        }
    }
Example #4
0
    protected void sure_review_click(object sender, EventArgs e)
    {
        if (m.Get_FieId_Data("Power_NO", "PartyData", " where studentnum='" + Session["studentnum"].ToString() + "'") != "003")
        {
            string studentnum = save_studentnum.Value;
            bool   result     = true; //判断是否已经添加考核
            for (int i = 0; i < studentnum.Split(',').Length; i++)
            {
                string n = studentnum.Split(',')[i];
                if (pidc.Update_Data.FirstOrDefault(p => p.Update1 == n && p.Update_Type == 4 && p.Update_Status == 0) != null)
                {
                    m.MessageBox(this, "学号为:" + studentnum + "的同学已经添加考核,请重新选择");
                    result = false;
                    return;
                }
            }
            if (result)
            {
                for (int i = 0; i < studentnum.Split(',').Length; i++)
                {
                    string      n  = studentnum.Split(',')[i];
                    Update_Data ud = new Update_Data();
                    ud.Update1       = n;
                    ud.Update2       = MemberStatus.SelectedValue; //党员身份
                    ud.Update_Status = 0;
                    ud.Update_Type   = 4;
                    ud.Update_Time   = DateTime.Now; //创建考核时间
                    ud.Update_Theme  = theme.Text;   //考核时间

                    ud.Review_Time  = Convert.ToDateTime(review_time.Text);
                    ud.Audit_Person = person.Text;
                    pidc.Update_Data.InsertOnSubmit(ud);
                    pidc.SubmitChanges();
                }
                m.MessageBox(this, "添加考核完成");
            }
        }
    }
Example #5
0
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            if (Session["StudentNum"] == null)
            {
                Response.Redirect("../Login.aspx");
            }

            else if (m.Get_FieId_Data("Power_NO", "Personal_Data", " where StudentNum='" + Session["StudentNum"].ToString() + "'") != "003")
            {
                int id = Convert.ToInt32(Request.QueryString["id"]);

                Update_Data ud = pidc.Update_Data.FirstOrDefault(p => p.ID == id);
                if (ud != null)
                {
                    studentnum.Text = ud.Update1;
                    string name = m.Get_FieId_Data("name", "PartyData", " where studentnum='" + ud.Update1 + "'");
                    studentname.Text = name;
                    reason.Text      = ud.Update_Reason;
                    if (ud.Update_Type == 1)
                    {
                        content.Text = "电话号码修改为:<span style='text-decoration:underline;color:#EE2C2C;font-weight:bold'>" + ud.Update3 + "</span>,住址修改为:<span style='text-decoration:underline;color:#EE2C2C;font-weight:bold'>" + ud.Update4 + "</span>,籍贯修改为:<span style='text-decoration:underline;color:#EE2C2C;font-weight:bold'>" + ud.Update2 + "</span><br />申请时间:<span style='text-decoration:underline;color:#EE2C2C;font-weight:bold'>" + ud.Update_Time + "</span>";
                    }
                    else if (ud.Update_Type == 3)
                    {
                        content.Text = "学号为<span style='text-decoration:underline;color:#EE2C2C;font-weight:bold'>" + ud.Update1 + "</span>的同学<span style='text-decoration:underline;color:#EE2C2C;font-weight:bold'>" + name + "</span>申诉密码";
                    }

                    else if (ud.Update_Type == 5)
                    {
                        content.Text = "上传文件:<span style='text-decoration:underline;color:#EE2C2C;font-weight:bold'>" + ud.Update2 + "</span>";
                    }
                }
            }
        }
    }
Example #6
0
    protected void application_pass_click(object sender, EventArgs e)
    {
        if (m.Get_FieId_Data("Power_NO", "Personal_Data", " where StudentNum='" + Session["StudentNum"].ToString() + "'") != "003")
        {
            int         id = Convert.ToInt32(Request.QueryString["id"]);
            Update_Data ud = pidc.Update_Data.FirstOrDefault(p => p.ID == id);
            if (ud != null)
            {
                if (ud.Update_Status == 0)
                {
                    if (ud.Update_Type == 1)
                    {
                        PartyData pd = pidc.PartyData.FirstOrDefault(p => p.StudentNum == ud.Update1);
                        #region  个人信息新盖审核
                        if (pd != null)
                        {
                            pd.PlaceOfOrigin = ud.Update2;
                            pd.Telephone     = ud.Update3;
                            pd.Address       = ud.Update4;
                            ud.Update_Time   = DateTime.Now;
                            ud.Update_Remark = Remark.Text;
                            ud.Audit_Person  = m.Get_FieId_Data("name", "PartyData", " where studentnum='" + ud.Update1 + "'");
                            ud.Update_Status = 1;
                            pidc.SubmitChanges();
                            m.MessageBox(this, "审核通过");
                        }
                        #endregion
                    }
                    #region  密码申诉审核
                    else if (ud.Update_Type == 3)
                    {
                        PartyData pd = pidc.PartyData.FirstOrDefault(p => p.StudentNum == ud.Update1);
                        if (pd != null)
                        {
                            ud.Update_Time   = DateTime.Now;
                            pd.Password      = ud.Update3;
                            ud.Update_Remark = Remark.Text;
                            ud.Audit_Person  = m.Get_FieId_Data("name", "PartyData", " where studentnum='" + ud.Update1 + "'");
                            ud.Update_Status = 1;
                            pidc.SubmitChanges();
                            m.MessageBox(this, "审核通过");
                        }
                    }
                    #endregion

                    #region  党员考核
                    else if (ud.Update_Type == 4)
                    {
                        PartyStatus ps = pidc.PartyStatus.FirstOrDefault(p => p.StudentNum == ud.Update1);
                        if (ps != null)
                        {
                            if (ps.AuditTime1 != null)
                            {
                                ps.AuditTime1    = ud.Review_Time;
                                ps.Auditor1      = ud.Audit_Person;
                                ps.AuditOpinion1 = Remark.Text;
                                if (ud.Update2 != "正式党员")
                                {
                                    ps.MemberStatus_NO = (Convert.ToInt32(m.Get_FieId_Data("TypeNO", "Category", " where TypeName='" + ud.Update2 + "'")) - 1).ToString();
                                }

                                ud.Update_Time = DateTime.Now;

                                ud.Update_Remark = Remark.Text;
                                //ud.Audit_Person = m.Get_FieId_Data("name", "PartyData", " where studentnum='" + ud.Update1 + "'");
                                ud.Update_Status = 1;
                                pidc.SubmitChanges();
                                m.MessageBox(this, "审核通过");
                            }
                            else
                            {
                                if (ps.AuditTime2 != null)
                                {
                                    ps.AuditTime2    = ud.Review_Time;
                                    ps.Auditor2      = ud.Audit_Person;
                                    ps.AuditOpinion2 = Remark.Text;
                                    if (ud.Update2 != "正式党员")
                                    {
                                        ps.MemberStatus_NO = (Convert.ToInt32(m.Get_FieId_Data("TypeNO", "Category", " where TypeName='" + ud.Update2 + "'")) - 1).ToString();
                                    }

                                    ud.Update_Time = DateTime.Now;

                                    ud.Update_Remark = Remark.Text;
                                    //ud.Audit_Person = m.Get_FieId_Data("name", "PartyData", " where studentnum='" + ud.Update1 + "'");
                                    ud.Update_Status = 1;
                                    pidc.SubmitChanges();
                                    m.MessageBox(this, "审核通过");
                                }
                                else
                                {
                                    if (ps.AuditTime3 != null)
                                    {
                                        ps.AuditTime3    = ud.Review_Time;
                                        ps.Auditor3      = ud.Audit_Person;
                                        ps.AuditOpinion3 = Remark.Text;
                                        if (ud.Update2 != "正式党员")
                                        {
                                            ps.MemberStatus_NO = (Convert.ToInt32(m.Get_FieId_Data("TypeNO", "Category", " where TypeName='" + ud.Update2 + "'")) - 1).ToString();
                                        }

                                        ud.Update_Time = DateTime.Now;

                                        ud.Update_Remark = Remark.Text;
                                        //ud.Audit_Person = m.Get_FieId_Data("name", "PartyData", " where studentnum='" + ud.Update1 + "'");
                                        ud.Update_Status = 1;
                                        pidc.SubmitChanges();
                                        m.MessageBox(this, "审核通过");
                                    }
                                }
                            }
                        }
                    }
                    #endregion

                    #region    资料审核
                    if (ud.Update_Type == 5)
                    {
                        ud.Update_Status = 1;
                        ud.Audit_Person  = m.Get_FieId_Data("name", "PartyData", " where studentnum='" + Session["studentnum"].ToString() + "'");
                        ud.Update_Remark = Remark.Text;
                        Datum d = pidc.Datum.FirstOrDefault(p => p.Datum_ID == Convert.ToInt32(ud.Update3));
                        if (d != null)
                        {
                            d.Audit_State = 1;
                        }
                        pidc.SubmitChanges();

                        m.MessageBox(this, "审核通过");
                    }
                    #endregion
                }
                else
                {
                    m.MessageBox(this, "只能审核未审核的");
                }
            }
        }
    }
Example #7
0
    protected void application_fail_click(object sender, EventArgs e)
    {
        if (m.Get_FieId_Data("Power_NO", "Personal_Data", " where StudentNum='" + Session["StudentNum"].ToString() + "'") != "003")
        {
            int         id = Convert.ToInt32(Request.QueryString["id"]);
            Update_Data ud = pidc.Update_Data.FirstOrDefault(p => p.ID == id);
            if (ud != null)
            {
                if (ud.Update_Status == 0)
                {
                    #region  党员考核
                    if (ud.Update_Type == 4)
                    {
                        PartyStatus ps = pidc.PartyStatus.FirstOrDefault(p => p.StudentNum == ud.Update1);
                        if (ps != null)
                        {
                            if (ps.AuditTime1 != null)
                            {
                                ps.AuditTime1    = ud.Review_Time;
                                ps.Auditor1      = ud.Audit_Person;
                                ps.AuditOpinion1 = Remark.Text;
                                // ps.MemberStatus_NO = (Convert.ToInt32(m.Get_FieId_Data("TypeNO", "Category", " where TypeName='" + ud.Update2 + "'")) - 1).ToString();


                                ud.Update_Time = DateTime.Now;

                                ud.Update_Remark = Remark.Text;
                                //ud.Audit_Person = m.Get_FieId_Data("name", "PartyData", " where studentnum='" + ud.Update1 + "'");
                                ud.Update_Status = 2;
                                pidc.SubmitChanges();
                                m.MessageBox(this, "考核不通过");
                            }
                            else
                            {
                                if (ps.AuditTime2 != null)
                                {
                                    ps.AuditTime2    = ud.Review_Time;
                                    ps.Auditor2      = ud.Audit_Person;
                                    ps.AuditOpinion2 = Remark.Text;
                                    // ps.MemberStatus_NO = (Convert.ToInt32(m.Get_FieId_Data("TypeNO", "Category", " where TypeName='" + ud.Update2 + "'")) - 1).ToString();


                                    ud.Update_Time = DateTime.Now;

                                    ud.Update_Remark = Remark.Text;
                                    //ud.Audit_Person = m.Get_FieId_Data("name", "PartyData", " where studentnum='" + ud.Update1 + "'");
                                    ud.Update_Status = 2;
                                    pidc.SubmitChanges();
                                    m.MessageBox(this, "考核不通过");
                                }
                                else
                                {
                                    if (ps.AuditTime3 != null)
                                    {
                                        ps.AuditTime3    = ud.Review_Time;
                                        ps.Auditor3      = ud.Audit_Person;
                                        ps.AuditOpinion3 = Remark.Text;
                                        // ps.MemberStatus_NO = (Convert.ToInt32(m.Get_FieId_Data("TypeNO", "Category", " where TypeName='" + ud.Update2 + "'")) - 1).ToString();


                                        ud.Update_Time = DateTime.Now;

                                        ud.Update_Remark = Remark.Text;
                                        //ud.Audit_Person = m.Get_FieId_Data("name", "PartyData", " where studentnum='" + ud.Update1 + "'");
                                        ud.Update_Status = 2;
                                        pidc.SubmitChanges();
                                        m.MessageBox(this, "考核不通过");
                                    }
                                }
                            }
                        }
                    }
                    #endregion
                    else
                    {
                        ud.Update_Time   = DateTime.Now;
                        ud.Update_Remark = Remark.Text;
                        ud.Audit_Person  = m.Get_FieId_Data("name", "PartyData", " where studentnum='" + Session["studentnum"].ToString() + "'");
                        ud.Update_Status = 2;
                        pidc.SubmitChanges();
                        m.MessageBox(this, "审核不通过");
                    }
                }
                else
                {
                    m.MessageBox(this, "只能审核未审核的");
                }
            }
        }
    }