Beispiel #1
0
 protected void btnSave_Click(object sender, EventArgs e)
 {
     if (IsPageValid())
     {
         int            emid = Convert.ToInt32(Session["EmployeeId"]);
         BasEmScoreInfo bes  = new BasEmScoreInfo();
         bes.EmployeeId      = emid;
         bes.DateSpan        = ddlYear.SelectedItem.Text + "年" + ddlMonth.SelectedItem.Text + "月";
         bes.YearId          = Convert.ToInt32(ddlYear.SelectedValue);
         bes.MonthId         = Convert.ToInt32(ddlMonth.SelectedValue);
         bes.EvaluateLevelId = 6;
         bes.TotalScore      = "待评";
         bes.IsSubmit        = 0;
         bes.Selfbas1        = Request.Form["iSelfbas1"].ToString();
         bes.Selfbas2        = Request.Form["iSelfbas2"].ToString();
         bes.Selfbas3        = Request.Form["iSelfbas3"].ToString();
         bes.Selfbas4        = Request.Form["iSelfbas4"].ToString();
         bes.Selfbas5        = Request.Form["iSelfbas5"].ToString();
         bes.Selfbas6        = Request.Form["iSelfbas6"].ToString();
         bes.Selfbas7        = Request.Form["iSelfbas7"].ToString();
         bes.Selfbas8        = Request.Form["iSelfbas8"].ToString();
         bes.Selfbas9        = Request.Form["iSelfbas9"].ToString();
         bes.Selfbas10       = Request.Form["iSelfbas10"].ToString();
         bes.Selfbas11       = Request.Form["iSelfbas11"].ToString();
         bes.Selfbas12       = Request.Form["iSelfbas12"].ToString();
         bes.Selfbas13       = Request.Form["iSelfbas13"].ToString();
         bes.Selfbas14       = Request.Form["iSelfbas14"].ToString();
         bes.Selfbas15       = Request.Form["iSelfbas15"].ToString();
         bes.Selfbas16       = Request.Form["iSelfbas16"].ToString();
         bes.Selfbas17       = Request.Form["iSelfbas17"].ToString();
         bes.Save();
         Page.ClientScript.RegisterStartupScript(this.GetType(), "", "<script language='javascript'>alert('保存成功!');</script>");
     }
 }
Beispiel #2
0
        protected void btnSubmit_Click(object sender, EventArgs e)
        {
            int            BasEmScoreId = Convert.ToInt32(((Button)sender).CommandArgument.ToString());
            BasEmScoreInfo bas          = new BasEmScoreInfo(BasEmScoreId);

            bas.IsSubmit = 1;

            int          recvid = Convert.ToInt32(Common.getEmployeeIdOfMarketManager());
            EmployeeInfo em     = new EmployeeInfo(Convert.ToInt32(bas.EmployeeId));
            EmployeeInfo ems    = new EmployeeInfo(recvid);

            MessageInfo.Msgs1(recvid, bas.BasEmScoreId, "~/Score/BASEmApprove.aspx", em.EmployeeName + "绩效考核申请", em.EmployeeName, "daiban", em.EmployeeName + "绩效考核申请");
            MessageInfo.SendMail(ems.Qq, "绩效考核申请", em.EmployeeName + "绩效考核申请");

            bas.Save();
            gvDataBind();
        }
