| 
									
										
										
										
											2021-04-30 10:28:37 +08:00
										 |  |  |  | using BLL; | 
					
						
							|  |  |  |  | using System; | 
					
						
							|  |  |  |  | using System.Collections.Generic; | 
					
						
							|  |  |  |  | using System.Data; | 
					
						
							|  |  |  |  | using System.Data.SqlClient; | 
					
						
							|  |  |  |  | using System.Linq; | 
					
						
							|  |  |  |  | using System.Web; | 
					
						
							|  |  |  |  | using System.Web.UI; | 
					
						
							|  |  |  |  | using System.Web.UI.WebControls; | 
					
						
							|  |  |  |  | 
 | 
					
						
							|  |  |  |  | namespace FineUIPro.Web.PZHGL.GJSX | 
					
						
							|  |  |  |  | { | 
					
						
							|  |  |  |  |     public partial class GJSXInfoCount : PageBase | 
					
						
							|  |  |  |  |     { | 
					
						
							|  |  |  |  |         protected void Page_Load(object sender, EventArgs e) | 
					
						
							|  |  |  |  |         { | 
					
						
							|  |  |  |  |             if (!IsPostBack) | 
					
						
							|  |  |  |  |             { | 
					
						
							|  |  |  |  |                 ///单位 | 
					
						
							|  |  |  |  |                 UnitService.InitUnitDropDownList(this.DropUnitId, this.CurrUser.LoginProjectId, true); | 
					
						
							|  |  |  |  |                 //专业 | 
					
						
							|  |  |  |  |                 CNProfessionalService.InitCNProfessional(this.DropCNProfessional_ID, true); | 
					
						
							|  |  |  |  |                 //编号 | 
					
						
							|  |  |  |  |                 string projectCode = BLL.ProjectService.GetProjectCodeByProjectId(this.CurrUser.LoginProjectId); | 
					
						
							| 
									
										
										
										
											2025-03-13 10:52:32 +08:00
										 |  |  |  |                 //紧急程度 | 
					
						
							| 
									
										
										
										
											2021-04-30 10:28:37 +08:00
										 |  |  |  |                 QuestionTypeService.InitQuestionTypeDropDownList(this.DropQuestionTypeID, true); | 
					
						
							| 
									
										
										
										
											2025-03-13 10:52:32 +08:00
										 |  |  |  |                 //事项类别 | 
					
						
							|  |  |  |  |                 GJSXTypeService.InitGJSXTypeDropDownList(this.DropGJSXTypeID, false); | 
					
						
							| 
									
										
										
										
											2021-04-30 10:28:37 +08:00
										 |  |  |  |                 //验收人 | 
					
						
							|  |  |  |  |                 UserService.InitUserDropDownList(DropUser_ReceiveID, CurrUser.LoginProjectId, false, string.Empty); | 
					
						
							|  |  |  |  |                 //接收人 | 
					
						
							|  |  |  |  |                 UserService.InitUserDropDownList(DropUser_Acceptance, CurrUser.LoginProjectId, false, string.Empty); | 
					
						
							|  |  |  |  |                 UserService.InitUserDropDownList(DropCreatuser, CurrUser.LoginProjectId, false, string.Empty); | 
					
						
							|  |  |  |  | 
 | 
					
						
							|  |  |  |  |                 BindGrid(); | 
					
						
							|  |  |  |  |             } | 
					
						
							| 
									
										
										
										
											2025-03-13 10:52:32 +08:00
										 |  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-04-30 10:28:37 +08:00
										 |  |  |  |         } | 
					
						
							|  |  |  |  | 
 | 
					
						
							|  |  |  |  |         protected void TextBox_TextChanged(object sender, EventArgs e) | 
					
						
							|  |  |  |  |         { | 
					
						
							|  |  |  |  |             this.BindGrid(); | 
					
						
							|  |  |  |  |         } | 
					
						
							|  |  |  |  |         private void BindGrid() | 
					
						
							|  |  |  |  |         { | 
					
						
							|  |  |  |  | 
 | 
					
						
							|  |  |  |  |             // @UserID nvarchar(50)= null, --提出人 | 
					
						
							|  |  |  |  |             //@unit nvarchar(50)= null, --责任单位 | 
					
						
							|  |  |  |  |             //@projectId nvarchar(50) = null, --所属项目 | 
					
						
							|  |  |  |  |             //@CNProfessional_ID nvarchar(500) = null, --专业 | 
					
						
							| 
									
										
										
										
											2025-03-13 10:52:32 +08:00
										 |  |  |  |             //@questionType nvarchar(500)= null, --紧急程度 | 
					
						
							| 
									
										
										
										
											2021-04-30 10:28:37 +08:00
										 |  |  |  |             //@processMan nvarchar(50)  = null, --接收人 | 
					
						
							|  |  |  |  |             //@User_Acceptance nvarchar(50) = null--验收人 | 
					
						
							|  |  |  |  | 
 | 
					
						
							|  |  |  |  |             string userid = DropCreatuser.SelectedValue; | 
					
						
							|  |  |  |  |             string unit = DropUnitId.SelectedValue; | 
					
						
							|  |  |  |  |             string projectid = CurrUser.LoginProjectId; | 
					
						
							|  |  |  |  |             string CNProfessional_ID = DropCNProfessional_ID.SelectedValue; | 
					
						
							|  |  |  |  |             string questionType = DropQuestionTypeID.SelectedValue; | 
					
						
							| 
									
										
										
										
											2025-03-13 10:52:32 +08:00
										 |  |  |  |             string GJSXType = DropGJSXTypeID.SelectedValue; | 
					
						
							| 
									
										
										
										
											2021-04-30 10:28:37 +08:00
										 |  |  |  |             string processMan = DropUser_ReceiveID.SelectedValue; | 
					
						
							|  |  |  |  |             string User_Acceptance = DropUser_Acceptance.SelectedValue; | 
					
						
							|  |  |  |  |             //if (userid is null) | 
					
						
							|  |  |  |  |             //{ | 
					
						
							|  |  |  |  |             //    userid = ""; | 
					
						
							|  |  |  |  |             //} | 
					
						
							|  |  |  |  |             if (unit == "null") | 
					
						
							|  |  |  |  |             { | 
					
						
							|  |  |  |  |                 unit = null; | 
					
						
							|  |  |  |  |             } | 
					
						
							|  |  |  |  |             //if (projectid is null) | 
					
						
							|  |  |  |  |             //{ | 
					
						
							|  |  |  |  |             //    projectid = ""; | 
					
						
							|  |  |  |  |             //} | 
					
						
							|  |  |  |  |             if (CNProfessional_ID == "null") | 
					
						
							|  |  |  |  |             { | 
					
						
							|  |  |  |  |                 CNProfessional_ID = null; | 
					
						
							|  |  |  |  |             } | 
					
						
							|  |  |  |  |             if (questionType == "null") | 
					
						
							|  |  |  |  |             { | 
					
						
							|  |  |  |  |                 questionType = null; | 
					
						
							|  |  |  |  |             } | 
					
						
							| 
									
										
										
										
											2025-03-13 10:52:32 +08:00
										 |  |  |  |             if (GJSXType == "null") | 
					
						
							|  |  |  |  |             { | 
					
						
							|  |  |  |  |                 GJSXType = null; | 
					
						
							|  |  |  |  |             } | 
					
						
							| 
									
										
										
										
											2021-04-30 10:28:37 +08:00
										 |  |  |  |             //if (processMan is null) | 
					
						
							|  |  |  |  |             //{ | 
					
						
							|  |  |  |  |             //    processMan = ""; | 
					
						
							|  |  |  |  |             //} | 
					
						
							|  |  |  |  |             //if (User_Acceptance is null) | 
					
						
							|  |  |  |  |             //{ | 
					
						
							|  |  |  |  |             //    userid = ""; | 
					
						
							|  |  |  |  |             //} | 
					
						
							|  |  |  |  | 
 | 
					
						
							|  |  |  |  | 
 | 
					
						
							|  |  |  |  |             Model.GJSX gjsx = BLL.GJSXService.GetGJSXById(ID); | 
					
						
							|  |  |  |  |             List<SqlParameter> listStr = new List<SqlParameter>(); | 
					
						
							|  |  |  |  | 
 | 
					
						
							|  |  |  |  |             listStr.Add(new SqlParameter("@UserID", userid)); | 
					
						
							|  |  |  |  |             listStr.Add(new SqlParameter("@unit", unit)); | 
					
						
							|  |  |  |  |             listStr.Add(new SqlParameter("@projectid", projectid)); | 
					
						
							|  |  |  |  |             listStr.Add(new SqlParameter("@CNProfessional_ID", CNProfessional_ID)); | 
					
						
							|  |  |  |  |             listStr.Add(new SqlParameter("@questionType", questionType)); | 
					
						
							| 
									
										
										
										
											2025-03-13 10:52:32 +08:00
										 |  |  |  |             listStr.Add(new SqlParameter("@GJSXType", GJSXType)); | 
					
						
							| 
									
										
										
										
											2021-04-30 10:28:37 +08:00
										 |  |  |  |             listStr.Add(new SqlParameter("@processMan", processMan)); | 
					
						
							|  |  |  |  |             listStr.Add(new SqlParameter("@User_Acceptance", User_Acceptance)); | 
					
						
							|  |  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2025-03-13 10:52:32 +08:00
										 |  |  |  | 
 | 
					
						
							|  |  |  |  |             SqlParameter[] parameter = listStr.ToArray(); | 
					
						
							| 
									
										
										
										
											2021-04-30 10:28:37 +08:00
										 |  |  |  |             DataTable tb = SQLHelper.GetDataTableRunProc("Sp_GJSXStatistic", parameter); | 
					
						
							|  |  |  |  | 
 | 
					
						
							|  |  |  |  | 
 | 
					
						
							|  |  |  |  |             Grid1.RecordCount = tb.Rows.Count; | 
					
						
							|  |  |  |  |             var table = this.GetPagedDataTable(Grid1, tb); | 
					
						
							|  |  |  |  |             this.Grid1.DataSource = table; | 
					
						
							|  |  |  |  |             this.Grid1.DataBind(); | 
					
						
							| 
									
										
										
										
											2025-03-13 10:52:32 +08:00
										 |  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-04-30 10:28:37 +08:00
										 |  |  |  |         } | 
					
						
							|  |  |  |  | 
 | 
					
						
							|  |  |  |  |         /// <summary> | 
					
						
							|  |  |  |  |         /// 分页显示条数下拉框 | 
					
						
							|  |  |  |  |         /// </summary> | 
					
						
							|  |  |  |  |         /// <param name="sender"></param> | 
					
						
							|  |  |  |  |         /// <param name="e"></param> | 
					
						
							|  |  |  |  |         protected void ddlPageSize_SelectedIndexChanged(object sender, EventArgs e) | 
					
						
							|  |  |  |  |         { | 
					
						
							|  |  |  |  |             Grid1.PageSize = Convert.ToInt32(ddlPageSize.SelectedValue); | 
					
						
							|  |  |  |  |             BindGrid(); | 
					
						
							|  |  |  |  |         } | 
					
						
							|  |  |  |  |         /// <summary> | 
					
						
							|  |  |  |  |         /// 排序 | 
					
						
							|  |  |  |  |         /// </summary> | 
					
						
							|  |  |  |  |         /// <param name="sender"></param> | 
					
						
							|  |  |  |  |         /// <param name="e"></param> | 
					
						
							|  |  |  |  |         protected void Grid1_Sort(object sender, FineUIPro.GridSortEventArgs e) | 
					
						
							|  |  |  |  |         { | 
					
						
							|  |  |  |  |             BindGrid(); | 
					
						
							|  |  |  |  |         } | 
					
						
							|  |  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2025-03-13 10:52:32 +08:00
										 |  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2021-04-30 10:28:37 +08:00
										 |  |  |  |         /// <param name="e"></param> | 
					
						
							|  |  |  |  |         protected void Grid1_PageIndexChange(object sender, GridPageEventArgs e) | 
					
						
							|  |  |  |  |         { | 
					
						
							|  |  |  |  |             BindGrid(); | 
					
						
							|  |  |  |  |         } | 
					
						
							|  |  |  |  | 
 | 
					
						
							|  |  |  |  |         /// <summary> | 
					
						
							|  |  |  |  |         /// Grid行双击事件 | 
					
						
							|  |  |  |  |         /// </summary> | 
					
						
							|  |  |  |  |         /// <param name="sender"></param> | 
					
						
							|  |  |  |  |         /// <param name="e"></param> | 
					
						
							|  |  |  |  |         protected void Grid1_RowDoubleClick(object sender, GridRowClickEventArgs e) | 
					
						
							|  |  |  |  |         { | 
					
						
							| 
									
										
										
										
											2025-03-13 10:52:32 +08:00
										 |  |  |  |             // this.EditData(); | 
					
						
							| 
									
										
										
										
											2021-04-30 10:28:37 +08:00
										 |  |  |  |         } | 
					
						
							|  |  |  |  |     } | 
					
						
							|  |  |  |  | } |