diff --git a/DataBase/版本日志/SGGLDB_V2023-07-21.sql b/DataBase/版本日志/SGGLDB_V2023-07-21.sql new file mode 100644 index 00000000..8eadd009 --- /dev/null +++ b/DataBase/版本日志/SGGLDB_V2023-07-21.sql @@ -0,0 +1,44 @@ +ALTER VIEW [dbo].[View_InformationProject_ConstructionStandardSelectedItem] +/*׼淶ʶѡбͼ*/ +AS +SELECT Item.ConstructionStandardSelectedItemId, + Item.ConstructionStandardIdentifyId, + Item.StandardId, + Identify.ProjectId, + List.StandardGrade, + List.StandardNo, + List.StandardName, + List.AttachUrl, + List.IsSelected1, + List.IsSelected2, + List.IsSelected3, + List.IsSelected4, + List.IsSelected5, + List.IsSelected6, + List.IsSelected7, + List.IsSelected8, + List.IsSelected9, + List.IsSelected10, + List.IsSelected11, + List.IsSelected12, + List.IsSelected13, + List.IsSelected14, + List.IsSelected15, + List.IsSelected16, + List.IsSelected17, + List.IsSelected18, + List.IsSelected19, + List.IsSelected20, + List.IsSelected21, + List.IsSelected22, + List.IsSelected23, + List.IsSelected90 +FROM dbo.Law_HSSEStandardsList AS List +LEFT JOIN dbo.InformationProject_ConstructionStandardSelectedItem AS Item ON List.StandardId =Item.StandardId +LEFT JOIN dbo.InformationProject_ConstructionStandardIdentify AS Identify ON Item.ConstructionStandardIdentifyId =Identify.ConstructionStandardIdentifyId + + + +GO + + diff --git a/SGGL/FineUIPro.Web/HSSE/InformationProject/ConstructionStandardIdentifyEdit.aspx b/SGGL/FineUIPro.Web/HSSE/InformationProject/ConstructionStandardIdentifyEdit.aspx index 8c1435a4..552dbbcf 100644 --- a/SGGL/FineUIPro.Web/HSSE/InformationProject/ConstructionStandardIdentifyEdit.aspx +++ b/SGGL/FineUIPro.Web/HSSE/InformationProject/ConstructionStandardIdentifyEdit.aspx @@ -10,7 +10,7 @@ 编辑标准规范辨识 - +
@@ -37,9 +37,9 @@ - + - @@ -49,10 +49,10 @@ + EnableColumnLines="true" EnableCheckBoxSelect="true"> diff --git a/SGGL/FineUIPro.Web/HSSE/InformationProject/ConstructionStandardIdentifyEdit.aspx.cs b/SGGL/FineUIPro.Web/HSSE/InformationProject/ConstructionStandardIdentifyEdit.aspx.cs index 2476e4d9..4f4a65d2 100644 --- a/SGGL/FineUIPro.Web/HSSE/InformationProject/ConstructionStandardIdentifyEdit.aspx.cs +++ b/SGGL/FineUIPro.Web/HSSE/InformationProject/ConstructionStandardIdentifyEdit.aspx.cs @@ -143,13 +143,56 @@ namespace FineUIPro.Web.HSSE.InformationProject /// private void BindGrid() { - var q = from x in Funs.DB.View_InformationProject_ConstructionStandardSelectedItem - where x.StandardName != null - select x; - if (!this.ckbAll.Checked) + IQueryable q; + if (this.ckbAll.Checked) { - q = q.Where(e => e.ConstructionStandardIdentifyId == this.ConstructionStandardIdentifyId); + q = from x in Funs.DB.Law_HSSEStandardsList + join y in Funs.DB.InformationProject_ConstructionStandardSelectedItem on x.StandardId equals y.StandardId + join z in Funs.DB.InformationProject_ConstructionStandardIdentify on y.ConstructionStandardIdentifyId equals z.ConstructionStandardIdentifyId + where x.StandardName != null && z.ProjectId == this.CurrUser.LoginProjectId + select new Model.View_InformationProject_ConstructionStandardSelectedItem + { + ConstructionStandardSelectedItemId =y.ConstructionStandardSelectedItemId, + ConstructionStandardIdentifyId = y.ConstructionStandardIdentifyId, + ProjectId = this.CurrUser.LoginProjectId, + StandardId = x.StandardId, + StandardGrade = x.StandardGrade, + StandardNo = x.StandardNo, + StandardName = x.StandardName, + AttachUrl = x.AttachUrl, + IsSelected1 = x.IsSelected1, + IsSelected2 = x.IsSelected2, + IsSelected3 = x.IsSelected3, + IsSelected4 = x.IsSelected4, + IsSelected5 = x.IsSelected5, + IsSelected6 = x.IsSelected6, + IsSelected7 = x.IsSelected7, + IsSelected8 = x.IsSelected8, + IsSelected9 = x.IsSelected9, + IsSelected10 = x.IsSelected10, + IsSelected11 = x.IsSelected11, + IsSelected12 = x.IsSelected12, + IsSelected13 = x.IsSelected13, + IsSelected14 = x.IsSelected14, + IsSelected15 = x.IsSelected15, + IsSelected16 = x.IsSelected16, + IsSelected17 = x.IsSelected17, + IsSelected18 = x.IsSelected18, + IsSelected19 = x.IsSelected19, + IsSelected20 = x.IsSelected20, + IsSelected21 = x.IsSelected21, + IsSelected22 = x.IsSelected22, + IsSelected23 = x.IsSelected23, + IsSelected90 = x.IsSelected90 + }; } + else + { + q = from x in Funs.DB.View_InformationProject_ConstructionStandardSelectedItem + where x.ConstructionStandardIdentifyId == this.ConstructionStandardIdentifyId + select x; + } + if (!string.IsNullOrEmpty(this.txtStandardGrade.Text.Trim())) { q = q.Where(e => e.StandardGrade.Contains(this.txtStandardGrade.Text.Trim())); diff --git a/SGGL/Model/Model.cs b/SGGL/Model/Model.cs index 4577002e..cfb8d5ab 100644 --- a/SGGL/Model/Model.cs +++ b/SGGL/Model/Model.cs @@ -10804,6 +10804,8 @@ namespace Model private EntityRef _Person_Persons; + private EntitySet _ActionPlan_ActionPlanListApprove; + #region 可扩展性方法定义 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -10842,6 +10844,7 @@ namespace Model { this._Base_Project = default(EntityRef); this._Person_Persons = default(EntityRef); + this._ActionPlan_ActionPlanListApprove = new EntitySet(new Action(this.attach_ActionPlan_ActionPlanListApprove), new Action(this.detach_ActionPlan_ActionPlanListApprove)); OnCreated(); } @@ -11201,6 +11204,19 @@ namespace Model } } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_ActionPlan_ActionPlanListApprove_ActionPlan_ActionPlanList", Storage="_ActionPlan_ActionPlanListApprove", ThisKey="ActionPlanListId", OtherKey="ActionPlanListId", DeleteRule="NO ACTION")] + public EntitySet ActionPlan_ActionPlanListApprove + { + get + { + return this._ActionPlan_ActionPlanListApprove; + } + set + { + this._ActionPlan_ActionPlanListApprove.Assign(value); + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -11220,6 +11236,18 @@ namespace Model this.PropertyChanged(this, new PropertyChangedEventArgs(propertyName)); } } + + private void attach_ActionPlan_ActionPlanListApprove(ActionPlan_ActionPlanListApprove entity) + { + this.SendPropertyChanging(); + entity.ActionPlan_ActionPlanList = this; + } + + private void detach_ActionPlan_ActionPlanListApprove(ActionPlan_ActionPlanListApprove entity) + { + this.SendPropertyChanging(); + entity.ActionPlan_ActionPlanList = null; + } } [global::System.Data.Linq.Mapping.TableAttribute(Name="dbo.ActionPlan_ActionPlanListApprove")] @@ -11252,6 +11280,8 @@ namespace Model private System.Nullable _IsPushOa; + private EntityRef _ActionPlan_ActionPlanList; + private EntityRef _Person_Persons; #region 可扩展性方法定义 @@ -11286,6 +11316,7 @@ namespace Model public ActionPlan_ActionPlanListApprove() { + this._ActionPlan_ActionPlanList = default(EntityRef); this._Person_Persons = default(EntityRef); OnCreated(); } @@ -11321,6 +11352,10 @@ namespace Model { if ((this._ActionPlanListId != value)) { + if (this._ActionPlan_ActionPlanList.HasLoadedOrAssignedValue) + { + throw new System.Data.Linq.ForeignKeyReferenceAlreadyHasValueException(); + } this.OnActionPlanListIdChanging(value); this.SendPropertyChanging(); this._ActionPlanListId = value; @@ -11534,6 +11569,40 @@ namespace Model } } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_ActionPlan_ActionPlanListApprove_ActionPlan_ActionPlanList", Storage="_ActionPlan_ActionPlanList", ThisKey="ActionPlanListId", OtherKey="ActionPlanListId", IsForeignKey=true)] + public ActionPlan_ActionPlanList ActionPlan_ActionPlanList + { + get + { + return this._ActionPlan_ActionPlanList.Entity; + } + set + { + ActionPlan_ActionPlanList previousValue = this._ActionPlan_ActionPlanList.Entity; + if (((previousValue != value) + || (this._ActionPlan_ActionPlanList.HasLoadedOrAssignedValue == false))) + { + this.SendPropertyChanging(); + if ((previousValue != null)) + { + this._ActionPlan_ActionPlanList.Entity = null; + previousValue.ActionPlan_ActionPlanListApprove.Remove(this); + } + this._ActionPlan_ActionPlanList.Entity = value; + if ((value != null)) + { + value.ActionPlan_ActionPlanListApprove.Add(this); + this._ActionPlanListId = value.ActionPlanListId; + } + else + { + this._ActionPlanListId = default(string); + } + this.SendPropertyChanged("ActionPlan_ActionPlanList"); + } + } + } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_ActionPlan_ActionPlanListApprove_Person_Persons", Storage="_Person_Persons", ThisKey="ApproveMan", OtherKey="PersonId", IsForeignKey=true)] public Person_Persons Person_Persons { @@ -276119,6 +276188,8 @@ namespace Model private string _StandardId; + private string _ProjectId; + private string _StandardGrade; private string _StandardNo; @@ -276179,7 +276250,7 @@ namespace Model { } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ConstructionStandardSelectedItemId", DbType="NVarChar(50) NOT NULL", CanBeNull=false)] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ConstructionStandardSelectedItemId", DbType="NVarChar(50)")] public string ConstructionStandardSelectedItemId { get @@ -276227,6 +276298,22 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectId", DbType="NVarChar(50)")] + public string ProjectId + { + get + { + return this._ProjectId; + } + set + { + if ((this._ProjectId != value)) + { + this._ProjectId = value; + } + } + } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_StandardGrade", DbType="NChar(12)")] public string StandardGrade {