安全检查补充公司级树
This commit is contained in:
@@ -32,15 +32,21 @@ namespace FineUIPro.Web.Customization.CNCCG.ZHGL.Problem
|
||||
{
|
||||
if (!IsPostBack)
|
||||
{
|
||||
Funs.DropDownPageSize(this.ddlPageSize);
|
||||
this.ProjectId = this.CurrUser.LoginProjectId;
|
||||
if (!string.IsNullOrEmpty(Request.Params["projectId"]) && Request.Params["projectId"] != this.CurrUser.LoginProjectId)
|
||||
{
|
||||
this.ProjectId = Request.Params["projectId"];
|
||||
}
|
||||
|
||||
////权限按钮方法
|
||||
GetButtonPower();
|
||||
Funs.DropDownPageSize(this.ddlPageSize);
|
||||
this.ucTree.UnitId = this.CurrUser.UnitId;
|
||||
this.ucTree.ProjectId = this.ProjectId;
|
||||
if (!string.IsNullOrEmpty(this.ProjectId))
|
||||
{
|
||||
this.panelLeftRegion.Hidden = true;
|
||||
////权限按钮方法
|
||||
this.GetButtonPower();
|
||||
}
|
||||
if (this.CurrUser != null && this.CurrUser.PageSize.HasValue)
|
||||
{
|
||||
Grid1.PageSize = this.CurrUser.PageSize.Value;
|
||||
@@ -51,6 +57,24 @@ namespace FineUIPro.Web.Customization.CNCCG.ZHGL.Problem
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 公司级树加载
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
|
||||
//if (string.IsNullOrEmpty(this.CurrUser.LoginProjectId))
|
||||
//{
|
||||
// btnNew.Hidden = true;
|
||||
//}
|
||||
this.GetButtonPower();
|
||||
this.BindGrid();
|
||||
}
|
||||
|
||||
|
||||
#region 获取按钮权限
|
||||
/// <summary>
|
||||
/// 获取按钮权限
|
||||
@@ -63,7 +87,7 @@ namespace FineUIPro.Web.Customization.CNCCG.ZHGL.Problem
|
||||
{
|
||||
return;
|
||||
}
|
||||
var buttonList = BLL.CommonService.GetAllButtonList(this.CurrUser.LoginProjectId, this.CurrUser.UserId, BLL.Const.ProblemReplyManagerMenuId);
|
||||
var buttonList = BLL.CommonService.GetAllButtonList(this.ProjectId, this.CurrUser.UserId, BLL.Const.ProblemReplyManagerMenuId);
|
||||
if (buttonList.Count() > 0)
|
||||
{
|
||||
if (buttonList.Contains(BLL.Const.BtnAdd))
|
||||
@@ -122,21 +146,26 @@ namespace FineUIPro.Web.Customization.CNCCG.ZHGL.Problem
|
||||
#region 加载数据
|
||||
protected void BindGrid()
|
||||
{
|
||||
if (string.IsNullOrEmpty(this.ProjectId))
|
||||
{
|
||||
return;
|
||||
}
|
||||
int unitType = CommonService.GetUnitTypeByUserId(this.CurrUser.UserId);
|
||||
|
||||
string strSql = @"select F.ProjectId,ProNoticeId,
|
||||
string strSql = @"SELECT F.ProjectId,ProNoticeId,
|
||||
case when F.ProType='1' then a.ProjectName
|
||||
else d.UnitName end as ProjectName
|
||||
,ProCode,CheckMans,
|
||||
case when F.ProType='1' then c.UnitName
|
||||
else d.UnitName end as UnitName
|
||||
,CheckStartTime
|
||||
,CheckEndTime,b.UserName as CreateUserName,F.CreateDate,CreateUser,State,ProType from Problem_Notice F
|
||||
,CheckEndTime,b.UserName as CreateUserName,F.CreateDate,CreateUser,State,ProType
|
||||
FROM Problem_Notice F
|
||||
LEFT JOIN Base_Project a on F.ProjectId=a.ProjectId
|
||||
LEFT JOIN Sys_User b on F.CreateUser=b.UserId
|
||||
LEFT JOIN Base_Unit c on F.Unitid=c.UnitId
|
||||
LEFT JOIN Base_unit d on F.ProjectId=d.UnitId
|
||||
Where F.State not in ('0','1') ";
|
||||
Where F.State not in ('0','1') ";
|
||||
List<SqlParameter> listStr = new List<SqlParameter>();
|
||||
if (unitType != 0 && string.IsNullOrEmpty(ProjectId)) //公司/分公司
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user