补充公司级别树
This commit is contained in:
@@ -37,11 +37,21 @@ namespace FineUIPro.Web.HSSE.Hazard
|
||||
{
|
||||
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"];
|
||||
}
|
||||
|
||||
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;
|
||||
@@ -53,11 +63,33 @@ namespace FineUIPro.Web.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 Item.HazardId,Item.HazardListTypeId,Item.HazardListId,Item.HazardItems,Item.DefectsType,Item.MayLeadAccidents,Item.HelperMethod,Item.HazardJudge_L "
|
||||
+ @" ,Item.HazardJudge_E,Item.HazardJudge_C,Item.HazardJudge_D,Item.HazardLevel,Item.ControlMeasures,Item.IsResponse"
|
||||
+ @" ,(select RiskLevelName from Base_RiskLevel where RiskLevelId=Item.HazardLevel) as RiskLevelName"
|
||||
|
||||
Reference in New Issue
Block a user