protected void btnSubmit_Click(object sender, EventArgs e) { int NsScoreId = Convert.ToInt32(((Button)sender).CommandArgument.ToString()); NurseScoreInfo ns = new NurseScoreInfo(NsScoreId); ns.IsSubmit = 1; int recvid = Convert.ToInt32(Common.getEmployeeIdOfAdmin()); EmployeeInfo em = new EmployeeInfo(Convert.ToInt32(ns.EmployeeId)); EmployeeInfo ems = new EmployeeInfo(recvid); MessageInfo.Msgs1(recvid, ns.NurseScoreId, "~/Score/NurseScoreApprove.aspx", em.EmployeeName + "绩效考核申请", em.EmployeeName, "daiban", em.EmployeeName + "绩效考核申请"); MessageInfo.SendMail(ems.Qq, "绩效考核申请", em.EmployeeName + "绩效考核申请"); ns.Save(); gvDataBind(); }
protected void btnSave_Click(object sender, EventArgs e) { if (IsPageValid()) { int emid = Convert.ToInt32(Session["EmployeeId"]); NurseScoreInfo ns = new NurseScoreInfo(); ns.EmployeeId = emid; ns.YearId = Convert.ToInt32(ddlYear.SelectedValue); ns.MonthId = Convert.ToInt32(ddlMonth.SelectedValue); ns.DateSpan = ddlYear.SelectedItem.Text + "年" + ddlMonth.SelectedItem.Text + "月"; ns.EvaluateLevelId = 6; ns.TotalScore = "待评"; ns.IsSubmit = 0; ns.Selfns1 = Request.Form["Selfns1"].ToString(); ns.Selfns2 = Request.Form["Selfns2"].ToString(); ns.Selfns3 = Request.Form["Selfns3"].ToString(); ns.Selfns4 = Request.Form["Selfns4"].ToString(); ns.Selfns5 = Request.Form["Selfns5"].ToString(); ns.Selfns6 = Request.Form["Selfns6"].ToString(); ns.Selfns7 = Request.Form["Selfns7"].ToString(); ns.Selfns8 = Request.Form["Selfns8"].ToString(); ns.Selfns9 = Request.Form["Selfns9"].ToString(); ns.Selfns10 = Request.Form["Selfns10"].ToString(); ns.Selfns11 = Request.Form["Selfns11"].ToString(); ns.Selfns12 = Request.Form["Selfns12"].ToString(); ns.Selfns13 = Request.Form["Selfns13"].ToString(); ns.Selfns14 = Request.Form["Selfns14"].ToString(); ns.Selfns15 = Request.Form["Selfns15"].ToString(); ns.Selfns16 = Request.Form["Selfns16"].ToString(); ns.Selfns17 = Request.Form["Selfns17"].ToString(); ns.Selfns18 = Request.Form["Selfns18"].ToString(); ns.Selfns19 = Request.Form["Selfns19"].ToString(); ns.Selfns20 = Request.Form["Selfns20"].ToString(); ns.Selfns21 = Request.Form["Selfns21"].ToString(); ns.Selfns22 = Request.Form["Selfns22"].ToString(); ns.Selfns23 = Request.Form["Selfns23"].ToString(); ns.Save(); Page.ClientScript.RegisterStartupScript(this.GetType(), "", "<script language='javascript'>alert('保存成功!');</script>"); } }
protected void btnSave_Click(object sender, EventArgs e) { int nsid = Convert.ToInt32(Request["NurseScoreId"].ToString()); NurseScoreInfo ns = new NurseScoreInfo(nsid); ns.Upns1 = Request.Form["Upns1"].ToString(); ns.Upns2 = Request.Form["Upns2"].ToString(); ns.Upns3 = Request.Form["Upns3"].ToString(); ns.Upns4 = Request.Form["Upns4"].ToString(); ns.Upns5 = Request.Form["Upns5"].ToString(); ns.Upns6 = Request.Form["Upns6"].ToString(); ns.Upns7 = Request.Form["Upns7"].ToString(); ns.Upns8 = Request.Form["Upns8"].ToString(); ns.Upns9 = Request.Form["Upns9"].ToString(); ns.Upns10 = Request.Form["Upns10"].ToString(); ns.Upns11 = Request.Form["Upns11"].ToString(); ns.Upns12 = Request.Form["Upns12"].ToString(); ns.Upns13 = Request.Form["Upns13"].ToString(); ns.Upns14 = Request.Form["Upns14"].ToString(); ns.Upns15 = Request.Form["Upns15"].ToString(); ns.Upns16 = Request.Form["Upns16"].ToString(); ns.Upns17 = Request.Form["Upns17"].ToString(); ns.Upns18 = Request.Form["Upns18"].ToString(); ns.Upns19 = Request.Form["Upns19"].ToString(); ns.Upns20 = Request.Form["Upns20"].ToString(); ns.Upns21 = Request.Form["Upns21"].ToString(); ns.Upns22 = Request.Form["Upns22"].ToString(); ns.Upns23 = Request.Form["Upns23"].ToString(); ns.Secns1 = Convert.ToString(Math.Round(float.Parse(lblSelfns1.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns1"].ToString()), 2) * 0.6); ns.Secns2 = Convert.ToString(Math.Round(float.Parse(lblSelfns2.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns2"].ToString()), 2) * 0.6); ns.Secns3 = Convert.ToString(Math.Round(float.Parse(lblSelfns3.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns3"].ToString()), 2) * 0.6); ns.Secns4 = Convert.ToString(Math.Round(float.Parse(lblSelfns4.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns4"].ToString()), 2) * 0.6); ns.Secns5 = Convert.ToString(Math.Round(float.Parse(lblSelfns5.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns5"].ToString()), 2) * 0.6); ns.Secns6 = Convert.ToString(Math.Round(float.Parse(lblSelfns6.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns6"].ToString()), 2) * 0.6); ns.Secns7 = Convert.ToString(Math.Round(float.Parse(lblSelfns7.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns7"].ToString()), 2) * 0.6); ns.Secns8 = Convert.ToString(Math.Round(float.Parse(lblSelfns8.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns8"].ToString()), 2) * 0.6); ns.Secns9 = Convert.ToString(Math.Round(float.Parse(lblSelfns9.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns9"].ToString()), 2) * 0.6); ns.Secns10 = Convert.ToString(Math.Round(float.Parse(lblSelfns10.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns10"].ToString()), 2) * 0.6); ns.Secns11 = Convert.ToString(Math.Round(float.Parse(lblSelfns11.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns11"].ToString()), 2) * 0.6); ns.Secns12 = Convert.ToString(Math.Round(float.Parse(lblSelfns12.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns12"].ToString()), 2) * 0.6); ns.Secns13 = Convert.ToString(Math.Round(float.Parse(lblSelfns13.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns13"].ToString()), 2) * 0.6); ns.Secns14 = Convert.ToString(Math.Round(float.Parse(lblSelfns14.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns14"].ToString()), 2) * 0.6); ns.Secns15 = Convert.ToString(Math.Round(float.Parse(lblSelfns15.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns15"].ToString()), 2) * 0.6); ns.Secns16 = Convert.ToString(Math.Round(float.Parse(lblSelfns16.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns16"].ToString()), 2) * 0.6); ns.Secns17 = Convert.ToString(Math.Round(float.Parse(lblSelfns17.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns17"].ToString()), 2) * 0.6); ns.Secns18 = Convert.ToString(Math.Round(float.Parse(lblSelfns18.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns18"].ToString()), 2) * 0.6); ns.Secns19 = Convert.ToString(Math.Round(float.Parse(lblSelfns19.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns19"].ToString()), 2) * 0.6); ns.Secns20 = Convert.ToString(Math.Round(float.Parse(lblSelfns20.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns20"].ToString()), 2) * 0.6); ns.Secns21 = Convert.ToString(Math.Round(float.Parse(lblSelfns21.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns21"].ToString()), 2) * 0.6); ns.Secns22 = Convert.ToString(Math.Round(float.Parse(lblSelfns22.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns22"].ToString()), 2) * 0.6); ns.Secns23 = Convert.ToString(Math.Round(float.Parse(lblSelfns23.Text.ToString()), 2) * 0.4 + Math.Round(float.Parse(Request.Form["Upns23"].ToString()), 2) * 0.6); float Score = float.Parse(Request.Form["hid"].ToString()); if (Score > 90) { ns.EvaluateLevelId = 2; } else if (Score > 75 && Score < 90) { ns.EvaluateLevelId = 3; } else if (Score > 60 && Score < 75) { ns.EvaluateLevelId = 4; } else if (Score < 60) { ns.EvaluateLevelId = 5; } ns.TotalScore = Request.Form["hid"].ToString(); ns.IsSubmit = 2; ns.UpViews = Request.Form["UpViews"].ToString(); ns.Save(); Page.ClientScript.RegisterStartupScript(this.GetType(), "", "<script language='javascript'>alert('保存成功!');</script>"); }
public object SaveNurseScoreInfo(NurseScoreInfo nurseScoreInfo) { nurseScoreInfo.Save(); return(nurseScoreInfo.NurseScoreId); }