This commit is contained in:
2026-08-26 18:18:13 +08:00
parent 3b2bb94e9e
commit 75df99e219
3 changed files with 42 additions and 5 deletions
@@ -192,7 +192,8 @@ namespace FineUIPro.Web.HSSE.SitePerson
Model.SitePerson_Person newPerson = new Model.SitePerson_Person
{
ProjectId = this.ProjectId,
PersonId = SQLHelper.GetNewID(typeof(Model.SitePerson_Person)),
//PersonId = SQLHelper.GetNewID(typeof(Model.SitePerson_Person)),
PersonId = user.UserId,
UnitId = user.UnitId,
IdentityCard = user.IdentityCard,
IdcardType = "SHENFEN_ZHENGJIAN",
@@ -68,8 +68,11 @@ namespace FineUIPro.Web.HSSE.SitePerson
//权限按钮方法
this.GetButtonPower();
}
////权限按钮方法
//this.GetButtonPower();
if (CommonService.IsSuperAdminManage(this.CurrUser.UserId))
{
//权限按钮方法
this.GetButtonPower();
}
this.btnMenuDelete.OnClientClick = Grid1.GetNoSelectionAlertReference("请至少选择一项!");
this.btnMenuDelete.ConfirmText = String.Format("你确定要删除选中的&nbsp;<b><script>{0}</script></b>&nbsp;行数据吗?", Grid1.GetSelectedCountReference());
this.ddlPageSize.SelectedValue = this.Grid1.PageSize.ToString();
@@ -89,7 +92,7 @@ namespace FineUIPro.Web.HSSE.SitePerson
this.InitTreeMenu();
this.BindGrid();
this.GetButtonPower();
if (string.IsNullOrEmpty(this.CurrUser.LoginProjectId))
if (string.IsNullOrEmpty(this.CurrUser.LoginProjectId) && !CommonService.IsSuperAdminManage(this.CurrUser.UserId))
{
btnNew.Hidden = true;
btnImport.Hidden = true;
@@ -599,6 +602,19 @@ namespace FineUIPro.Web.HSSE.SitePerson
protected void btnSearchUserAdd_Click(object sender, EventArgs e)
{
string projectId = this.CurrUser.LoginProjectId;
if (this.tvProjectAndUnit.SelectedNodeID.Contains("|"))
{
string id = this.tvProjectAndUnit.SelectedNodeID;
string[] str = id.Split('|');
if (str.Count() > 1)
{
string unitId = id.Split('|')[0];
projectId = id.Split('|')[1];
//PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("PersonListEdit.aspx?ProjectId={0}&&UnitId={1}", projectId, unitId, "编辑 - ")));
}
}
PageContext.RegisterStartupScript(Window4.GetShowReference(String.Format("PersonAddFromUser.aspx?ProjectId={0}", projectId, "编辑 - ")));
//if (this.tvProjectAndUnit.SelectedNodeID.Contains("|"))
@@ -790,7 +806,7 @@ namespace FineUIPro.Web.HSSE.SitePerson
this.btnPersonUnit.Hidden = false;
}
}
if (this.CurrUser.UserId == Const.luofeiId || this.CurrUser.UserId == Const.shizhiyangId || this.CurrUser.UserId == Const.hfnbdId || this.CurrUser.UserId == Const.sysglyId)
if (CommonService.IsSuperAdminManage(this.CurrUser.UserId))
{//罗菲、史志扬、管理员账号
this.btnSearchUserAdd.Hidden = false;
}