集成人员同步,专项检查同步

This commit is contained in:
2026-02-28 10:57:21 +08:00
parent 8f8f970ed5
commit 37ec112f65
51 changed files with 10342 additions and 20 deletions
@@ -55,6 +55,15 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
{
Type = Request.Params["Type"];
Funs.DropDownPageSize(this.ddlPageSize);
ListItem[] ProblemTypes = new ListItem[2];
ProblemTypes[0] = new ListItem("日常巡检", "1");
ProblemTypes[1] = new ListItem("专项巡检", "2");
this.drpProblemTypes.DataValueField = "Value";
this.drpProblemTypes.DataTextField = "Text";
this.drpProblemTypes.DataSource = ProblemTypes;
this.drpProblemTypes.DataBind();
Funs.FineUIPleaseSelect(this.drpProblemTypes);
GetButtonPower();
this.ItemSelectedList = new List<string>();
ddlPageSize.SelectedValue = Grid1.PageSize.ToString();
@@ -73,7 +82,8 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
/// </summary>
private void BindGrid()
{
string strSql = "SELECT * FROM View_Hazard_HazardRegister WHERE ProblemTypes='1' ";
//string strSql = "SELECT * FROM View_Hazard_HazardRegister WHERE ProblemTypes='1' ";
string strSql = "SELECT * FROM View_Hazard_HazardRegister ";
List<SqlParameter> listStr = new List<SqlParameter>();
if (!string.IsNullOrEmpty(this.CurrUser.LoginProjectId))
{
@@ -90,6 +100,23 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
strSql += " AND CheckManName LIKE @CheckMan";
listStr.Add(new SqlParameter("@CheckMan", "%" + this.txtCheckMan.Text.Trim() + "%"));
}
if (this.drpProblemTypes.SelectedValue != BLL.Const._Null)
{
strSql += " AND ProblemTypes = @ProblemTypes";
listStr.Add(new SqlParameter("@ProblemTypes", this.drpProblemTypes.SelectedValue));
}
if (this.drpDataSource.SelectedValue != BLL.Const._Null)
{
if (this.drpDataSource.SelectedValue == "0")
{
strSql += " AND DataSource = @DataSource";
}
else
{
strSql += " AND (DataSource = @DataSource OR DataSource is null)";
}
listStr.Add(new SqlParameter("@DataSource", this.drpDataSource.SelectedValue));
}
//if (!string.IsNullOrEmpty(this.txtType.Text.Trim()))
//{
// strSql += " AND RegisterTypesName LIKE @Type";
@@ -285,6 +312,20 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
}
#endregion
protected string ConvertDataSource(object dataSource)
{
string data = "本单位";
if (dataSource != null)
{
if (dataSource.ToString() == "1")
{
data = "总包";
}
}
return data;
}
#region
/// <summary>
/// 整改按钮
@@ -292,6 +333,50 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
/// <param name="sender"></param>
/// <param name="e"></param>
protected void btnMenuRectify_Click(object sender, EventArgs e)
{
if (Grid1.SelectedRowIndexArray.Length == 0)
{
Alert.ShowInTop("请至少选择一条记录!", MessageBoxIcon.Warning);
return;
}
string RegistrationId = Grid1.SelectedRowID;
var registration = BLL.HSSE_Hazard_HazardRegisterService.GetHazardRegisterByHazardRegisterId(RegistrationId);
if (registration != null)
{
if (registration.States == "1") //待整改
{
if (registration.DataSource == "1")
{
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("HiddenRectificationRectify.aspx?HazardRegisterId={0}", RegistrationId, "编辑 - ")));
}
else
{
if (registration.ResponsibleMan == this.CurrUser.UserId) //当前人是责任人,可以进行整改操作
{
PageContext.RegisterStartupScript(Window1.GetShowReference(String.Format("HiddenRectificationRectify.aspx?HazardRegisterId={0}", RegistrationId, "编辑 - ")));
}
else
{
Alert.ShowInTop("您不是记录责任人,无法整改!", MessageBoxIcon.Warning);
return;
}
}
}
else
{
Alert.ShowInTop("该记录不是待整改状态,无法进行整改操作!", MessageBoxIcon.Warning);
return;
}
}
}
/*
/// <summary>
/// 整改按钮
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
protected void btnMenuRectify_Click(object sender, EventArgs e)
{
if (Grid1.SelectedRowIndexArray.Length == 0)
{
@@ -321,6 +406,8 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
}
}
}
*/
#endregion
#region