This commit is contained in:
geh 2026-01-19 10:34:19 +08:00
parent dfe154dd56
commit feb9e58357
3 changed files with 35 additions and 1 deletions

View File

@ -663,6 +663,10 @@ namespace BLL
string urlParams = "JDGL/SGManPower/SGWarningDetails.aspx?projectId=" + projectId; string urlParams = "JDGL/SGManPower/SGWarningDetails.aspx?projectId=" + projectId;
// 添加单位参数 // 添加单位参数
if (!string.IsNullOrEmpty(unitId))
{
urlParams += "&unitId=" + unitId;
}
if (!string.IsNullOrEmpty(warningType)) if (!string.IsNullOrEmpty(warningType))
{ {
urlParams += "&warningType=" + warningType; urlParams += "&warningType=" + warningType;
@ -739,6 +743,10 @@ namespace BLL
string urlParams = "JDGL/SGManPower/SGWarningDetails.aspx?projectId=" + projectId; string urlParams = "JDGL/SGManPower/SGWarningDetails.aspx?projectId=" + projectId;
// 添加单位参数 // 添加单位参数
if (!string.IsNullOrEmpty(unitId))
{
urlParams += "&unitId=" + unitId;
}
if (!string.IsNullOrEmpty(warningType)) if (!string.IsNullOrEmpty(warningType))
{ {
urlParams += "&warningType=" + warningType; urlParams += "&warningType=" + warningType;

View File

@ -21,6 +21,12 @@ namespace FineUIPro.Web.JDGL.SGManPower
set { ViewState["ProjectId"] = value; } set { ViewState["ProjectId"] = value; }
} }
public string UnitId
{
get => (string)ViewState["UnitId"];
set => ViewState["UnitId"] = value;
}
public string WarningType public string WarningType
{ {
get => (string)ViewState["WarningType"]; get => (string)ViewState["WarningType"];
@ -37,6 +43,7 @@ namespace FineUIPro.Web.JDGL.SGManPower
Funs.DropDownPageSize(this.ddlPageSize); Funs.DropDownPageSize(this.ddlPageSize);
ddlPageSize.SelectedValue = Grid1.PageSize.ToString(); ddlPageSize.SelectedValue = Grid1.PageSize.ToString();
this.ProjectId = Request.Params["projectId"]; this.ProjectId = Request.Params["projectId"];
this.UnitId = Request.Params["unitId"];
this.WarningType = Request.Params["warningType"]; this.WarningType = Request.Params["warningType"];
// 绑定表格 // 绑定表格
BindGrid(); BindGrid();
@ -56,7 +63,11 @@ namespace FineUIPro.Web.JDGL.SGManPower
strSql += " AND ProjectId = @ProjectId "; strSql += " AND ProjectId = @ProjectId ";
listStr.Add(new SqlParameter("@ProjectId", this.ProjectId)); listStr.Add(new SqlParameter("@ProjectId", this.ProjectId));
} }
if (!string.IsNullOrEmpty(this.UnitId))
{
strSql += " AND UnitId = @UnitId ";
listStr.Add(new SqlParameter("@UnitId", this.UnitId));
}
if (!string.IsNullOrEmpty(this.WarningType)) if (!string.IsNullOrEmpty(this.WarningType))
{ {
strSql += " AND WarningType = @WarningType "; strSql += " AND WarningType = @WarningType ";
@ -76,6 +87,21 @@ namespace FineUIPro.Web.JDGL.SGManPower
} }
#region
/// <summary>
/// 查询
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
protected void btnQuery_OnClick(object sender, EventArgs e)
{
this.BindGrid();
}
#endregion
/// <summary> /// <summary>
/// 右键编辑事件 /// 右键编辑事件
/// </summary> /// </summary>