This commit is contained in:
2023-03-14 16:07:07 +08:00
12 changed files with 65 additions and 16 deletions
@@ -0,0 +1,2 @@
alter table RewardAndPunish_RewardAndPunish add RewardAndPunishDecision nvarchar(200) null
GO
@@ -38,6 +38,7 @@ namespace BLL
Type = RewardAndPunish.Type, Type = RewardAndPunish.Type,
RewardAndPunishTypeId = RewardAndPunish.RewardAndPunishTypeId, RewardAndPunishTypeId = RewardAndPunish.RewardAndPunishTypeId,
RewardAndPunishBasis = RewardAndPunish.RewardAndPunishBasis, RewardAndPunishBasis = RewardAndPunish.RewardAndPunishBasis,
RewardAndPunishDecision = RewardAndPunish.RewardAndPunishDecision,
State = RewardAndPunish.State, State = RewardAndPunish.State,
CompileMan = RewardAndPunish.CompileMan, CompileMan = RewardAndPunish.CompileMan,
CompileDate = RewardAndPunish.CompileDate, CompileDate = RewardAndPunish.CompileDate,
@@ -61,6 +62,7 @@ namespace BLL
newRewardAndPunish.Type = RewardAndPunish.Type; newRewardAndPunish.Type = RewardAndPunish.Type;
newRewardAndPunish.RewardAndPunishTypeId = RewardAndPunish.RewardAndPunishTypeId; newRewardAndPunish.RewardAndPunishTypeId = RewardAndPunish.RewardAndPunishTypeId;
newRewardAndPunish.RewardAndPunishBasis = RewardAndPunish.RewardAndPunishBasis; newRewardAndPunish.RewardAndPunishBasis = RewardAndPunish.RewardAndPunishBasis;
newRewardAndPunish.RewardAndPunishDecision = RewardAndPunish.RewardAndPunishDecision;
newRewardAndPunish.State = RewardAndPunish.State; newRewardAndPunish.State = RewardAndPunish.State;
db.SubmitChanges(); db.SubmitChanges();
@@ -27,7 +27,7 @@ namespace FineUIPro.Web.BaseInfo
{ {
this.btnSave.Hidden = true; this.btnSave.Hidden = true;
} }
CompanyModelKindService.InitCompanyModelKindDownList(this.drpCompanyModelKindId,true); CompanyModelKindService.InitCompanyModelKindDownList(this.drpCompanyModelKindId, true);
this.drpCompanyModelKindId.SelectedValue = BLL.Const._Null; this.drpCompanyModelKindId.SelectedValue = BLL.Const._Null;
if (!string.IsNullOrEmpty(id)) if (!string.IsNullOrEmpty(id))
{ {
@@ -106,6 +106,18 @@ namespace FineUIPro.Web.BaseInfo
this.hdId.Text = newCompanyModel.CompanyModelId; this.hdId.Text = newCompanyModel.CompanyModelId;
} }
BLL.CompanyModelService.AddCompanyModel(newCompanyModel); BLL.CompanyModelService.AddCompanyModel(newCompanyModel);
var projects = from x in Funs.DB.Base_Project select x;
foreach (var item in projects)
{
Model.Model_QualityModel newQualityModel = new Model.Model_QualityModel();
newQualityModel.ProjectId = item.ProjectId;
newQualityModel.CompanyModelId = newCompanyModel.CompanyModelId;
newQualityModel.Remark = this.txtRemark.Text.Trim();
newQualityModel.QualityModelId = SQLHelper.GetNewID();
newQualityModel.CompileMan = this.CurrUser.PersonId;
newQualityModel.CompileDate = DateTime.Now;
BLL.QualityModelService.AddQualityModel(newQualityModel);
}
} }
ShowNotify("保存成功!", MessageBoxIcon.Success); ShowNotify("保存成功!", MessageBoxIcon.Success);
PageContext.RegisterStartupScript(ActiveWindow.GetHidePostBackReference()); PageContext.RegisterStartupScript(ActiveWindow.GetHidePostBackReference());
@@ -49,7 +49,7 @@
<f:FormRow> <f:FormRow>
<Items> <Items>
<f:TextBox ID="txtProjectName" runat="server" Readonly="true" LabelWidth="110px" Label="项目名称" LabelAlign="Right" <f:TextBox ID="txtProjectName" runat="server" Readonly="true" LabelWidth="110px" Label="项目名称" LabelAlign="Right"
MaxLength="50"> >
</f:TextBox> </f:TextBox>
<f:TextBox ID="txtDocCode" runat="server" Required="true" ShowRedStar="true" Label="编号" LabelAlign="Right" <f:TextBox ID="txtDocCode" runat="server" Required="true" ShowRedStar="true" Label="编号" LabelAlign="Right"
MaxLength="50"> MaxLength="50">
@@ -49,7 +49,7 @@
<f:FormRow> <f:FormRow>
<Items> <Items>
<f:TextBox ID="txtProjectName" runat="server" Readonly="true" LabelWidth="110px" Label="项目名称" LabelAlign="Right" <f:TextBox ID="txtProjectName" runat="server" Readonly="true" LabelWidth="110px" Label="项目名称" LabelAlign="Right"
MaxLength="50"> >
</f:TextBox> </f:TextBox>
<f:TextBox ID="txtDocCode" runat="server" Required="true" ShowRedStar="true" Label="编号" LabelAlign="Right" <f:TextBox ID="txtDocCode" runat="server" Required="true" ShowRedStar="true" Label="编号" LabelAlign="Right"
MaxLength="50"> MaxLength="50">
@@ -44,7 +44,7 @@
<f:FormRow> <f:FormRow>
<Items> <Items>
<f:TextBox ID="txtProjectName" runat="server" Readonly="true" Label="项目名称" LabelAlign="Right" <f:TextBox ID="txtProjectName" runat="server" Readonly="true" Label="项目名称" LabelAlign="Right"
MaxLength="50"> >
</f:TextBox> </f:TextBox>
<f:TextBox ID="txtCode" runat="server" Required="true" ShowRedStar="true" Label="编号" LabelAlign="Right" <f:TextBox ID="txtCode" runat="server" Required="true" ShowRedStar="true" Label="编号" LabelAlign="Right"
MaxLength="50"> MaxLength="50">
@@ -51,7 +51,7 @@ namespace FineUIPro.Web.CQMS.RewardAndPunish
protected DataTable insklistData() protected DataTable insklistData()
{ {
string strSql = @"SELECT ins.*,un.UnitName,u.PersonName as CompileManName,case ins.Type when '1' then '奖励' else '处罚' end as TypeStr,case ins.Type when '1' then rt.RewardCause else pt.PunishCause end as Cause,case ins.Type when '1' then rt.RewardDecision else pt.PunishDecision end as Decision" string strSql = @"SELECT ins.*,un.UnitName,u.PersonName as CompileManName,case ins.Type when '1' then '奖励' else '处罚' end as TypeStr,case ins.Type when '1' then rt.RewardCause else pt.PunishCause end as Cause,ins.RewardAndPunishDecision as Decision"
+ @" FROM RewardAndPunish_RewardAndPunish ins" + @" FROM RewardAndPunish_RewardAndPunish ins"
+ @" left join Base_Unit un on un.UnitId = ins.UnitId" + @" left join Base_Unit un on un.UnitId = ins.UnitId"
+ @" left join Base_RewardType rt on rt.RewardTypeId = ins.RewardAndPunishTypeId" + @" left join Base_RewardType rt on rt.RewardTypeId = ins.RewardAndPunishTypeId"
@@ -64,7 +64,7 @@
</f:FormRow> </f:FormRow>
<f:FormRow> <f:FormRow>
<Items> <Items>
<f:TextBox ID="txtRewardAndPunishDecision" runat="server" Label="奖罚决定" ShowRedStar="true" Required="true" Readonly="true" <f:TextBox ID="txtRewardAndPunishDecision" runat="server" Label="奖罚决定" ShowRedStar="true" Required="true"
MaxLength="200" LabelWidth="100px"> MaxLength="200" LabelWidth="100px">
</f:TextBox> </f:TextBox>
</Items> </Items>
@@ -80,6 +80,10 @@ namespace FineUIPro.Web.CQMS.RewardAndPunish
drpRewardAndPunishType.SelectedValue = RewardAndPunish.RewardAndPunishTypeId; drpRewardAndPunishType.SelectedValue = RewardAndPunish.RewardAndPunishTypeId;
drpRewardAndPunishType_SelectedIndexChanged(null, null); drpRewardAndPunishType_SelectedIndexChanged(null, null);
} }
if (!string.IsNullOrEmpty(RewardAndPunish.RewardAndPunishDecision))
{
this.txtRewardAndPunishDecision.Text = RewardAndPunish.RewardAndPunishDecision;
}
gvApprove.DataSource = BLL.RewardAndPunishApproveService.getListData(this.RewardAndPunishId); gvApprove.DataSource = BLL.RewardAndPunishApproveService.getListData(this.RewardAndPunishId);
gvApprove.DataBind(); gvApprove.DataBind();
if (!string.IsNullOrEmpty(RewardAndPunish.State)) if (!string.IsNullOrEmpty(RewardAndPunish.State))
@@ -295,6 +299,7 @@ namespace FineUIPro.Web.CQMS.RewardAndPunish
RewardAndPunish.Type = this.rblType.SelectedValue; RewardAndPunish.Type = this.rblType.SelectedValue;
RewardAndPunish.RewardAndPunishTypeId = this.drpRewardAndPunishType.SelectedValue; RewardAndPunish.RewardAndPunishTypeId = this.drpRewardAndPunishType.SelectedValue;
RewardAndPunish.RewardAndPunishBasis = this.txtRewardAndPunishBasis.Text.Trim(); RewardAndPunish.RewardAndPunishBasis = this.txtRewardAndPunishBasis.Text.Trim();
RewardAndPunish.RewardAndPunishDecision = this.txtRewardAndPunishDecision.Text.Trim();
if (saveType == "submit") if (saveType == "submit")
{ {
RewardAndPunish.State = this.drpHandleType.SelectedValue; RewardAndPunish.State = this.drpHandleType.SelectedValue;
@@ -76,6 +76,10 @@ namespace FineUIPro.Web.CQMS.RewardAndPunish
drpRewardAndPunishType.SelectedValue = RewardAndPunish.RewardAndPunishTypeId; drpRewardAndPunishType.SelectedValue = RewardAndPunish.RewardAndPunishTypeId;
drpRewardAndPunishType_SelectedIndexChanged(null, null); drpRewardAndPunishType_SelectedIndexChanged(null, null);
} }
if (!string.IsNullOrEmpty(RewardAndPunish.RewardAndPunishDecision))
{
this.txtRewardAndPunishDecision.Text = RewardAndPunish.RewardAndPunishDecision;
}
gvApprove.DataSource = BLL.RewardAndPunishApproveService.getListData(this.RewardAndPunishId); gvApprove.DataSource = BLL.RewardAndPunishApproveService.getListData(this.RewardAndPunishId);
gvApprove.DataBind(); gvApprove.DataBind();
} }
@@ -45,7 +45,7 @@
<f:FormRow> <f:FormRow>
<Items> <Items>
<f:TextBox ID="txtProjectName" runat="server" Readonly="true" Label="项目名称" LabelAlign="Right" <f:TextBox ID="txtProjectName" runat="server" Readonly="true" Label="项目名称" LabelAlign="Right"
MaxLength="50"> >
</f:TextBox> </f:TextBox>
<f:TextBox ID="txtCode" runat="server" Required="true" ShowRedStar="true" Label="编号" LabelAlign="Right" <f:TextBox ID="txtCode" runat="server" Required="true" ShowRedStar="true" Label="编号" LabelAlign="Right"
MaxLength="50"> MaxLength="50">
+33 -9
View File
@@ -73878,7 +73878,7 @@ namespace Model
OnCreated(); OnCreated();
} }
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialCode", DbType="NVarChar(15) NOT NULL", CanBeNull=false, IsPrimaryKey=true)] [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialCode", DbType="NVarChar(50) NOT NULL", CanBeNull=false, IsPrimaryKey=true)]
public string MaterialCode public string MaterialCode
{ {
get get
@@ -73982,7 +73982,7 @@ namespace Model
} }
} }
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialDef", DbType="NVarChar(3000)")] [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialDef", DbType="NVarChar(MAX)", UpdateCheck=UpdateCheck.Never)]
public string MaterialDef public string MaterialDef
{ {
get get
@@ -78572,7 +78572,7 @@ namespace Model
} }
} }
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialCode", DbType="NVarChar(15)")] [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialCode", DbType="NVarChar(50)")]
public string MaterialCode public string MaterialCode
{ {
get get
@@ -82920,7 +82920,7 @@ namespace Model
} }
} }
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CanWelderCode", DbType="NVarChar(200)")] [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CanWelderCode", DbType="NVarChar(1000)")]
public string CanWelderCode public string CanWelderCode
{ {
get get
@@ -122289,7 +122289,7 @@ namespace Model
} }
} }
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialName", DbType="NVarChar(50)")] [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialName", DbType="NVarChar(100)")]
public string MaterialName public string MaterialName
{ {
get get
@@ -122309,7 +122309,7 @@ namespace Model
} }
} }
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SpecificationAndModel", DbType="NVarChar(50)")] [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_SpecificationAndModel", DbType="NVarChar(200)")]
public string SpecificationAndModel public string SpecificationAndModel
{ {
get get
@@ -122329,7 +122329,7 @@ namespace Model
} }
} }
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialCode", DbType="NVarChar(50)")] [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialCode", DbType="NVarChar(100)")]
public string MaterialCode public string MaterialCode
{ {
get get
@@ -122349,7 +122349,7 @@ namespace Model
} }
} }
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Material", DbType="NVarChar(50)")] [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Material", DbType="NVarChar(100)")]
public string Material public string Material
{ {
get get
@@ -181173,6 +181173,8 @@ namespace Model
private System.Nullable<System.DateTime> _CompileDate; private System.Nullable<System.DateTime> _CompileDate;
private string _RewardAndPunishDecision;
private EntityRef<Base_Project> _Base_Project; private EntityRef<Base_Project> _Base_Project;
private EntitySet<RewardAndPunish_RewardAndPunishApprove> _RewardAndPunish_RewardAndPunishApprove; private EntitySet<RewardAndPunish_RewardAndPunishApprove> _RewardAndPunish_RewardAndPunishApprove;
@@ -181201,6 +181203,8 @@ namespace Model
partial void OnCompileManChanged(); partial void OnCompileManChanged();
partial void OnCompileDateChanging(System.Nullable<System.DateTime> value); partial void OnCompileDateChanging(System.Nullable<System.DateTime> value);
partial void OnCompileDateChanged(); partial void OnCompileDateChanged();
partial void OnRewardAndPunishDecisionChanging(string value);
partial void OnRewardAndPunishDecisionChanged();
#endregion #endregion
public RewardAndPunish_RewardAndPunish() public RewardAndPunish_RewardAndPunish()
@@ -181414,6 +181418,26 @@ namespace Model
} }
} }
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_RewardAndPunishDecision", DbType="NVarChar(100)")]
public string RewardAndPunishDecision
{
get
{
return this._RewardAndPunishDecision;
}
set
{
if ((this._RewardAndPunishDecision != value))
{
this.OnRewardAndPunishDecisionChanging(value);
this.SendPropertyChanging();
this._RewardAndPunishDecision = value;
this.SendPropertyChanged("RewardAndPunishDecision");
this.OnRewardAndPunishDecisionChanged();
}
}
}
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_RewardAndPunish_RewardAndPunish_Base_Project", Storage="_Base_Project", ThisKey="ProjectId", OtherKey="ProjectId", IsForeignKey=true)] [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_RewardAndPunish_RewardAndPunish_Base_Project", Storage="_Base_Project", ThisKey="ProjectId", OtherKey="ProjectId", IsForeignKey=true)]
public Base_Project Base_Project public Base_Project Base_Project
{ {
@@ -235851,7 +235875,7 @@ namespace Model
} }
} }
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CanWelderCode", DbType="NVarChar(200)")] [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CanWelderCode", DbType="NVarChar(1000)")]
public string CanWelderCode public string CanWelderCode
{ {
get get