报表管理:安全、职业健康危害因素清单补充事故分类
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
ALTER TABLE HazardFactor_Safety
|
||||
ADD AccidentType NVARCHAR(200) null;
|
||||
GO
|
||||
ALTER TABLE HazardFactor_OccHealth
|
||||
ADD AccidentType NVARCHAR(200) null;
|
||||
GO
|
||||
@@ -41,6 +41,7 @@ namespace BLL
|
||||
newModel.JobStep = model.JobStep;
|
||||
newModel.Hazard = model.Hazard;
|
||||
newModel.Consequence = model.Consequence;
|
||||
newModel.AccidentType = model.AccidentType;
|
||||
newModel.Illegality = model.Illegality;
|
||||
newModel.BaseRiskSeverity = model.BaseRiskSeverity;
|
||||
newModel.BaseRiskProbability = model.BaseRiskProbability;
|
||||
@@ -76,6 +77,7 @@ namespace BLL
|
||||
newModel.JobStep = model.JobStep;
|
||||
newModel.Hazard = model.Hazard;
|
||||
newModel.Consequence = model.Consequence;
|
||||
newModel.AccidentType = model.AccidentType;
|
||||
newModel.Illegality = model.Illegality;
|
||||
newModel.BaseRiskSeverity = model.BaseRiskSeverity;
|
||||
newModel.BaseRiskProbability = model.BaseRiskProbability;
|
||||
|
||||
@@ -41,6 +41,7 @@ namespace BLL
|
||||
newModel.JobStep = model.JobStep;
|
||||
newModel.Hazard = model.Hazard;
|
||||
newModel.Consequence = model.Consequence;
|
||||
newModel.AccidentType = model.AccidentType;
|
||||
newModel.Illegality = model.Illegality;
|
||||
newModel.BaseRiskSeverity = model.BaseRiskSeverity;
|
||||
newModel.BaseRiskProbability = model.BaseRiskProbability;
|
||||
@@ -76,6 +77,7 @@ namespace BLL
|
||||
newModel.JobStep = model.JobStep;
|
||||
newModel.Hazard = model.Hazard;
|
||||
newModel.Consequence = model.Consequence;
|
||||
newModel.AccidentType = model.AccidentType;
|
||||
newModel.Illegality = model.Illegality;
|
||||
newModel.BaseRiskSeverity = model.BaseRiskSeverity;
|
||||
newModel.BaseRiskProbability = model.BaseRiskProbability;
|
||||
|
||||
Binary file not shown.
Binary file not shown.
@@ -93,6 +93,8 @@
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="Consequence" DataField="Consequence" SortField="Consequence" FieldType="String" HeaderText="主要后果" TextAlign="Center" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="AccidentType" DataField="AccidentType" SortField="AccidentType" FieldType="String" HeaderText="事故分类" TextAlign="Center" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:CheckBoxField Width="50px" RenderAsStaticField="true" DataField="Illegality" SortField="Illegality" HeaderText="违法" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:CheckBoxField>
|
||||
<f:GroupField ColumnID="GroupField2" runat="server" HeaderText="固有风险评价" HeaderTextAlign="Center">
|
||||
|
||||
@@ -39,7 +39,19 @@
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtConsequence" runat="server" Label="主要后果" EmptyText="请输入主要后果(20字以内)" MaxLength="20" ShowRedStar="true" Required="true">
|
||||
<%--<f:TextBox ID="txtConsequence" runat="server" Label="主要后果" EmptyText="请输入主要后果(20字以内)" MaxLength="20" ShowRedStar="true" Required="true">
|
||||
</f:TextBox>--%>
|
||||
<f:RadioButtonList ID="rblConsequence" runat="server" Label="主要后果" LabelAlign="Right" Required="True" ShowRedStar="True">
|
||||
<f:RadioItem Value="人员伤亡" Text="人员伤亡" />
|
||||
<f:RadioItem Value="财产损失" Text="财产损失" />
|
||||
<f:RadioItem Value="环境破坏" Text="环境破坏" />
|
||||
<f:RadioItem Value="公司声誉" Text="公司声誉" />
|
||||
</f:RadioButtonList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtAccidentType" runat="server" Label="事故分类" EmptyText="请输入事故分类(20字以内)" MaxLength="20" ShowRedStar="true" Required="true">
|
||||
</f:TextBox>
|
||||
<f:RadioButtonList ID="rblIllegality" runat="server" Label="违法" LabelAlign="Right" Required="True" ShowRedStar="True">
|
||||
<f:RadioItem Value="1" Text="是" />
|
||||
@@ -47,6 +59,12 @@
|
||||
</f:RadioButtonList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtNetRiskControlMeasures" runat="server" Label="现有控制措施" EmptyText="请输入现有控制措施(500字以内)" LabelAlign="Right" MaxLength="500" Height="80px" ShowRedStar="true" Required="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:Panel ID="Panel1" Title="" BodyPadding="5px" runat="server" ShowHeader="false" EnableCollapse="True" AutoScroll="true">
|
||||
@@ -90,12 +108,12 @@
|
||||
<Items>
|
||||
<f:Form ID="Form4" ShowBorder="false" ShowHeader="false" runat="server">
|
||||
<Rows>
|
||||
<f:FormRow>
|
||||
<%--<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtNetRiskControlMeasures" runat="server" Label="现有控制措施" EmptyText="请输入现有控制措施(500字以内)" LabelAlign="Right" MaxLength="500" Height="80px" ShowRedStar="true" Required="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
</f:FormRow>--%>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:NumberBox ID="txtNetRiskSeverity" runat="server" Label="严重性" AutoPostBack="true" OnTextChanged="NetRisk_OnTextChanged" LabelAlign="Right" NoDecimal="true" NoNegative="true" EmptyText="0" ShowRedStar="true" Required="true">
|
||||
|
||||
@@ -77,7 +77,9 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
this.txtWorkPlace.Text = model.WorkPlace;
|
||||
this.txtJobStep.Text = model.JobStep;
|
||||
this.txtHazard.Text = model.Hazard;
|
||||
this.txtConsequence.Text = model.Consequence;
|
||||
//this.txtConsequence.Text = model.Consequence;
|
||||
this.rblConsequence.SelectedValue = model.Consequence;
|
||||
this.txtAccidentType.Text = model.AccidentType;
|
||||
this.rblIllegality.SelectedValue = model.Illegality ? "1" : "0";
|
||||
this.txtBaseRiskSeverity.Text = model.BaseRiskSeverity.ToString();
|
||||
this.txtBaseRiskProbability.Text = model.BaseRiskProbability.ToString();
|
||||
@@ -160,7 +162,9 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
model.WorkPlace = this.txtWorkPlace.Text.Trim();
|
||||
model.JobStep = this.txtJobStep.Text.Trim();
|
||||
model.Hazard = this.txtHazard.Text.Trim();
|
||||
model.Consequence = this.txtConsequence.Text.Trim();
|
||||
//model.Consequence = this.txtConsequence.Text.Trim();
|
||||
model.Consequence = this.rblConsequence.SelectedValue;
|
||||
model.AccidentType = this.txtAccidentType.Text.Trim();
|
||||
model.Illegality = this.rblIllegality.SelectedValue == "1";
|
||||
model.BaseRiskSeverity = int.Parse(this.txtBaseRiskSeverity.Text.Trim());
|
||||
model.BaseRiskProbability = int.Parse(this.txtBaseRiskProbability.Text.Trim());
|
||||
|
||||
+20
-11
@@ -96,13 +96,22 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
protected global::FineUIPro.TextArea txtHazard;
|
||||
|
||||
/// <summary>
|
||||
/// txtConsequence 控件。
|
||||
/// rblConsequence 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtConsequence;
|
||||
protected global::FineUIPro.RadioButtonList rblConsequence;
|
||||
|
||||
/// <summary>
|
||||
/// txtAccidentType 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtAccidentType;
|
||||
|
||||
/// <summary>
|
||||
/// rblIllegality 控件。
|
||||
@@ -113,6 +122,15 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.RadioButtonList rblIllegality;
|
||||
|
||||
/// <summary>
|
||||
/// txtNetRiskControlMeasures 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtNetRiskControlMeasures;
|
||||
|
||||
/// <summary>
|
||||
/// Panel1 控件。
|
||||
/// </summary>
|
||||
@@ -212,15 +230,6 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Form Form4;
|
||||
|
||||
/// <summary>
|
||||
/// txtNetRiskControlMeasures 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtNetRiskControlMeasures;
|
||||
|
||||
/// <summary>
|
||||
/// txtNetRiskSeverity 控件。
|
||||
/// </summary>
|
||||
|
||||
@@ -78,9 +78,10 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
}
|
||||
}
|
||||
|
||||
public static int Cols = 19;//列数
|
||||
public static int Cols = 20;//列数
|
||||
|
||||
public static List<string> validLevelStrings = new List<string> { "低风险", "一般风险", "较大风险", "重大风险" };
|
||||
public static List<string> validConsequenceStrings = new List<string> { "人员伤亡", "财产损失", "环境破坏", "公司声誉" };
|
||||
|
||||
#endregion
|
||||
|
||||
@@ -269,22 +270,23 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
string rData2 = row[2]?.ToString().Trim(); // 作业内容/步骤
|
||||
string rData3 = row[3]?.ToString().Trim(); // 危害因素描述
|
||||
string rData4 = row[4]?.ToString().Trim(); // 主要后果
|
||||
string rData5 = row[5]?.ToString().Trim(); // 违法
|
||||
string rData6 = row[6]?.ToString().Trim(); // 固有风险-严重性
|
||||
string rData7 = row[7]?.ToString().Trim(); // 固有风险-可能性
|
||||
string rData8 = row[8]?.ToString().Trim(); // 固有风险-得分
|
||||
string rData9 = row[9]?.ToString().Trim(); // 固有风险-风险级别
|
||||
string rData10 = row[10]?.ToString().Trim(); // 固有风险-可接受
|
||||
string rData11 = row[11]?.ToString().Trim(); // 残留风险-现有控制措施
|
||||
string rData12 = row[12]?.ToString().Trim(); // 残留风险-严重性
|
||||
string rData13 = row[13]?.ToString().Trim(); // 残留风险-可能性
|
||||
string rData14 = row[14]?.ToString().Trim(); // 残留风险-得分
|
||||
string rData15 = row[15]?.ToString().Trim(); // 残留风险-风险级别
|
||||
string rData16 = row[16]?.ToString().Trim(); // 残留风险-可接受
|
||||
string rData17 = row[17]?.ToString().Trim(); // 新增或变更的控制措施
|
||||
string rData18 = row[18]?.ToString().Trim(); // 责任部门
|
||||
string rData5 = row[5]?.ToString().Trim(); // 事故分类
|
||||
string rData6 = row[6]?.ToString().Trim(); // 违法
|
||||
string rData7 = row[7]?.ToString().Trim(); // 固有风险-严重性
|
||||
string rData8 = row[8]?.ToString().Trim(); // 固有风险-可能性
|
||||
string rData9 = row[9]?.ToString().Trim(); // 固有风险-得分
|
||||
string rData10 = row[10]?.ToString().Trim(); // 固有风险-风险级别
|
||||
string rData11 = row[11]?.ToString().Trim(); // 固有风险-可接受
|
||||
string rData12 = row[12]?.ToString().Trim(); // 残留风险-现有控制措施
|
||||
string rData13 = row[13]?.ToString().Trim(); // 残留风险-严重性
|
||||
string rData14 = row[14]?.ToString().Trim(); // 残留风险-可能性
|
||||
string rData15 = row[15]?.ToString().Trim(); // 残留风险-得分
|
||||
string rData16 = row[16]?.ToString().Trim(); // 残留风险-风险级别
|
||||
string rData17 = row[17]?.ToString().Trim(); // 残留风险-可接受
|
||||
string rData18 = row[18]?.ToString().Trim(); // 新增或变更的控制措施
|
||||
string rData19 = row[19]?.ToString().Trim(); // 责任部门
|
||||
|
||||
rData17 = rData17 == "无" ? string.Empty : rData17;
|
||||
rData18 = rData18 == "无" ? string.Empty : rData18;
|
||||
|
||||
string Year = string.Empty;
|
||||
string Month = string.Empty;
|
||||
@@ -292,6 +294,7 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
string JobStep = string.Empty;
|
||||
string Hazard = string.Empty;
|
||||
string Consequence = string.Empty;
|
||||
string AccidentType = string.Empty;
|
||||
bool Illegality = false;
|
||||
int BaseRiskSeverity = 0;
|
||||
int BaseRiskProbability = 0;
|
||||
@@ -351,16 +354,32 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
}
|
||||
if (!string.IsNullOrEmpty(rData4))
|
||||
{
|
||||
Consequence = rData4;
|
||||
//Consequence = rData4;
|
||||
if (!validConsequenceStrings.Any(x => x == rData4))
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "主要后果", Reason = "只能是[人员伤亡/财产损失/环境破坏/公司声誉]!" });
|
||||
}
|
||||
else
|
||||
{
|
||||
Consequence = rData4;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "主要后果", Reason = "不能为空" });
|
||||
}
|
||||
Illegality = !string.IsNullOrEmpty(rData5) && rData5 == "是";
|
||||
if (!string.IsNullOrEmpty(rData6))
|
||||
if (!string.IsNullOrEmpty(rData5))
|
||||
{
|
||||
if (!int.TryParse(rData6, out int ct))
|
||||
AccidentType = rData5;
|
||||
}
|
||||
else
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "事故分类", Reason = "不能为空" });
|
||||
}
|
||||
Illegality = !string.IsNullOrEmpty(rData6) && rData6 == "是";
|
||||
if (!string.IsNullOrEmpty(rData7))
|
||||
{
|
||||
if (!int.TryParse(rData7, out int ct))
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "固有风险严重性", Reason = "格式错误" });
|
||||
}
|
||||
@@ -369,9 +388,9 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
BaseRiskSeverity = ct;
|
||||
}
|
||||
}
|
||||
if (!string.IsNullOrEmpty(rData7))
|
||||
if (!string.IsNullOrEmpty(rData8))
|
||||
{
|
||||
if (!int.TryParse(rData7, out int ct))
|
||||
if (!int.TryParse(rData8, out int ct))
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "固有风险可能性", Reason = "格式错误" });
|
||||
}
|
||||
@@ -386,19 +405,19 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
{
|
||||
BaseRiskLevel = baseRiskLevel.RiskLevelName;
|
||||
}
|
||||
BaseRiskAcceptabity = !string.IsNullOrEmpty(rData10) && rData10 == "否" ? false : true;
|
||||
if (!string.IsNullOrEmpty(rData11))
|
||||
BaseRiskAcceptabity = !string.IsNullOrEmpty(rData11) && rData11 == "否" ? false : true;
|
||||
if (!string.IsNullOrEmpty(rData12))
|
||||
{
|
||||
NetRiskControlMeasures = rData11;
|
||||
NetRiskControlMeasures = rData12;
|
||||
}
|
||||
else
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "现有控制措施", Reason = "不能为空" });
|
||||
}
|
||||
|
||||
if (!string.IsNullOrEmpty(rData12))
|
||||
if (!string.IsNullOrEmpty(rData13))
|
||||
{
|
||||
if (!int.TryParse(rData12, out int ct))
|
||||
if (!int.TryParse(rData13, out int ct))
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "残留风险严重性", Reason = "格式错误" });
|
||||
}
|
||||
@@ -407,9 +426,9 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
NetRiskSeverity = ct;
|
||||
}
|
||||
}
|
||||
if (!string.IsNullOrEmpty(rData13))
|
||||
if (!string.IsNullOrEmpty(rData14))
|
||||
{
|
||||
if (!int.TryParse(rData13, out int ct))
|
||||
if (!int.TryParse(rData14, out int ct))
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "残留风险可能性", Reason = "格式错误" });
|
||||
}
|
||||
@@ -424,15 +443,15 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
{
|
||||
NetRiskLevel = netRiskLevel.RiskLevelName;
|
||||
}
|
||||
NetRiskAcceptabity = !string.IsNullOrEmpty(rData16) && rData16 == "否" ? false : true;
|
||||
NetRiskAcceptabity = !string.IsNullOrEmpty(rData17) && rData17 == "否" ? false : true;
|
||||
|
||||
if (!string.IsNullOrEmpty(rData17))
|
||||
{
|
||||
AdditionalControlMeasures = rData17;
|
||||
}
|
||||
if (!string.IsNullOrEmpty(rData18))
|
||||
{
|
||||
ResponsibleDepartment = rData18;
|
||||
AdditionalControlMeasures = rData18;
|
||||
}
|
||||
if (!string.IsNullOrEmpty(rData19))
|
||||
{
|
||||
ResponsibleDepartment = rData19;
|
||||
}
|
||||
|
||||
if (lstError.Any())
|
||||
@@ -469,6 +488,7 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
JobStep = JobStep,
|
||||
Hazard = Hazard,
|
||||
Consequence = Consequence,
|
||||
AccidentType = AccidentType,
|
||||
Illegality = Illegality,
|
||||
BaseRiskSeverity = BaseRiskSeverity,
|
||||
BaseRiskProbability = BaseRiskProbability,
|
||||
|
||||
@@ -105,6 +105,8 @@
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="Consequence" DataField="Consequence" SortField="Consequence" FieldType="String" HeaderText="主要后果" TextAlign="Center" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="AccidentType" DataField="AccidentType" SortField="AccidentType" FieldType="String" HeaderText="事故分类" TextAlign="Center" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:CheckBoxField Width="50px" RenderAsStaticField="true" DataField="Illegality" SortField="Illegality" HeaderText="违法" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:CheckBoxField>
|
||||
<f:GroupField ColumnID="GroupField2" runat="server" HeaderText="固有风险评价" HeaderTextAlign="Center">
|
||||
|
||||
@@ -65,11 +65,11 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
sb.Append("WITH CTE AS ( ");
|
||||
if (dedupe == "0")
|
||||
{//按月
|
||||
sb.Append("SELECT ROW_NUMBER() OVER (PARTITION BY tba.Year,tba.Month,tba.WorkPlace,tba.JobStep,tba.Hazard,tba.Consequence,tba.Illegality,tba.BaseRiskSeverity,tba.BaseRiskProbability,tba.BaseRiskScore,tba.BaseRiskLevel,tba.BaseRiskAcceptabity,tba.NetRiskControlMeasures,tba.NetRiskSeverity,tba.NetRiskProbability,tba.NetRiskScore,tba.NetRiskLevel,tba.NetRiskAcceptabity,tba.AdditionalControlMeasures ORDER BY CompileDate desc) as rn,tba.* ");
|
||||
sb.Append("SELECT ROW_NUMBER() OVER (PARTITION BY tba.Year,tba.Month,tba.WorkPlace,tba.JobStep,tba.Hazard,tba.Consequence,tba.AccidentType,tba.Illegality,tba.BaseRiskSeverity,tba.BaseRiskProbability,tba.BaseRiskScore,tba.BaseRiskLevel,tba.BaseRiskAcceptabity,tba.NetRiskControlMeasures,tba.NetRiskSeverity,tba.NetRiskProbability,tba.NetRiskScore,tba.NetRiskLevel,tba.NetRiskAcceptabity,tba.AdditionalControlMeasures ORDER BY CompileDate desc) as rn,tba.* ");
|
||||
}
|
||||
else
|
||||
{//按年
|
||||
sb.Append("SELECT ROW_NUMBER() OVER (PARTITION BY tba.Year,tba.WorkPlace,tba.JobStep,tba.Hazard,tba.Consequence,tba.Illegality,tba.BaseRiskSeverity,tba.BaseRiskProbability,tba.BaseRiskScore,tba.BaseRiskLevel,tba.BaseRiskAcceptabity,tba.NetRiskControlMeasures,tba.NetRiskSeverity,tba.NetRiskProbability,tba.NetRiskScore,tba.NetRiskLevel,tba.NetRiskAcceptabity,tba.AdditionalControlMeasures ORDER BY CompileDate desc) as rn,tba.* ");
|
||||
sb.Append("SELECT ROW_NUMBER() OVER (PARTITION BY tba.Year,tba.WorkPlace,tba.JobStep,tba.Hazard,tba.Consequence,tba.AccidentType,tba.Illegality,tba.BaseRiskSeverity,tba.BaseRiskProbability,tba.BaseRiskScore,tba.BaseRiskLevel,tba.BaseRiskAcceptabity,tba.NetRiskControlMeasures,tba.NetRiskSeverity,tba.NetRiskProbability,tba.NetRiskScore,tba.NetRiskLevel,tba.NetRiskAcceptabity,tba.AdditionalControlMeasures ORDER BY CompileDate desc) as rn,tba.* ");
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
@@ -45,14 +45,32 @@
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtConsequence" runat="server" Label="主要后果" Readonly="true" MaxLength="20" ShowRedStar="true" Required="true">
|
||||
<%--<f:TextBox ID="txtConsequence" runat="server" Label="主要后果" Readonly="true" MaxLength="20" ShowRedStar="true" Required="true">
|
||||
</f:TextBox>--%>
|
||||
<f:RadioButtonList ID="rblConsequence" runat="server" Label="主要后果" LabelAlign="Right" Required="True" ShowRedStar="True" Readonly="true">
|
||||
<f:RadioItem Value="人员伤亡" Text="人员伤亡" />
|
||||
<f:RadioItem Value="财产损失" Text="财产损失" />
|
||||
<f:RadioItem Value="环境破坏" Text="环境破坏" />
|
||||
<f:RadioItem Value="公司声誉" Text="公司声誉" />
|
||||
</f:RadioButtonList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtAccidentType" runat="server" Label="事故分类" Readonly="true" MaxLength="20" ShowRedStar="true" Required="true">
|
||||
</f:TextBox>
|
||||
<f:RadioButtonList ID="rblIllegality" runat="server" Label="违法" LabelAlign="Right" Required="True" ShowRedStar="True" Readonly="true">
|
||||
<f:RadioItem Value="1" Text="是" />
|
||||
<f:RadioItem Value="0" Text="否" Selected="true" />
|
||||
<f:RadioItem Value="0" Text="否" />
|
||||
</f:RadioButtonList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtNetRiskControlMeasures" runat="server" Label="现有控制措施" Readonly="true" LabelAlign="Right" MaxLength="500" Height="80px" ShowRedStar="true" Required="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:Panel ID="Panel1" Title="" BodyPadding="5px" runat="server" ShowHeader="false" EnableCollapse="True" AutoScroll="true">
|
||||
@@ -96,12 +114,6 @@
|
||||
<Items>
|
||||
<f:Form ID="Form4" ShowBorder="false" ShowHeader="false" runat="server">
|
||||
<Rows>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtNetRiskControlMeasures" runat="server" Label="现有控制措施" Readonly="true" LabelAlign="Right" MaxLength="500" Height="80px" ShowRedStar="true" Required="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:NumberBox ID="txtNetRiskSeverity" runat="server" Label="严重性" Readonly="true" LabelAlign="Right" NoDecimal="true" NoNegative="true" EmptyText="0" ShowRedStar="true" Required="true">
|
||||
|
||||
@@ -63,7 +63,9 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
this.txtWorkPlace.Text = model.WorkPlace;
|
||||
this.txtJobStep.Text = model.JobStep;
|
||||
this.txtHazard.Text = model.Hazard;
|
||||
this.txtConsequence.Text = model.Consequence;
|
||||
//this.txtConsequence.Text = model.Consequence;
|
||||
this.rblConsequence.SelectedValue = model.Consequence;
|
||||
this.txtAccidentType.Text = model.AccidentType;
|
||||
this.rblIllegality.SelectedValue = model.Illegality ? "1" : "0";
|
||||
this.txtBaseRiskSeverity.Text = model.BaseRiskSeverity.ToString();
|
||||
this.txtBaseRiskProbability.Text = model.BaseRiskProbability.ToString();
|
||||
|
||||
+20
-11
@@ -105,13 +105,22 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
protected global::FineUIPro.TextArea txtHazard;
|
||||
|
||||
/// <summary>
|
||||
/// txtConsequence 控件。
|
||||
/// rblConsequence 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtConsequence;
|
||||
protected global::FineUIPro.RadioButtonList rblConsequence;
|
||||
|
||||
/// <summary>
|
||||
/// txtAccidentType 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtAccidentType;
|
||||
|
||||
/// <summary>
|
||||
/// rblIllegality 控件。
|
||||
@@ -122,6 +131,15 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.RadioButtonList rblIllegality;
|
||||
|
||||
/// <summary>
|
||||
/// txtNetRiskControlMeasures 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtNetRiskControlMeasures;
|
||||
|
||||
/// <summary>
|
||||
/// Panel1 控件。
|
||||
/// </summary>
|
||||
@@ -221,15 +239,6 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Form Form4;
|
||||
|
||||
/// <summary>
|
||||
/// txtNetRiskControlMeasures 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtNetRiskControlMeasures;
|
||||
|
||||
/// <summary>
|
||||
/// txtNetRiskSeverity 控件。
|
||||
/// </summary>
|
||||
|
||||
@@ -93,6 +93,8 @@
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="Consequence" DataField="Consequence" SortField="Consequence" FieldType="String" HeaderText="主要后果" TextAlign="Center" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="AccidentType" DataField="AccidentType" SortField="AccidentType" FieldType="String" HeaderText="事故分类" TextAlign="Center" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:CheckBoxField Width="50px" RenderAsStaticField="true" DataField="Illegality" SortField="Illegality" HeaderText="违法" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:CheckBoxField>
|
||||
<f:GroupField ColumnID="GroupField2" runat="server" HeaderText="固有风险评价" HeaderTextAlign="Center">
|
||||
|
||||
@@ -39,7 +39,19 @@
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtConsequence" runat="server" Label="主要后果" EmptyText="请输入主要后果(20字以内)" MaxLength="20" ShowRedStar="true" Required="true">
|
||||
<%--<f:TextBox ID="txtConsequence" runat="server" Label="主要后果" EmptyText="请输入主要后果(20字以内)" MaxLength="20" ShowRedStar="true" Required="true">
|
||||
</f:TextBox>--%>
|
||||
<f:RadioButtonList ID="rblConsequence" runat="server" Label="主要后果" LabelAlign="Right" Required="True" ShowRedStar="True">
|
||||
<f:RadioItem Value="人员伤亡" Text="人员伤亡" />
|
||||
<f:RadioItem Value="财产损失" Text="财产损失" />
|
||||
<f:RadioItem Value="环境破坏" Text="环境破坏" />
|
||||
<f:RadioItem Value="公司声誉" Text="公司声誉" />
|
||||
</f:RadioButtonList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtAccidentType" runat="server" Label="事故分类" EmptyText="请输入事故分类(20字以内)" MaxLength="20" ShowRedStar="true" Required="true">
|
||||
</f:TextBox>
|
||||
<f:RadioButtonList ID="rblIllegality" runat="server" Label="违法" LabelAlign="Right" Required="True" ShowRedStar="True">
|
||||
<f:RadioItem Value="1" Text="是" />
|
||||
@@ -47,6 +59,12 @@
|
||||
</f:RadioButtonList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtNetRiskControlMeasures" runat="server" Label="现有控制措施" EmptyText="请输入现有控制措施(500字以内)" LabelAlign="Right" MaxLength="500" Height="80px" ShowRedStar="true" Required="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:Panel ID="Panel1" Title="" BodyPadding="5px" runat="server" ShowHeader="false" EnableCollapse="True" AutoScroll="true">
|
||||
@@ -90,12 +108,12 @@
|
||||
<Items>
|
||||
<f:Form ID="Form4" ShowBorder="false" ShowHeader="false" runat="server">
|
||||
<Rows>
|
||||
<f:FormRow>
|
||||
<%--<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtNetRiskControlMeasures" runat="server" Label="现有控制措施" EmptyText="请输入现有控制措施(500字以内)" LabelAlign="Right" MaxLength="500" Height="80px" ShowRedStar="true" Required="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
</f:FormRow>--%>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:NumberBox ID="txtNetRiskSeverity" runat="server" Label="严重性" AutoPostBack="true" OnTextChanged="NetRisk_OnTextChanged" LabelAlign="Right" NoDecimal="true" NoNegative="true" EmptyText="0" ShowRedStar="true" Required="true">
|
||||
|
||||
@@ -76,7 +76,9 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
this.txtWorkPlace.Text = model.WorkPlace;
|
||||
this.txtJobStep.Text = model.JobStep;
|
||||
this.txtHazard.Text = model.Hazard;
|
||||
this.txtConsequence.Text = model.Consequence;
|
||||
//this.txtConsequence.Text = model.Consequence;
|
||||
this.rblConsequence.SelectedValue = model.Consequence;
|
||||
this.txtAccidentType.Text = model.AccidentType;
|
||||
this.rblIllegality.SelectedValue = model.Illegality ? "1" : "0";
|
||||
this.txtBaseRiskSeverity.Text = model.BaseRiskSeverity.ToString();
|
||||
this.txtBaseRiskProbability.Text = model.BaseRiskProbability.ToString();
|
||||
@@ -159,7 +161,9 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
model.WorkPlace = this.txtWorkPlace.Text.Trim();
|
||||
model.JobStep = this.txtJobStep.Text.Trim();
|
||||
model.Hazard = this.txtHazard.Text.Trim();
|
||||
model.Consequence = this.txtConsequence.Text.Trim();
|
||||
//model.Consequence = this.txtConsequence.Text.Trim();
|
||||
model.Consequence = this.rblConsequence.SelectedValue;
|
||||
model.AccidentType = this.txtAccidentType.Text.Trim();
|
||||
model.Illegality = this.rblIllegality.SelectedValue == "1";
|
||||
model.BaseRiskSeverity = int.Parse(this.txtBaseRiskSeverity.Text.Trim());
|
||||
model.BaseRiskProbability = int.Parse(this.txtBaseRiskProbability.Text.Trim());
|
||||
|
||||
+20
-11
@@ -96,13 +96,22 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
protected global::FineUIPro.TextArea txtHazard;
|
||||
|
||||
/// <summary>
|
||||
/// txtConsequence 控件。
|
||||
/// rblConsequence 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtConsequence;
|
||||
protected global::FineUIPro.RadioButtonList rblConsequence;
|
||||
|
||||
/// <summary>
|
||||
/// txtAccidentType 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtAccidentType;
|
||||
|
||||
/// <summary>
|
||||
/// rblIllegality 控件。
|
||||
@@ -113,6 +122,15 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.RadioButtonList rblIllegality;
|
||||
|
||||
/// <summary>
|
||||
/// txtNetRiskControlMeasures 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtNetRiskControlMeasures;
|
||||
|
||||
/// <summary>
|
||||
/// Panel1 控件。
|
||||
/// </summary>
|
||||
@@ -212,15 +230,6 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Form Form4;
|
||||
|
||||
/// <summary>
|
||||
/// txtNetRiskControlMeasures 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtNetRiskControlMeasures;
|
||||
|
||||
/// <summary>
|
||||
/// txtNetRiskSeverity 控件。
|
||||
/// </summary>
|
||||
|
||||
@@ -78,9 +78,10 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
}
|
||||
}
|
||||
|
||||
public static int Cols = 19;//列数
|
||||
public static int Cols = 20;//列数
|
||||
|
||||
public static List<string> validLevelStrings = new List<string> { "低风险", "一般风险", "较大风险", "重大风险" };
|
||||
public static List<string> validConsequenceStrings = new List<string> { "人员伤亡", "财产损失", "环境破坏", "公司声誉" };
|
||||
|
||||
#endregion
|
||||
|
||||
@@ -269,22 +270,23 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
string rData2 = row[2]?.ToString().Trim(); // 作业内容/步骤
|
||||
string rData3 = row[3]?.ToString().Trim(); // 危害因素描述
|
||||
string rData4 = row[4]?.ToString().Trim(); // 主要后果
|
||||
string rData5 = row[5]?.ToString().Trim(); // 违法
|
||||
string rData6 = row[6]?.ToString().Trim(); // 固有风险-严重性
|
||||
string rData7 = row[7]?.ToString().Trim(); // 固有风险-可能性
|
||||
string rData8 = row[8]?.ToString().Trim(); // 固有风险-得分
|
||||
string rData9 = row[9]?.ToString().Trim(); // 固有风险-风险级别
|
||||
string rData10 = row[10]?.ToString().Trim(); // 固有风险-可接受
|
||||
string rData11 = row[11]?.ToString().Trim(); // 残留风险-现有控制措施
|
||||
string rData12 = row[12]?.ToString().Trim(); // 残留风险-严重性
|
||||
string rData13 = row[13]?.ToString().Trim(); // 残留风险-可能性
|
||||
string rData14 = row[14]?.ToString().Trim(); // 残留风险-得分
|
||||
string rData15 = row[15]?.ToString().Trim(); // 残留风险-风险级别
|
||||
string rData16 = row[16]?.ToString().Trim(); // 残留风险-可接受
|
||||
string rData17 = row[17]?.ToString().Trim(); // 新增或变更的控制措施
|
||||
string rData18 = row[18]?.ToString().Trim(); // 责任部门
|
||||
string rData5 = row[5]?.ToString().Trim(); // 事故分类
|
||||
string rData6 = row[6]?.ToString().Trim(); // 违法
|
||||
string rData7 = row[7]?.ToString().Trim(); // 固有风险-严重性
|
||||
string rData8 = row[8]?.ToString().Trim(); // 固有风险-可能性
|
||||
string rData9 = row[9]?.ToString().Trim(); // 固有风险-得分
|
||||
string rData10 = row[10]?.ToString().Trim(); // 固有风险-风险级别
|
||||
string rData11 = row[11]?.ToString().Trim(); // 固有风险-可接受
|
||||
string rData12 = row[12]?.ToString().Trim(); // 残留风险-现有控制措施
|
||||
string rData13 = row[13]?.ToString().Trim(); // 残留风险-严重性
|
||||
string rData14 = row[14]?.ToString().Trim(); // 残留风险-可能性
|
||||
string rData15 = row[15]?.ToString().Trim(); // 残留风险-得分
|
||||
string rData16 = row[16]?.ToString().Trim(); // 残留风险-风险级别
|
||||
string rData17 = row[17]?.ToString().Trim(); // 残留风险-可接受
|
||||
string rData18 = row[18]?.ToString().Trim(); // 新增或变更的控制措施
|
||||
string rData19 = row[19]?.ToString().Trim(); // 责任部门
|
||||
|
||||
rData17 = rData17 == "无" ? string.Empty : rData17;
|
||||
rData18 = rData18 == "无" ? string.Empty : rData18;
|
||||
|
||||
string Year = string.Empty;
|
||||
string Month = string.Empty;
|
||||
@@ -292,6 +294,7 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
string JobStep = string.Empty;
|
||||
string Hazard = string.Empty;
|
||||
string Consequence = string.Empty;
|
||||
string AccidentType = string.Empty;
|
||||
bool Illegality = false;
|
||||
int BaseRiskSeverity = 0;
|
||||
int BaseRiskProbability = 0;
|
||||
@@ -351,16 +354,32 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
}
|
||||
if (!string.IsNullOrEmpty(rData4))
|
||||
{
|
||||
Consequence = rData4;
|
||||
//Consequence = rData4;
|
||||
if (!validConsequenceStrings.Any(x => x == rData4))
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "主要后果", Reason = "只能是[人员伤亡/财产损失/环境破坏/公司声誉]!" });
|
||||
}
|
||||
else
|
||||
{
|
||||
Consequence = rData4;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "主要后果", Reason = "不能为空" });
|
||||
}
|
||||
Illegality = !string.IsNullOrEmpty(rData5) && rData5 == "是";
|
||||
if (!string.IsNullOrEmpty(rData6))
|
||||
if (!string.IsNullOrEmpty(rData5))
|
||||
{
|
||||
if (!int.TryParse(rData6, out int ct))
|
||||
AccidentType = rData5;
|
||||
}
|
||||
else
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "事故分类", Reason = "不能为空" });
|
||||
}
|
||||
Illegality = !string.IsNullOrEmpty(rData6) && rData6 == "是";
|
||||
if (!string.IsNullOrEmpty(rData7))
|
||||
{
|
||||
if (!int.TryParse(rData7, out int ct))
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "固有风险严重性", Reason = "格式错误" });
|
||||
}
|
||||
@@ -369,9 +388,9 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
BaseRiskSeverity = ct;
|
||||
}
|
||||
}
|
||||
if (!string.IsNullOrEmpty(rData7))
|
||||
if (!string.IsNullOrEmpty(rData8))
|
||||
{
|
||||
if (!int.TryParse(rData7, out int ct))
|
||||
if (!int.TryParse(rData8, out int ct))
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "固有风险可能性", Reason = "格式错误" });
|
||||
}
|
||||
@@ -386,19 +405,19 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
{
|
||||
BaseRiskLevel = baseRiskLevel.RiskLevelName;
|
||||
}
|
||||
BaseRiskAcceptabity = !string.IsNullOrEmpty(rData10) && rData10 == "否" ? false : true;
|
||||
if (!string.IsNullOrEmpty(rData11))
|
||||
BaseRiskAcceptabity = !string.IsNullOrEmpty(rData11) && rData11 == "否" ? false : true;
|
||||
if (!string.IsNullOrEmpty(rData12))
|
||||
{
|
||||
NetRiskControlMeasures = rData11;
|
||||
NetRiskControlMeasures = rData12;
|
||||
}
|
||||
else
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "现有控制措施", Reason = "不能为空" });
|
||||
}
|
||||
|
||||
if (!string.IsNullOrEmpty(rData12))
|
||||
if (!string.IsNullOrEmpty(rData13))
|
||||
{
|
||||
if (!int.TryParse(rData12, out int ct))
|
||||
if (!int.TryParse(rData13, out int ct))
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "残留风险严重性", Reason = "格式错误" });
|
||||
}
|
||||
@@ -407,9 +426,9 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
NetRiskSeverity = ct;
|
||||
}
|
||||
}
|
||||
if (!string.IsNullOrEmpty(rData13))
|
||||
if (!string.IsNullOrEmpty(rData14))
|
||||
{
|
||||
if (!int.TryParse(rData13, out int ct))
|
||||
if (!int.TryParse(rData14, out int ct))
|
||||
{
|
||||
lstError.Add(new ErrorInfo { Row = displayRow, Column = "残留风险可能性", Reason = "格式错误" });
|
||||
}
|
||||
@@ -424,15 +443,15 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
{
|
||||
NetRiskLevel = netRiskLevel.RiskLevelName;
|
||||
}
|
||||
NetRiskAcceptabity = !string.IsNullOrEmpty(rData16) && rData16 == "否" ? false : true;
|
||||
NetRiskAcceptabity = !string.IsNullOrEmpty(rData17) && rData17 == "否" ? false : true;
|
||||
|
||||
if (!string.IsNullOrEmpty(rData17))
|
||||
{
|
||||
AdditionalControlMeasures = rData17;
|
||||
}
|
||||
if (!string.IsNullOrEmpty(rData18))
|
||||
{
|
||||
ResponsibleDepartment = rData18;
|
||||
AdditionalControlMeasures = rData18;
|
||||
}
|
||||
if (!string.IsNullOrEmpty(rData19))
|
||||
{
|
||||
ResponsibleDepartment = rData19;
|
||||
}
|
||||
|
||||
if (lstError.Any())
|
||||
@@ -469,6 +488,7 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
JobStep = JobStep,
|
||||
Hazard = Hazard,
|
||||
Consequence = Consequence,
|
||||
AccidentType = AccidentType,
|
||||
Illegality = Illegality,
|
||||
BaseRiskSeverity = BaseRiskSeverity,
|
||||
BaseRiskProbability = BaseRiskProbability,
|
||||
|
||||
@@ -105,6 +105,8 @@
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="Consequence" DataField="Consequence" SortField="Consequence" FieldType="String" HeaderText="主要后果" TextAlign="Center" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="120px" ColumnID="AccidentType" DataField="AccidentType" SortField="AccidentType" FieldType="String" HeaderText="事故分类" TextAlign="Center" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:CheckBoxField Width="50px" RenderAsStaticField="true" DataField="Illegality" SortField="Illegality" HeaderText="违法" HeaderTextAlign="Center" TextAlign="Center">
|
||||
</f:CheckBoxField>
|
||||
<f:GroupField ColumnID="GroupField2" runat="server" HeaderText="固有风险评价" HeaderTextAlign="Center">
|
||||
|
||||
@@ -65,11 +65,11 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
sb.Append("WITH CTE AS ( ");
|
||||
if (dedupe == "0")
|
||||
{//按月
|
||||
sb.Append("SELECT ROW_NUMBER() OVER (PARTITION BY tba.Year,tba.Month,tba.WorkPlace,tba.JobStep,tba.Hazard,tba.Consequence,tba.Illegality,tba.BaseRiskSeverity,tba.BaseRiskProbability,tba.BaseRiskScore,tba.BaseRiskLevel,tba.BaseRiskAcceptabity,tba.NetRiskControlMeasures,tba.NetRiskSeverity,tba.NetRiskProbability,tba.NetRiskScore,tba.NetRiskLevel,tba.NetRiskAcceptabity,tba.AdditionalControlMeasures ORDER BY CompileDate desc) as rn,tba.* ");
|
||||
sb.Append("SELECT ROW_NUMBER() OVER (PARTITION BY tba.Year,tba.Month,tba.WorkPlace,tba.JobStep,tba.Hazard,tba.Consequence,tba.AccidentType,tba.Illegality,tba.BaseRiskSeverity,tba.BaseRiskProbability,tba.BaseRiskScore,tba.BaseRiskLevel,tba.BaseRiskAcceptabity,tba.NetRiskControlMeasures,tba.NetRiskSeverity,tba.NetRiskProbability,tba.NetRiskScore,tba.NetRiskLevel,tba.NetRiskAcceptabity,tba.AdditionalControlMeasures ORDER BY CompileDate desc) as rn,tba.* ");
|
||||
}
|
||||
else
|
||||
{//按年
|
||||
sb.Append("SELECT ROW_NUMBER() OVER (PARTITION BY tba.Year,tba.WorkPlace,tba.JobStep,tba.Hazard,tba.Consequence,tba.Illegality,tba.BaseRiskSeverity,tba.BaseRiskProbability,tba.BaseRiskScore,tba.BaseRiskLevel,tba.BaseRiskAcceptabity,tba.NetRiskControlMeasures,tba.NetRiskSeverity,tba.NetRiskProbability,tba.NetRiskScore,tba.NetRiskLevel,tba.NetRiskAcceptabity,tba.AdditionalControlMeasures ORDER BY CompileDate desc) as rn,tba.* ");
|
||||
sb.Append("SELECT ROW_NUMBER() OVER (PARTITION BY tba.Year,tba.WorkPlace,tba.JobStep,tba.Hazard,tba.Consequence,tba.AccidentType,tba.Illegality,tba.BaseRiskSeverity,tba.BaseRiskProbability,tba.BaseRiskScore,tba.BaseRiskLevel,tba.BaseRiskAcceptabity,tba.NetRiskControlMeasures,tba.NetRiskSeverity,tba.NetRiskProbability,tba.NetRiskScore,tba.NetRiskLevel,tba.NetRiskAcceptabity,tba.AdditionalControlMeasures ORDER BY CompileDate desc) as rn,tba.* ");
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
@@ -45,7 +45,19 @@
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtConsequence" runat="server" Label="主要后果" Readonly="true" MaxLength="20" ShowRedStar="true" Required="true">
|
||||
<%--<f:TextBox ID="txtConsequence" runat="server" Label="主要后果" Readonly="true" MaxLength="20" ShowRedStar="true" Required="true">
|
||||
</f:TextBox>--%>
|
||||
<f:RadioButtonList ID="rblConsequence" runat="server" Label="主要后果" LabelAlign="Right" Required="True" ShowRedStar="True" Readonly="true">
|
||||
<f:RadioItem Value="人员伤亡" Text="人员伤亡" />
|
||||
<f:RadioItem Value="财产损失" Text="财产损失" />
|
||||
<f:RadioItem Value="环境破坏" Text="环境破坏" />
|
||||
<f:RadioItem Value="公司声誉" Text="公司声誉" />
|
||||
</f:RadioButtonList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtAccidentType" runat="server" Label="事故分类" Readonly="true" MaxLength="20" ShowRedStar="true" Required="true">
|
||||
</f:TextBox>
|
||||
<f:RadioButtonList ID="rblIllegality" runat="server" Label="违法" LabelAlign="Right" Required="True" ShowRedStar="True" Readonly="true">
|
||||
<f:RadioItem Value="1" Text="是" />
|
||||
@@ -53,6 +65,12 @@
|
||||
</f:RadioButtonList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtNetRiskControlMeasures" runat="server" Label="现有控制措施" Readonly="true" LabelAlign="Right" MaxLength="500" Height="80px" ShowRedStar="true" Required="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:Panel ID="Panel1" Title="" BodyPadding="5px" runat="server" ShowHeader="false" EnableCollapse="True" AutoScroll="true">
|
||||
@@ -96,12 +114,6 @@
|
||||
<Items>
|
||||
<f:Form ID="Form4" ShowBorder="false" ShowHeader="false" runat="server">
|
||||
<Rows>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtNetRiskControlMeasures" runat="server" Label="现有控制措施" Readonly="true" LabelAlign="Right" MaxLength="500" Height="80px" ShowRedStar="true" Required="true">
|
||||
</f:TextArea>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:NumberBox ID="txtNetRiskSeverity" runat="server" Label="严重性" Readonly="true" LabelAlign="Right" NoDecimal="true" NoNegative="true" EmptyText="0" ShowRedStar="true" Required="true">
|
||||
|
||||
@@ -62,7 +62,9 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
this.txtWorkPlace.Text = model.WorkPlace;
|
||||
this.txtJobStep.Text = model.JobStep;
|
||||
this.txtHazard.Text = model.Hazard;
|
||||
this.txtConsequence.Text = model.Consequence;
|
||||
//this.txtConsequence.Text = model.Consequence;
|
||||
this.rblConsequence.SelectedValue = model.Consequence;
|
||||
this.txtAccidentType.Text = model.AccidentType;
|
||||
this.rblIllegality.SelectedValue = model.Illegality ? "1" : "0";
|
||||
this.txtBaseRiskSeverity.Text = model.BaseRiskSeverity.ToString();
|
||||
this.txtBaseRiskProbability.Text = model.BaseRiskProbability.ToString();
|
||||
|
||||
+20
-11
@@ -105,13 +105,22 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
protected global::FineUIPro.TextArea txtHazard;
|
||||
|
||||
/// <summary>
|
||||
/// txtConsequence 控件。
|
||||
/// rblConsequence 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtConsequence;
|
||||
protected global::FineUIPro.RadioButtonList rblConsequence;
|
||||
|
||||
/// <summary>
|
||||
/// txtAccidentType 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtAccidentType;
|
||||
|
||||
/// <summary>
|
||||
/// rblIllegality 控件。
|
||||
@@ -122,6 +131,15 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.RadioButtonList rblIllegality;
|
||||
|
||||
/// <summary>
|
||||
/// txtNetRiskControlMeasures 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtNetRiskControlMeasures;
|
||||
|
||||
/// <summary>
|
||||
/// Panel1 控件。
|
||||
/// </summary>
|
||||
@@ -221,15 +239,6 @@ namespace FineUIPro.Web.ReportManage.HazardFactor
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Form Form4;
|
||||
|
||||
/// <summary>
|
||||
/// txtNetRiskControlMeasures 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextArea txtNetRiskControlMeasures;
|
||||
|
||||
/// <summary>
|
||||
/// txtNetRiskSeverity 控件。
|
||||
/// </summary>
|
||||
|
||||
+50
-2
@@ -88199,7 +88199,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UnitName", DbType="NVarChar(50)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UnitName", DbType="NVarChar(200)")]
|
||||
public string UnitName
|
||||
{
|
||||
get
|
||||
@@ -88239,7 +88239,7 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectName", DbType="NVarChar(50)")]
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectName", DbType="NVarChar(200)")]
|
||||
public string ProjectName
|
||||
{
|
||||
get
|
||||
@@ -171049,6 +171049,8 @@ namespace Model
|
||||
|
||||
private string _UnitProjectName;
|
||||
|
||||
private string _AccidentType;
|
||||
|
||||
#region 可扩展性方法定义
|
||||
partial void OnLoaded();
|
||||
partial void OnValidate(System.Data.Linq.ChangeAction action);
|
||||
@@ -171109,6 +171111,8 @@ namespace Model
|
||||
partial void OnUnitIdChanged();
|
||||
partial void OnUnitProjectNameChanging(string value);
|
||||
partial void OnUnitProjectNameChanged();
|
||||
partial void OnAccidentTypeChanging(string value);
|
||||
partial void OnAccidentTypeChanged();
|
||||
#endregion
|
||||
|
||||
public HazardFactor_OccHealth()
|
||||
@@ -171676,6 +171680,26 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AccidentType", DbType="NVarChar(200)")]
|
||||
public string AccidentType
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._AccidentType;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._AccidentType != value))
|
||||
{
|
||||
this.OnAccidentTypeChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._AccidentType = value;
|
||||
this.SendPropertyChanged("AccidentType");
|
||||
this.OnAccidentTypeChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public event PropertyChangingEventHandler PropertyChanging;
|
||||
|
||||
public event PropertyChangedEventHandler PropertyChanged;
|
||||
@@ -171759,6 +171783,8 @@ namespace Model
|
||||
|
||||
private string _UnitProjectName;
|
||||
|
||||
private string _AccidentType;
|
||||
|
||||
#region 可扩展性方法定义
|
||||
partial void OnLoaded();
|
||||
partial void OnValidate(System.Data.Linq.ChangeAction action);
|
||||
@@ -171819,6 +171845,8 @@ namespace Model
|
||||
partial void OnUnitIdChanged();
|
||||
partial void OnUnitProjectNameChanging(string value);
|
||||
partial void OnUnitProjectNameChanged();
|
||||
partial void OnAccidentTypeChanging(string value);
|
||||
partial void OnAccidentTypeChanged();
|
||||
#endregion
|
||||
|
||||
public HazardFactor_Safety()
|
||||
@@ -172386,6 +172414,26 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AccidentType", DbType="NVarChar(200)")]
|
||||
public string AccidentType
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._AccidentType;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._AccidentType != value))
|
||||
{
|
||||
this.OnAccidentTypeChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._AccidentType = value;
|
||||
this.SendPropertyChanged("AccidentType");
|
||||
this.OnAccidentTypeChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public event PropertyChangingEventHandler PropertyChanging;
|
||||
|
||||
public event PropertyChangedEventHandler PropertyChanged;
|
||||
|
||||
Reference in New Issue
Block a user