补充公司级别树
This commit is contained in:
@@ -56,12 +56,20 @@ namespace FineUIPro.Web.Customization.ZJ.HSSE.Hazard
|
||||
{
|
||||
Funs.DropDownPageSize(this.ddlPageSize);
|
||||
this.ProjectId = this.CurrUser.LoginProjectId;
|
||||
if (!string.IsNullOrEmpty(Request.Params["projectId"]) && Request.Params["projectId"] != this.ProjectId)
|
||||
if (!string.IsNullOrEmpty(Request.Params["projectId"]) && Request.Params["projectId"] != this.CurrUser.LoginProjectId)
|
||||
{
|
||||
this.ProjectId = Request.Params["projectId"];
|
||||
}
|
||||
////权限按钮方法
|
||||
this.GetButtonPower();
|
||||
|
||||
this.ucTree.UnitId = this.CurrUser.UnitId;
|
||||
this.ucTree.ProjectId = this.ProjectId;
|
||||
if (!string.IsNullOrEmpty(this.CurrUser.LoginProjectId))
|
||||
{
|
||||
this.panelLeftRegion.Hidden = true;
|
||||
////权限按钮方法
|
||||
this.GetButtonPower();
|
||||
}
|
||||
|
||||
ddlPageSize.SelectedValue = Grid1.PageSize.ToString();
|
||||
BLL.RiskLevelService.InitRiskLevelDropDownList(this.drpHazardLevel, true);
|
||||
// 绑定表格
|
||||
@@ -69,11 +77,32 @@ namespace FineUIPro.Web.Customization.ZJ.HSSE.Hazard
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 公司级树加载
|
||||
/// </summary>
|
||||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
this.BindGrid();
|
||||
|
||||
this.GetButtonPower();
|
||||
//if (string.IsNullOrEmpty(this.CurrUser.LoginProjectId))
|
||||
//{
|
||||
// btnNew.Hidden = true;
|
||||
//}
|
||||
}
|
||||
/// <summary>
|
||||
/// 绑定数据
|
||||
/// </summary>
|
||||
private void BindGrid()
|
||||
{
|
||||
if (string.IsNullOrEmpty(this.ProjectId))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
string strSql = "select HazardListItem.*,ControllingPersonUsers.UserName AS ControllingPersonName,Users.UserName,HazardList.WorkAreaName,HazardList.CompileDate,case HazardListItem.State when '1' then '存在' else '已取消' end as StateStr,"
|
||||
+ @" (select UserName from Sys_User where UserId=(select top 1 Evaluatorld from Hazard_RiskEvaluationRecord where DataId=HazardListItem.HazardSelectedItemId order by EvaluatorDate desc)) as EvaluatorPersonName, "
|
||||
+ @" (select top 1 EvaluatorDate from Hazard_RiskEvaluationRecord where DataId=HazardListItem.HazardSelectedItemId order by EvaluatorDate desc) as EvaluatorDate,"
|
||||
|
||||
Reference in New Issue
Block a user