nianzongjie.aspx.cs
资源名称:OASystem.rar [点击查看]
上传用户:lishan0805
上传日期:2019-12-08
资源大小:12048k
文件大小:2k
源码类别:
OA系统
开发平台:
C#
- using System;
- using System.Data;
- using System.Configuration;
- using System.Collections;
- using System.Web;
- using System.Web.Security;
- using System.Web.UI;
- using System.Web.UI.WebControls;
- using System.Web.UI.WebControls.WebParts;
- using System.Web.UI.HtmlControls;
- using COM.OA.Entity;
- using COM.OA.BLL;
- public partial class wx_zongjie_nianzongjie : System.Web.UI.Page
- {
- protected void Page_Load(object sender, EventArgs e)
- {
- }
- protected void Submit1_ServerClick(object sender, EventArgs e)
- {
- //取要插入的数据值
- string changgui = this.Request.Form["Freenianzong"].Trim();
- string jobjihua = this.Request.Form["txt_jobjihua"].Trim();
- string chuangxin = this.Request.Form["txt_chuangxin"].Trim();
- string year = this.Request.Form["yearvalue"].Trim();
- string month = this.Request.Form["monthvalue"].Trim();
- if (changgui == null || changgui=="")
- {
- this.Response.Write(string.Format(GetRedirect.WINALERT, "常规不能为空"));
- return;
- }
- else if (jobjihua == null || jobjihua == "")
- {
- this.Response.Write(string.Format(GetRedirect.WINALERT, "工作计划不能为空"));
- return;
- }
- else if (chuangxin == null || chuangxin == "")
- {
- this.Response.Write(string.Format(GetRedirect.WINALERT, "创新不能为空"));
- return;
- }
- else
- {
- users loginuser = Session["loginuser"] as users;
- //实力化实体,存值
- worksumup ws = new worksumup();
- ws.ws_st_id = 1;
- ws.ws_year = year;
- ws.ws_month = month;
- ws.ws_time = DateTime.Now;
- ws.ws_generalwork = changgui;
- ws.ws_nextplan = jobjihua;
- ws.ws_advice = chuangxin;
- ws.ws_u_id = loginuser.u_id;
- //插入
- worksumupBLL.Insert(ws);
- this.Response.Write(string.Format(GetRedirect.WINALERT, "插入成功"));
- this.Response.Write(string.Format(GetRedirect.REDIRECT, "nianzongjie.aspx"));
- }
- }
- }