diff --git a/SGGL/FineUIPro.Web/HSSE/Solution/LargerHazardEdit.aspx b/SGGL/FineUIPro.Web/HSSE/Solution/LargerHazardEdit.aspx index 4b245f26..f5422a15 100644 --- a/SGGL/FineUIPro.Web/HSSE/Solution/LargerHazardEdit.aspx +++ b/SGGL/FineUIPro.Web/HSSE/Solution/LargerHazardEdit.aspx @@ -64,7 +64,7 @@ - diff --git a/SGGL/FineUIPro.Web/HSSE/Solution/LargerHazardEdit.aspx.cs b/SGGL/FineUIPro.Web/HSSE/Solution/LargerHazardEdit.aspx.cs index 8f63b3f9..3187f469 100644 --- a/SGGL/FineUIPro.Web/HSSE/Solution/LargerHazardEdit.aspx.cs +++ b/SGGL/FineUIPro.Web/HSSE/Solution/LargerHazardEdit.aspx.cs @@ -111,7 +111,7 @@ namespace FineUIPro.Web.HSSE.Solution // this.txtLargerHazardCode.Text = BLL.CodeRecordsService.ReturnCodeByMenuIdProjectId(BLL.Const.ProjectLargerHazardListMenuId, this.ProjectId, this.CurrUser.UnitId); this.txtExpectedTime.Text = string.Format("{0:yyyy-MM-dd}", DateTime.Now); this.txtRemark.Text = HttpUtility.HtmlDecode("描述"); - this.txtRecordTime.Text = string.Format("{0:yyyy-MM-dd}",DateTime.Now); + this.txtRecordTime.Text = string.Format("{0:yyyy-MM-dd}", DateTime.Now); } } } @@ -135,26 +135,29 @@ namespace FineUIPro.Web.HSSE.Solution //判断附件是否必传 if (!returnFj(this.HazardId + "_1")) { - Alert.ShowInTop("请上传附件1-论证后的方案", MessageBoxIcon.Warning); + Alert.ShowInTop("请上传附件1-专项方案", MessageBoxIcon.Warning); return; } - if (!returnFj(this.HazardId + "_2")) + if (Convert.ToBoolean(this.rblIsArgument.SelectedValue) && Convert.ToBoolean(this.rblIsSuperLargerHazard.SelectedValue)) { - Alert.ShowInTop("请上传附件2-专家论证报告", MessageBoxIcon.Warning); - return; - } + if (!returnFj(this.HazardId + "_2")) + { + Alert.ShowInTop("请上传附件2-专家论证报告", MessageBoxIcon.Warning); + return; + } - if (!returnFj(this.HazardId + "_3")) - { - Alert.ShowInTop("请上传附件3-论证会签到表", MessageBoxIcon.Warning); - return; - } + if (!returnFj(this.HazardId + "_3")) + { + Alert.ShowInTop("请上传附件3-论证会签到表", MessageBoxIcon.Warning); + return; + } - if (!returnFj(this.HazardId + "_4")) - { - Alert.ShowInTop("请上传附件4-论证会会议照片", MessageBoxIcon.Warning); - return; + if (!returnFj(this.HazardId + "_4")) + { + Alert.ShowInTop("请上传附件4-论证会会议照片", MessageBoxIcon.Warning); + return; + } } if (!returnFj(this.HazardId + "_5")) @@ -189,7 +192,7 @@ namespace FineUIPro.Web.HSSE.Solution ExpectedTime = Funs.GetNewDateTime(this.txtExpectedTime.Text.Trim()), IsArgument = Convert.ToBoolean(this.rblIsArgument.SelectedValue), IsSuperLargerHazard = Convert.ToBoolean(this.rblIsSuperLargerHazard.SelectedValue), - TrainPersonNum=Funs.GetNewIntOrZero(this.txtTrainPersonNum.Text.Trim()), + TrainPersonNum = Funs.GetNewIntOrZero(this.txtTrainPersonNum.Text.Trim()), Remark = HttpUtility.HtmlEncode(this.txtRemark.Text.Trim()), Descriptions = this.txtDescriptions.Text.Trim(), RecordTime = Funs.GetNewDateTime(this.txtRecordTime.Text.Trim()), @@ -200,7 +203,7 @@ namespace FineUIPro.Web.HSSE.Solution { largerHazard.HazardId = this.HazardId; BLL.LargerHazardService.UpdateLargerHazard(largerHazard); - BLL.LogService.AddSys_Log(this.CurrUser, largerHazard.HazardCode, largerHazard.HazardId,BLL.Const.ProjectLargerHazardListMenuId,BLL.Const.BtnModify); + BLL.LogService.AddSys_Log(this.CurrUser, largerHazard.HazardCode, largerHazard.HazardId, BLL.Const.ProjectLargerHazardListMenuId, BLL.Const.BtnModify); } else { @@ -208,7 +211,7 @@ namespace FineUIPro.Web.HSSE.Solution largerHazard.RecardMan = this.CurrUser.UserId; this.HazardId = largerHazard.HazardId; BLL.LargerHazardService.AddLargerHazard(largerHazard); - BLL.LogService.AddSys_Log(this.CurrUser, largerHazard.HazardCode, largerHazard.HazardId, BLL.Const.ProjectLargerHazardListMenuId, BLL.Const.BtnAdd); + BLL.LogService.AddSys_Log(this.CurrUser, largerHazard.HazardCode, largerHazard.HazardId, BLL.Const.ProjectLargerHazardListMenuId, BLL.Const.BtnAdd); } Project_HSSEData_HSSEService.StatisticalData(this.CurrUser.LoginProjectId, Project_HSSEData_HSSEService.HSSEDateType.ProjectInformation); Project_HSSEData_HSSEService.StatisticalData(this.CurrUser.LoginProjectId, Project_HSSEData_HSSEService.HSSEDateType.DangerousProject); @@ -230,9 +233,9 @@ namespace FineUIPro.Web.HSSE.Solution //菜单id和质量危大保持一致 PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format( "../../AttachFile/webuploader.aspx?type=0&toKeyId={0}&path=FileUpload/CQMS/MajorPlanApproval&menuId={1}", - this.HazardId+"_1", BLL.Const.MajorPlanApprovalMenuId))); + this.HazardId + "_1", BLL.Const.MajorPlanApprovalMenuId))); } - + protected void btnAttach_Click2(object sender, EventArgs e) { if (string.IsNullOrEmpty(this.HazardId)) @@ -242,7 +245,7 @@ namespace FineUIPro.Web.HSSE.Solution PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format( "../../AttachFile/webuploader.aspx?type=0&toKeyId={0}&path=FileUpload/CQMS/MajorPlanApproval&menuId={1}", - this.HazardId+"_2", BLL.Const.MajorPlanApprovalMenuId))); + this.HazardId + "_2", BLL.Const.MajorPlanApprovalMenuId))); } protected void btnAttach_Click3(object sender, EventArgs e) @@ -254,7 +257,7 @@ namespace FineUIPro.Web.HSSE.Solution PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format( "../../AttachFile/webuploader.aspx?type=0&toKeyId={0}&path=FileUpload/CQMS/MajorPlanApproval&menuId={1}", - this.HazardId+"_3", BLL.Const.MajorPlanApprovalMenuId))); + this.HazardId + "_3", BLL.Const.MajorPlanApprovalMenuId))); } protected void btnAttach_Click4(object sender, EventArgs e) @@ -266,7 +269,7 @@ namespace FineUIPro.Web.HSSE.Solution PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format( "../../AttachFile/webuploader.aspx?type=0&toKeyId={0}&path=FileUpload/CQMS/MajorPlanApproval&menuId={1}", - this.HazardId+"_4", BLL.Const.MajorPlanApprovalMenuId))); + this.HazardId + "_4", BLL.Const.MajorPlanApprovalMenuId))); } protected void btnAttach_Click5(object sender, EventArgs e) @@ -278,7 +281,7 @@ namespace FineUIPro.Web.HSSE.Solution PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format( "../../AttachFile/webuploader.aspx?type=0&toKeyId={0}&path=FileUpload/CQMS/MajorPlanApproval&menuId={1}", - this.HazardId+"_5", BLL.Const.MajorPlanApprovalMenuId))); + this.HazardId + "_5", BLL.Const.MajorPlanApprovalMenuId))); } protected void btnAttach_Click6(object sender, EventArgs e) @@ -290,13 +293,14 @@ namespace FineUIPro.Web.HSSE.Solution PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format( "../../AttachFile/webuploader.aspx?type=0&toKeyId={0}&path=FileUpload/CQMS/MajorPlanApproval&menuId={1}", - this.HazardId+"_6", BLL.Const.MajorPlanApprovalMenuId))); + this.HazardId + "_6", BLL.Const.MajorPlanApprovalMenuId))); } - - private bool returnFj(string id) { + + private bool returnFj(string id) + { bool isT = true; var model = Funs.DB.AttachFile.FirstOrDefault(x => x.ToKeyId == id); - if (model==null) + if (model == null) { return false; } @@ -323,7 +327,7 @@ namespace FineUIPro.Web.HSSE.Solution }; this.HazardId = largerHazard.HazardId; BLL.LargerHazardService.AddLargerHazard(largerHazard); - BLL.LogService.AddSys_Log(this.CurrUser, largerHazard.HazardCode, largerHazard.HazardId,BLL.Const.ProjectLargerHazardListMenuId,BLL.Const.BtnAdd); + BLL.LogService.AddSys_Log(this.CurrUser, largerHazard.HazardCode, largerHazard.HazardId, BLL.Const.ProjectLargerHazardListMenuId, BLL.Const.BtnAdd); } } } \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/HSSE/Solution/LargerHazardList.aspx b/SGGL/FineUIPro.Web/HSSE/Solution/LargerHazardList.aspx index ceaff8cd..6bd9d33f 100644 --- a/SGGL/FineUIPro.Web/HSSE/Solution/LargerHazardList.aspx +++ b/SGGL/FineUIPro.Web/HSSE/Solution/LargerHazardList.aspx @@ -125,7 +125,7 @@