Beispiel #3
0
        protected void btnSave_Click(object sender, EventArgs e)
        {
            int            basid = Convert.ToInt32(Request["BasEmScoreId"].ToString());
            BasEmScoreInfo bas   = new BasEmScoreInfo(basid);

            bas.Upbas1  = Request.Form["Upbas1"].ToString();
            bas.Upbas2  = Request.Form["Upbas2"].ToString();
            bas.Upbas3  = Request.Form["Upbas3"].ToString();
            bas.Upbas4  = Request.Form["Upbas4"].ToString();
            bas.Upbas5  = Request.Form["Upbas5"].ToString();
            bas.Upbas6  = Request.Form["Upbas6"].ToString();
            bas.Upbas7  = Request.Form["Upbas7"].ToString();
            bas.Upbas8  = Request.Form["Upbas8"].ToString();
            bas.Upbas9  = Request.Form["Upbas9"].ToString();
            bas.Upbas10 = Request.Form["Upbas10"].ToString();
            bas.Upbas11 = Request.Form["Upbas11"].ToString();
            bas.Upbas12 = Request.Form["Upbas12"].ToString();
            bas.Upbas13 = Request.Form["Upbas13"].ToString();
            bas.Upbas14 = Request.Form["Upbas14"].ToString();
            bas.Upbas15 = Request.Form["Upbas15"].ToString();
            bas.Upbas16 = Request.Form["Upbas16"].ToString();
            bas.Upbas17 = Request.Form["Upbas17"].ToString();

            bas.Secbas1  = Convert.ToString(Math.Round(float.Parse(lblSelfbas1.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas1"].ToString()), 2) * 0.6);
            bas.Secbas2  = Convert.ToString(Math.Round(float.Parse(lblSelfbas2.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas2"].ToString()), 2) * 0.6);
            bas.Secbas3  = Convert.ToString(Math.Round(float.Parse(lblSelfbas3.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas3"].ToString()), 2) * 0.6);
            bas.Secbas4  = Convert.ToString(Math.Round(float.Parse(lblSelfbas4.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas4"].ToString()), 2) * 0.6);
            bas.Secbas5  = Convert.ToString(Math.Round(float.Parse(lblSelfbas5.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas5"].ToString()), 2) * 0.6);
            bas.Secbas6  = Convert.ToString(Math.Round(float.Parse(lblSelfbas6.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas6"].ToString()), 2) * 0.6);
            bas.Secbas7  = Convert.ToString(Math.Round(float.Parse(lblSelfbas7.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas7"].ToString()), 2) * 0.6);
            bas.Secbas8  = Convert.ToString(Math.Round(float.Parse(lblSelfbas8.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas8"].ToString()), 2) * 0.6);
            bas.Secbas9  = Convert.ToString(Math.Round(float.Parse(lblSelfbas9.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas9"].ToString()), 2) * 0.6);
            bas.Secbas10 = Convert.ToString(Math.Round(float.Parse(lblSelfbas10.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas10"].ToString()), 2) * 0.6);
            bas.Secbas11 = Convert.ToString(Math.Round(float.Parse(lblSelfbas11.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas11"].ToString()), 2) * 0.6);
            bas.Secbas12 = Convert.ToString(Math.Round(float.Parse(lblSelfbas12.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas12"].ToString()), 2) * 0.6);
            bas.Secbas13 = Convert.ToString(Math.Round(float.Parse(lblSelfbas13.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas13"].ToString()), 2) * 0.6);
            bas.Secbas14 = Convert.ToString(Math.Round(float.Parse(lblSelfbas14.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas14"].ToString()), 2) * 0.6);
            bas.Secbas15 = Convert.ToString(Math.Round(float.Parse(lblSelfbas15.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas15"].ToString()), 2) * 0.6);
            bas.Secbas16 = Convert.ToString(Math.Round(float.Parse(lblSelfbas16.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas16"].ToString()), 2) * 0.6);
            bas.Secbas17 = Convert.ToString(Math.Round(float.Parse(lblSelfbas17.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upbas17"].ToString()), 2) * 0.6);

            bas.TotalScore = Request.Form["hid"].ToString();

            float Score = float.Parse(Request.Form["hid"].ToString());

            if (Score > 90)
            {
                bas.EvaluateLevelId = 2;
            }
            else if (Score > 75 && Score < 90)
            {
                bas.EvaluateLevelId = 3;
            }
            else if (Score > 60 && Score < 75)
            {
                bas.EvaluateLevelId = 4;
            }
            else if (Score < 60)
            {
                bas.EvaluateLevelId = 5;
            }
            bas.IsSubmit = 2;
            bas.UpViews  = Request.Form["UpViews"].ToString();
            bas.Save();
            Page.ClientScript.RegisterStartupScript(this.GetType(), "", "<script language='javascript'>alert('保存成功!');</script>");
        }