安全管理,作业票等,补充公司级树
This commit is contained in:
@@ -42,15 +42,9 @@ namespace FineUIPro.Web.HSSE.Meeting
|
||||
{
|
||||
this.ProjectId = Request.Params["projectId"];
|
||||
}
|
||||
this.InitDropDownList();
|
||||
this.ucTree.UnitId = this.CurrUser.UnitId;
|
||||
this.ucTree.ProjectId = this.ProjectId;
|
||||
BLL.UnitService.InitUnitDropDownList(this.drpUnitId, this.ProjectId, false);
|
||||
Funs.FineUIPleaseSelect(this.drpUnitId, "按单位查询");
|
||||
if (BLL.ProjectUnitService.GetProjectUnitTypeByProjectIdUnitId(this.ProjectId, this.CurrUser.UnitId))
|
||||
{
|
||||
this.drpUnitId.SelectedValue = this.CurrUser.UnitId;
|
||||
this.drpUnitId.Enabled = false;
|
||||
}
|
||||
this.btnNew.OnClientClick = Window1.GetShowReference("MonthMeetingEdit.aspx") + "return false;";
|
||||
if (this.CurrUser != null && this.CurrUser.PageSize.HasValue)
|
||||
{
|
||||
@@ -72,14 +66,30 @@ namespace FineUIPro.Web.HSSE.Meeting
|
||||
protected void changeTree(object sender, EventArgs e)
|
||||
{
|
||||
this.ProjectId = this.ucTree.ProjectId;
|
||||
this.InitDropDownList();
|
||||
this.BindGrid();
|
||||
}
|
||||
|
||||
private void InitDropDownList()
|
||||
{
|
||||
BLL.UnitService.InitUnitDropDownList(this.drpUnitId, this.ProjectId, false);
|
||||
Funs.FineUIPleaseSelect(this.drpUnitId, "按单位查询");
|
||||
if (BLL.ProjectUnitService.GetProjectUnitTypeByProjectIdUnitId(this.ProjectId, this.CurrUser.UnitId))
|
||||
{
|
||||
this.drpUnitId.SelectedValue = this.CurrUser.UnitId;
|
||||
this.drpUnitId.Enabled = false;
|
||||
}
|
||||
}
|
||||
/// <summary>
|
||||
/// 绑定数据
|
||||
/// </summary>
|
||||
private void BindGrid()
|
||||
{
|
||||
if (string.IsNullOrEmpty(this.ProjectId))
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if (!string.IsNullOrEmpty(this.ProjectId))
|
||||
{
|
||||
string strSql = @"SELECT MonthMeeting.MonthMeetingId,MonthMeeting.ProjectId,CodeRecords.Code AS MonthMeetingCode,Unit.UnitId,Unit.UnitName,MonthMeeting.MonthMeetingName,MonthMeeting.MonthMeetingDate,MonthMeeting.CompileMan,MonthMeeting.MonthMeetingContents,MonthMeeting.CompileDate,MonthMeeting.States,MonthMeeting.MeetingHours,MonthMeeting.MeetingHostMan,MonthMeeting.AttentPersonNum,MonthMeeting.AttentPerson "
|
||||
@@ -95,7 +105,7 @@ namespace FineUIPro.Web.HSSE.Meeting
|
||||
strSql += " AND MonthMeeting.ProjectId = @ProjectId";
|
||||
listStr.Add(new SqlParameter("@ProjectId", this.ProjectId));
|
||||
|
||||
if (this.drpUnitId.SelectedValue != BLL.Const._Null)
|
||||
if (this.drpUnitId.SelectedValue != null && this.drpUnitId.SelectedValue != BLL.Const._Null)
|
||||
{
|
||||
strSql += " AND Unit.UnitId = @UnitId";
|
||||
listStr.Add(new SqlParameter("@UnitId", this.drpUnitId.SelectedValue.Trim()));
|
||||
@@ -218,7 +228,7 @@ namespace FineUIPro.Web.HSSE.Meeting
|
||||
{
|
||||
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("MonthMeetingEdit.aspx?MonthMeetingId={0}", id, "编辑 - ")));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
@@ -241,7 +251,7 @@ namespace FineUIPro.Web.HSSE.Meeting
|
||||
BLL.LogService.AddSys_Log(this.CurrUser, meet.MonthMeetingCode, meet.MonthMeetingId, BLL.Const.ProjectMonthMeetingMenuId, BLL.Const.BtnDelete);
|
||||
|
||||
BLL.MonthMeetingService.DeleteMonthMeetingById(rowID);
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
// Project_HSSEData_HSSEService.StatisticalData(this.CurrUser.LoginProjectId, Project_HSSEData_HSSEService.HSSEDateType.SafetyMeeting);
|
||||
@@ -315,11 +325,11 @@ namespace FineUIPro.Web.HSSE.Meeting
|
||||
Response.AddHeader("content-disposition", "attachment; filename=" + System.Web.HttpUtility.UrlEncode("安全月例会" + filename, System.Text.Encoding.UTF8) + ".xls");
|
||||
Response.ContentType = "application/excel";
|
||||
Response.ContentEncoding = System.Text.Encoding.UTF8;
|
||||
this.Grid1.PageSize = this.Grid1.RecordCount;
|
||||
this.Grid1.PageSize = this.Grid1.RecordCount;
|
||||
this.BindGrid();
|
||||
Response.Write(GetGridTableHtml(Grid1));
|
||||
Response.End();
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
protected void btnView_Click(object sender, EventArgs e)
|
||||
|
||||
Reference in New Issue
Block a user