葛恒:奖惩
This commit is contained in:
@@ -33,7 +33,14 @@
|
||||
</f:DropDownList>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:DropDownList runat="server" EnableSimulateTree="True" Label="处罚人" ID="drpPunishPerson">
|
||||
</f:DropDownList>
|
||||
<f:Label ID="lblBottom" runat="server" Text="说明:当选择了处罚人,会关联到奖罚管理中。">
|
||||
</f:Label>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextArea ID="txtRegisterDef" runat="server" Label="隐患内容" ShowRedStar="true" Required="true">
|
||||
|
||||
@@ -83,7 +83,7 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
|
||||
Type = Request.Params["Type"];
|
||||
|
||||
this.btnClose.OnClientClick = ActiveWindow.GetHideReference();
|
||||
|
||||
|
||||
ConstValue.InitConstValueDropDownList(drpHiddenType, "Hiddendangertype", false);
|
||||
|
||||
UnitService.InitUnitByProjectIdUnitTypeDropDownList(this.drpUnit, this.CurrUser.LoginProjectId, Const.ProjectUnitType_2, true);
|
||||
@@ -126,7 +126,13 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
|
||||
this.drpResponsibleMan.DataBind();
|
||||
this.drpWorkArea.SelectedValue = BLL.Const._Null;
|
||||
this.drpResponsibleMan.SelectedValue = BLL.Const._Null;
|
||||
BLL.PersonService.InitPersonByProjectUnitDropDownList(this.drpPunishPerson, this.CurrUser.LoginProjectId, registration.ResponsibleUnit, false);//添加人员下拉
|
||||
}
|
||||
if (!string.IsNullOrEmpty(registration.PunishPerson))
|
||||
{
|
||||
this.drpPunishPerson.SelectedValue = registration.PunishPerson;
|
||||
}
|
||||
|
||||
this.txtRequirements.Text = registration.Requirements;
|
||||
if (!string.IsNullOrEmpty(registration.Place))
|
||||
{
|
||||
@@ -194,6 +200,7 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
|
||||
where y.ProjectId == this.CurrUser.LoginProjectId && x.UnitId == this.drpUnit.SelectedValue
|
||||
select x;
|
||||
this.drpResponsibleMan.DataBind();
|
||||
BLL.PersonService.InitPersonByProjectUnitDropDownList(this.drpPunishPerson, this.CurrUser.LoginProjectId, this.drpUnit.SelectedValue, false);//添加人员下拉
|
||||
}
|
||||
Funs.FineUIPleaseSelect(this.drpWorkArea);
|
||||
Funs.FineUIPleaseSelect(this.drpResponsibleMan);
|
||||
@@ -249,8 +256,8 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
|
||||
register.CheckCycle = this.ckType.SelectedValue;
|
||||
register.Risk_Level = this.dpRiskLevel.SelectedText;
|
||||
register.IsEffective = "1";
|
||||
var RegisterTypesDt =BLL.HSSE_Hazard_HazardRegisterTypesService.GetTitleByRegisterTypesId(register.RegisterTypesId);
|
||||
if (RegisterTypesDt != null && RegisterTypesDt .HazardRegisterType=="4")
|
||||
var RegisterTypesDt = BLL.HSSE_Hazard_HazardRegisterTypesService.GetTitleByRegisterTypesId(register.RegisterTypesId);
|
||||
if (RegisterTypesDt != null && RegisterTypesDt.HazardRegisterType == "4")
|
||||
{
|
||||
register.Type = 1; //常规巡检
|
||||
|
||||
@@ -259,6 +266,10 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
|
||||
{
|
||||
register.Type = 0; //日常巡检
|
||||
}
|
||||
if (this.drpPunishPerson.SelectedValue != BLL.Const._Null)
|
||||
{
|
||||
register.PunishPerson = this.drpPunishPerson.SelectedValue;
|
||||
}
|
||||
if (this.drpUnit.SelectedValue != BLL.Const._Null)
|
||||
{
|
||||
register.ResponsibleUnit = this.drpUnit.SelectedValue;
|
||||
|
||||
+18
@@ -59,6 +59,24 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList drpWorkArea;
|
||||
|
||||
/// <summary>
|
||||
/// drpPunishPerson 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.DropDownList drpPunishPerson;
|
||||
|
||||
/// <summary>
|
||||
/// lblBottom 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label lblBottom;
|
||||
|
||||
/// <summary>
|
||||
/// txtRegisterDef 控件。
|
||||
/// </summary>
|
||||
|
||||
@@ -29,7 +29,13 @@
|
||||
</f:TextBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtPunishPersonName" runat="server" Label="处罚人" Readonly="true">
|
||||
</f:TextBox>
|
||||
<f:Label runat="server" CssStyle="display:none"></f:Label>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtRiskLevel" runat="server" Label="隐患级别" Readonly="true">
|
||||
|
||||
@@ -74,7 +74,8 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
|
||||
this.txtUnitName.Text = registration.ResponsibilityUnitName;
|
||||
this.txtWorkAreaName.Text = registration.WorkAreaName;
|
||||
this.txtRegisterTypesName.Text = registration.RegisterTypesName;
|
||||
this.txtRequirements.Text = registration.Requirements;
|
||||
this.txtRequirements.Text = registration.Requirements;
|
||||
this.txtPunishPersonName.Text = registration.PunishPersonName;
|
||||
if (registration.CheckCycle == "D")
|
||||
{
|
||||
this.txtType.Text = "日检";
|
||||
@@ -156,6 +157,44 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
|
||||
if (this.ckConfirm.SelectedValue == "True") //通过
|
||||
{
|
||||
register.States = "3"; //已闭环
|
||||
if (!string.IsNullOrEmpty(register.CheckItemDetailId))
|
||||
{
|
||||
var checkSpecialDetail = Check_CheckSpecialDetailService.GetCheckSpecialDetailByCheckSpecialDetailId(register.CheckItemDetailId);
|
||||
if (checkSpecialDetail != null)
|
||||
{
|
||||
checkSpecialDetail.CompleteStatus = true;
|
||||
Check_CheckSpecialDetailService.UpdateCheckSpecialDetail(checkSpecialDetail);
|
||||
var checkSpecialDetails = Check_CheckSpecialDetailService.GetCheckSpecialDetailByCheckSpecialId(checkSpecialDetail.CheckSpecialId);
|
||||
var getDails = checkSpecialDetails.Where(x => x.CompleteStatus == false);
|
||||
if (getDails.Count() == 0)
|
||||
{
|
||||
var checkSpecial = Check_CheckSpecialService.GetCheckSpecialByCheckSpecialId(checkSpecialDetail.CheckSpecialId);
|
||||
checkSpecial.States = Const.State_2;
|
||||
Check_CheckSpecialService.UpdateCheckSpecial(checkSpecial);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
//确认的时候把数据添加到奖惩管理表
|
||||
if (!string.IsNullOrEmpty(register.PunishPerson))
|
||||
{
|
||||
Model.Check_RewardAndPunish RewardAndPunish = new Model.Check_RewardAndPunish();
|
||||
RewardAndPunish.RewardAndPunishID = SQLHelper.GetNewID(typeof(Model.Check_RewardAndPunish));
|
||||
RewardAndPunish.ProjectId = this.CurrUser.LoginProjectId;
|
||||
RewardAndPunish.Type = 2;
|
||||
RewardAndPunish.ResponseUnit = register.ResponsibleUnit;
|
||||
RewardAndPunish.Date = register.CheckTime;
|
||||
RewardAndPunish.Description = register.RegisterDef;
|
||||
RewardAndPunish.CreateMan = register.CheckManId;
|
||||
RewardAndPunish.RewardAndPunishCode = BLL.SQLHelper.RunProcNewId("SpGetNewCode5",
|
||||
"Check_RewardAndPunish", "RewardAndPunishCode", $"CF");
|
||||
RewardAndPunish.RewardAndPunishMan = register.PunishPerson;
|
||||
RewardAndPunish.TeamGroupId = BLL.PersonService.GetPersonById(register.PunishPerson).TeamGroupId;
|
||||
RewardAndPunish.DataSource = "1";
|
||||
RewardAndPunish.SysTemType = "1";
|
||||
RewardAndPunish.HazardRegisterId = register.HazardRegisterId;
|
||||
BLL.RewardAndPunishService.AddRewardAndPunish(RewardAndPunish);
|
||||
}
|
||||
}
|
||||
else //未通过
|
||||
{
|
||||
|
||||
+9
@@ -77,6 +77,15 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtWorkAreaName;
|
||||
|
||||
/// <summary>
|
||||
/// txtPunishPersonName 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtPunishPersonName;
|
||||
|
||||
/// <summary>
|
||||
/// txtRiskLevel 控件。
|
||||
/// </summary>
|
||||
|
||||
@@ -120,6 +120,9 @@
|
||||
SortField="ResponsibilityManName" FieldType="String" HeaderText="责任人" TextAlign="Center"
|
||||
HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="90px" ColumnID="PunishPersonName" DataField="PunishPersonName" SortField="PunishPersonName"
|
||||
FieldType="String" HeaderText="处罚人" TextAlign="Left" HeaderTextAlign="Center">
|
||||
</f:RenderField>
|
||||
<f:RenderField Width="150px" ColumnID="RectificationPeriod" DataField="RectificationPeriod"
|
||||
SortField="RectificationPeriod" FieldType="Date" Renderer="Date" HeaderText="整改期限"
|
||||
TextAlign="Center" HeaderTextAlign="Center">
|
||||
|
||||
@@ -525,6 +525,7 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
||||
#region 删除
|
||||
/// <summary>
|
||||
/// 右键删除事件
|
||||
@@ -560,6 +561,8 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
|
||||
else
|
||||
{
|
||||
BLL.HSSE_Hazard_HazardRegisterService.DeleteHazardRegisterByHazardRegisterId(rowID);
|
||||
//删除奖罚管理数据
|
||||
BLL.RewardAndPunishService.DeleteRewardAndPunishByHazardRegisterId(rowID);
|
||||
}
|
||||
//}
|
||||
//else
|
||||
@@ -579,7 +582,6 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region 格式化字符串
|
||||
|
||||
@@ -28,8 +28,13 @@
|
||||
<f:TextBox ID="txtWorkAreaName" runat="server" Label="单位工程" Readonly="true">
|
||||
</f:TextBox>
|
||||
</Items>
|
||||
</f:FormRow><f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtPunishPersonName" runat="server" Label="处罚人" Readonly="true">
|
||||
</f:TextBox>
|
||||
<f:Label runat="server" CssStyle="display:none"></f:Label>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtRiskLevel" runat="server" Label="隐患级别" Readonly="true">
|
||||
|
||||
@@ -79,6 +79,7 @@ namespace FineUIPro.Web.HiddenInspection
|
||||
this.txtWorkAreaName.Text = registration.WorkAreaName;
|
||||
this.txtRegisterTypesName.Text = registration.RegisterTypesName;
|
||||
this.txtRequirements.Text = registration.Requirements;
|
||||
this.txtPunishPersonName.Text = registration.PunishPersonName;
|
||||
if (registration.CheckCycle == "D")
|
||||
{
|
||||
this.txtType.Text = "日检";
|
||||
|
||||
+9
@@ -77,6 +77,15 @@ namespace FineUIPro.Web.HiddenInspection
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtWorkAreaName;
|
||||
|
||||
/// <summary>
|
||||
/// txtPunishPersonName 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtPunishPersonName;
|
||||
|
||||
/// <summary>
|
||||
/// txtRiskLevel 控件。
|
||||
/// </summary>
|
||||
|
||||
@@ -21,6 +21,13 @@
|
||||
</f:TextBox>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtPunishPersonName" runat="server" Label="处罚人" Readonly="true">
|
||||
</f:TextBox>
|
||||
<f:Label runat="server" CssStyle="display:none"></f:Label>
|
||||
</Items>
|
||||
</f:FormRow>
|
||||
<f:FormRow>
|
||||
<Items>
|
||||
<f:TextBox ID="txtRegisterTypesName" runat="server" Label="检查项" Readonly="true">
|
||||
|
||||
@@ -75,6 +75,7 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
|
||||
this.txtResponsibilityUnitName.Text = registration.ResponsibilityUnitName;
|
||||
this.txtRegisterTypesName.Text = registration.RegisterTypesName;
|
||||
this.txtRequirements.Text = registration.Requirements;
|
||||
this.txtPunishPersonName.Text = registration.PunishPersonName;
|
||||
this.txtProblemDescription.Text = registration.RegisterDef;
|
||||
this.txtTakeSteps.Text = registration.Rectification;
|
||||
this.txtResponsibilityManName.Text = registration.ResponsibilityManName;
|
||||
|
||||
+9
@@ -59,6 +59,15 @@ namespace FineUIPro.Web.HSSE.HiddenInspection
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtResponsibilityUnitName;
|
||||
|
||||
/// <summary>
|
||||
/// txtPunishPersonName 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.TextBox txtPunishPersonName;
|
||||
|
||||
/// <summary>
|
||||
/// txtRegisterTypesName 控件。
|
||||
/// </summary>
|
||||
|
||||
Reference in New Issue
Block a user