From 9140eab873cabbae8de9ce352db7fe893950d29a Mon Sep 17 00:00:00 2001
From: xiaju <1784803958@qq.com>
Date: Thu, 4 Jun 2026 16:45:46 +0800
Subject: [PATCH] =?UTF-8?q?=E5=AE=89=E5=85=A8=E4=B8=8D=E7=AC=A6=E5=90=88?=
=?UTF-8?q?=E9=A1=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
DataBase/版本日志/SGGLDB_V2026-06-05-xiaj.sql | 20 +++++++++++
.../FineUIPro.Web/Check/HSE/CheckProblem.aspx | 10 +++---
.../Check/HSE/CheckProblem.aspx.cs | 35 +++++++++++++++----
3 files changed, 54 insertions(+), 11 deletions(-)
create mode 100644 DataBase/版本日志/SGGLDB_V2026-06-05-xiaj.sql
diff --git a/DataBase/版本日志/SGGLDB_V2026-06-05-xiaj.sql b/DataBase/版本日志/SGGLDB_V2026-06-05-xiaj.sql
new file mode 100644
index 00000000..be8f2f22
--- /dev/null
+++ b/DataBase/版本日志/SGGLDB_V2026-06-05-xiaj.sql
@@ -0,0 +1,20 @@
+
+
+
+
+
+--ĿHSE嵥
+IF NOT EXISTS (SELECT * FROM Sys_Menu WHERE MenuId = '664ACF2F-6750-4389-AF11-F429010FC987')
+BEGIN
+INSERT INTO dbo.Sys_Menu (MenuId, MenuName,Url, SortIndex, SuperMenu, MenuType, IsOffice, IsEnd, IsUsed)
+VALUES (N'664ACF2F-6750-4389-AF11-F429010FC987', N'HSE嵥', N'Check/HSE/CheckProblem.aspx', 10, N'467A0CB9-737D-4451-965E-869EBC3A4BD6', N'Menu_HSSE', 0,1, 1);
+END
+GO
+
+update Sys_Menu
+set IsUsed=0
+where MenuId='2FC8AA2A-F421-4174-A05E-2711167AF141'
+GO
+
+
+
diff --git a/SGGL/FineUIPro.Web/Check/HSE/CheckProblem.aspx b/SGGL/FineUIPro.Web/Check/HSE/CheckProblem.aspx
index dce528ba..0c980b31 100644
--- a/SGGL/FineUIPro.Web/Check/HSE/CheckProblem.aspx
+++ b/SGGL/FineUIPro.Web/Check/HSE/CheckProblem.aspx
@@ -87,11 +87,11 @@
-
+
-
+
-
+
@@ -109,9 +109,9 @@
-
+
-
+
diff --git a/SGGL/FineUIPro.Web/Check/HSE/CheckProblem.aspx.cs b/SGGL/FineUIPro.Web/Check/HSE/CheckProblem.aspx.cs
index 73f6b2f9..3bd514d6 100644
--- a/SGGL/FineUIPro.Web/Check/HSE/CheckProblem.aspx.cs
+++ b/SGGL/FineUIPro.Web/Check/HSE/CheckProblem.aspx.cs
@@ -42,6 +42,12 @@ namespace FineUIPro.Web.Check.HSE
}
//权限按钮方法
GetButtonPower();
+ if (!string.IsNullOrWhiteSpace(this.ProjectId) || (this.CurrUser.UnitId != null && this.CurrUser.UnitId != Const.UnitId_XJYJ))
+ {
+ this.btnNew.Hidden = true;
+ this.btnImport.Hidden = true;
+ }
+
InitDropDownList();
//Funs.FineUIPleaseSelect(this.dpState);
@@ -136,8 +142,16 @@ namespace FineUIPro.Web.Check.HSE
sb.Append("WHERE 1=1 ");
List listStr = new List();
- //listStr.Add(new SqlParameter("@ProjectId", this.CurrUser.LoginProjectId));
-
+ if (this.CurrUser.UnitId != null && this.CurrUser.UnitId != Const.UnitId_XJYJ && (this.CurrUser.UserId != Const.hfnbdId || this.CurrUser.UserId != Const.sysglyId))
+ {
+ sb.Append("AND tba.UnitId=@UnitId ");
+ listStr.Add(new SqlParameter("@UnitId", this.CurrUser.UnitId));
+ }
+ if (!string.IsNullOrWhiteSpace(this.ProjectId))
+ {
+ sb.Append("AND tba.ProjectId=@ProjectId ");
+ listStr.Add(new SqlParameter("@ProjectId", this.ProjectId));
+ }
if (!string.IsNullOrWhiteSpace(this.txtSearch.Text.Trim()))
{
sb.Append("AND (tba.UnitName LIKE @SearchTxt OR tba.ProjectName LIKE @SearchTxt OR tba.Description LIKE @SearchTxt OR tba.CheckTeamUser LIKE @SearchTxt) ");
@@ -331,12 +345,21 @@ namespace FineUIPro.Web.Check.HSE
var model = CheckProblemSafetyService.GetCheckProblemById(checkId);
if (model != null)
{
- if (model.State == (int)CheckProblemSafetyService.StateInt.已闭环) //双击事件 已闭环
+ if (!string.IsNullOrWhiteSpace(this.ProjectId) || (this.CurrUser.UnitId != null && this.CurrUser.UnitId != Const.UnitId_XJYJ))
{
- Alert.ShowInTop("当前隐患已闭环,无法编辑,请右键查看!", MessageBoxIcon.Warning);
- return;
+ PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("CheckProblemView.aspx?CheckId={0}", checkId), "查看安全不符合项"));
+ }
+ else
+ {
+ if (model.State == (int)CheckProblemSafetyService.StateInt.已闭环) //双击事件 已闭环
+ {
+ Alert.ShowInTop("当前隐患已闭环,无法编辑,请右键查看!", MessageBoxIcon.Warning);
+ }
+ else
+ {
+ PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("CheckProblemEdit.aspx?CheckId={0}", checkId), "编辑安全不符合项"));
+ }
}
- PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("CheckProblemEdit.aspx?CheckId={0}", checkId), "编辑安全不符合项"));
return;
}
}