提交定制会内容

This commit is contained in:
2025-06-19 18:59:39 +08:00
parent 6be8d160e0
commit e1eb091f3b
150 changed files with 24036 additions and 582 deletions
@@ -14,6 +14,21 @@ namespace FineUIPro.Web.ZHGL.Supervise
/// 定义集合
/// </summary>
private static List<string> list = new List<string>();
/// <summary>
/// 类型:安全、质量
/// </summary>
public string Type
{
get
{
return (string)ViewState["type"];
}
set
{
ViewState["type"] = value;
}
}
#endregion
#region
@@ -27,6 +42,7 @@ namespace FineUIPro.Web.ZHGL.Supervise
if (!IsPostBack)
{
list = new List<string>();
this.Type = Request.Params["type"];
string lists = Request.Params["lists"];
list = Funs.GetStrListByStr(lists, ',');
InitTreeMenu();
@@ -63,7 +79,7 @@ namespace FineUIPro.Web.ZHGL.Supervise
/// <param name="menuId"></param>
private void BoundTree(TreeNodeCollection nodes, string menuId)
{
var dt = BLL.RectifyService.GetRectifyBySupRectifyId(menuId);
var dt = BLL.RectifyService.GetRectifyBySupRectifyId(menuId, this.Type);
if (dt.Count() > 0)
{
TreeNode tn = null;
@@ -90,6 +106,7 @@ namespace FineUIPro.Web.ZHGL.Supervise
/// <param name="e"></param>
protected void trRectify_NodeCommand(object sender, TreeCommandEventArgs e)
{
this.txtName.Text = "";
BindGrid();
}
#endregion
@@ -100,12 +117,26 @@ namespace FineUIPro.Web.ZHGL.Supervise
/// </summary>
private void BindGrid()
{
string strSql = "select * from View_Technique_RectifyItem where RectifyId=@RectifyId and IsPass=@IsPass";
SqlParameter[] parameter = new SqlParameter[]
{
string strSql = "";
SqlParameter[] parameter = new SqlParameter[] { };
if (string.IsNullOrEmpty(this.txtName.Text.Trim()))
{
strSql = "select * from View_Technique_RectifyItem where RectifyId=@RectifyId and IsPass=@IsPass";
parameter = new SqlParameter[]
{
new SqlParameter("@RectifyId",this.trRectify.SelectedNode.NodeID),
new SqlParameter("@IsPass",true)
};
};
}
else
{
strSql = "select * from View_Technique_RectifyItem where IsPass=@IsPass and HazardSourcePoint like @HazardSourcePoint ";
parameter = new SqlParameter[]
{
new SqlParameter("@IsPass",true),
new SqlParameter("@HazardSourcePoint", "%" + this.txtName.Text.Trim() + "%"),
};
}
DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter);
Grid1.RecordCount = tb.Rows.Count;
@@ -119,10 +150,11 @@ namespace FineUIPro.Web.ZHGL.Supervise
{
for (int i = 0; i < Grid1.Rows.Count; i++)
{
CheckBoxField checkField = (CheckBoxField)Grid1.FindColumn("ckbIsSelected");
string id = Grid1.DataKeys[i][0].ToString();
if (list.Contains(id))
{
Grid1.Rows[i].Values[0] = true;
checkField.SetCheckedState(i, true);
}
}
}
@@ -232,5 +264,19 @@ namespace FineUIPro.Web.ZHGL.Supervise
}
}
#endregion
/// <summary>
/// 查询
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
protected void txtName_TextChanged(object sender, EventArgs e)
{
if (!string.IsNullOrEmpty(this.txtName.Text.Trim()))
{
this.BindGrid();
}
}
}
}