From bfdffc4ccf29af768ac205564b47234c36840854 Mon Sep 17 00:00:00 2001 From: fei550 <1420031550@qq.com> Date: Wed, 6 Nov 2024 09:36:10 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E7=84=8A=E6=8E=A5=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .vs/SGGL_SeDin_New/v17/.wsuo | Bin 65536 -> 65536 bytes DataBase/版本日志/SGGLDB_V2024-11-06.sql | 3 + .../API/HJGL/APIPipelineComponentService.cs | 14 +- .../WeldingManage/PipelineComponentService.cs | 9 +- .../File/Fastreport/材料出库单.frx | 4 +- .../File/Fastreport/材料出库计划单.frx | 4 +- .../HJGL/PreDesign/PrePipeline.aspx.cs | 2 +- .../HJGL/WeldingManage/WeldMatMatch.aspx | 5 +- .../HJGL/WeldingManage/WeldMatMatch.aspx.cs | 2 +- SGGL/Model/Model.cs | 290 ++++++++++-------- .../HJGL/PipelineComponentController.cs | 4 +- 11 files changed, 192 insertions(+), 145 deletions(-) create mode 100644 DataBase/版本日志/SGGLDB_V2024-11-06.sql diff --git a/.vs/SGGL_SeDin_New/v17/.wsuo b/.vs/SGGL_SeDin_New/v17/.wsuo index e47c8d62b655992a6a90ff4f0ec47f6a89342a4e..aac6161431d64c86e12b00ceec5c95864a8a96d7 100644 GIT binary patch delta 1906 zcmd6ne{54#6vy9rZE08fwlPXAOPSl+XbW^}*R9EWQj5U;XnLAjERykV>Q`4=fNWtV~mkM zyvZl`+;i_a@1F0w_m)c5Qpx(!oG6tR<6lj8eh00BAn15fd=(U27OzQyM2-NlN)5{m z0T{z&OXt8Qa;+uS5p~2?VujaG+er2X!b$MhRWrw9Zf?w3AClQ>quF-CPwfaz%unNbeqvd}gu-$KC zfgRZ9csR6%EK^cD*(`Mf!E&3Dvp9yNKDPc&QXI8O7VZzPr9ccmxSQ-W24iG z0q6O~&YJ330lexQf+4)+To1c()7tM<*Wy2~slV#r18gLxbFJO3UlJXSH6B}>1}?0w zPq}Pl@%c0t!!E7p&WQIV@QlNs5@-eQIZ)k0MtJM};THiLo4Q?`()=ZSzqCU0mwGD2Q6?30V;8e-Z`3O`||ptf%i#A`%TpdlJ!b_e?An?oA|O;n{q5S3VN!?dgu= zoNrv6&{6lvsORK`79G^)idJdb4r+S=9>-$)DcFh2?IRNK^)#<4?*I$_Q5PS&7Q(Dp zyX|*bRnGR{cBTfCSP`SPFn#AVo(w9O3~X0J6$$u=J8Hge<43`%Rm1zh!7q!sD=c)L zLtU}rmE1O?#yc6I1B<~`*n-6n)fc1yzD;J3Z8ImsYG(?sG)G_mxMTY>qwE|`-tG799M_fxdPO@|(jkoCyZvEJ z9+K9eq$Kc+qT;8Dhoo?$oZ5{c(S;XMM>Ku-JuA*D)5e6ZTp;HbETtUiNcW;Xb{5a3 z;{ezuZa`0J^JP5^YFe>8CS-B162rli8_%bgn)V3CzEB22?;lQm@Xe(+(<_S~;%ug) z`LAx;n$hrdX2%0QD|p?vQTuk{Q9yZ0$6FJ32AAanfL~7rFfirAOW78j&X%z?x6Z<1 zRwMG&d^^{NrCbni<|hAB0`2BO@8J9maeiLG{3{;K^YagN dHh%R5&Gzf>fL(c?=KJvms2@8u=WoAQ{s0z2Mfm^# delta 1958 zcmd6o&rcj>7{})w7Ff13uu$3x>~4Ww+VW${%&@Raf9MpJ0=oze&}PwMSaypSjfw7R zYtwfAfF9g=dhlRkvv}yCiOO8;shi-T2cv1yo;=tZQ*U~K7)&jGU%G=UG0`^B_+~#d z&-1)L_MPwhJTs>0GELWKZ-{d7ZS%K}y1r!rK@d#3AYNqSv@U)vGZ}$Ou!%<(&k@4IpU)L-}h#+(cCt-|&F)$9| zAOR-8%U}{rfp@Xpmi&U*_8y$`-~xCbTm+Yav-2mk!QPRthn_*@>R^qda25I8`;R-i zR%2Z^DA)Yib!{x$ouliXQtW@DYscT}$^|Co36j_2qLAmBmuHd#&kMTaiP4(J%f_f} z*LV2^mnD7i4+hoVaXV+n)81aIy(hX`OZxCgB~LPmHkuMr5Z2+cE<4+Lm01ljsRBW7 zSqB@na}6`%j+Gl{*`FiXy_nv*YOgk5Vm&{Lg22xz)HjgQqkU>x(b5rB37<>r%HUE| zQ}o5?lA1mjjYgN~rf-&JlI`@pKj7t6%iEbB9~^!7@hcOQ52$4LP12H0)Ra7E8-XID z>j7iiu-dciB<0$#un}5spOm+%H-sg&M8-2yHh4;F(r>#+bXK?B6M?T($I=REOB!vN(%TPTyo2<@%?j zDs=RebyoJmQSFULwOAMs3&;3x#XHPo)>RtiJRD`~Xa6!iy5lnA<;4s3kHI}tGUFb9 zb#6!35Z&^eGURE-_q{SCiS*S-*fwHCR_4f6Bu_`^%TsshbRtaSGZ88#aGVp9E~=d# z*x5nGbe!V819i7XZXUUx{_vOc{CI>3I+55z*Jkh0jhQ4FKGnOF)>SgPg~IqM^1uDEO@xBX?~RYvC7Pa9JyUDNtgnlc#CbS2y$ zVJQ5D`NP(HU1#zeuCgF3E=II;N>67p`X&BZ;>F1u{}}M5(dTdOu6P|2Z_jtqjrkX> ufMLC6{HyC17KRF+#I0qY?fdlyw(_W1w3~l=R8x5DVwdfF;4NOCAN&q4V{uUc diff --git a/DataBase/版本日志/SGGLDB_V2024-11-06.sql b/DataBase/版本日志/SGGLDB_V2024-11-06.sql new file mode 100644 index 00000000..fa8c6e98 --- /dev/null +++ b/DataBase/版本日志/SGGLDB_V2024-11-06.sql @@ -0,0 +1,3 @@ +alter table dbo.HJGL_Pipeline_Component + add Remark nvarchar(200) +go diff --git a/SGGL/BLL/API/HJGL/APIPipelineComponentService.cs b/SGGL/BLL/API/HJGL/APIPipelineComponentService.cs index 5f1f938c..34858eb9 100644 --- a/SGGL/BLL/API/HJGL/APIPipelineComponentService.cs +++ b/SGGL/BLL/API/HJGL/APIPipelineComponentService.cs @@ -76,14 +76,24 @@ namespace BLL } } - public static void GetComponentConfirmArrival(string PipelineComponentId,string PersonId) + public static void GetComponentConfirmArrival(string PipelineComponentId,string PersonId,string message) { var q = BLL.HJGL_PipelineComponentService.GetPipelineComponentById(PipelineComponentId); if (q != null) { - q.State = HJGL_PipelineComponentService.state_1; + if (!string.IsNullOrEmpty(message)) + { + q.State = HJGL_PipelineComponentService.state_Msg; + q.Remark=message; + } + else + { + q.State = HJGL_PipelineComponentService.state_1; + + } q.ReceiveMan = PersonId; q.ReceiveDate = DateTime.Now; + HJGL_PipelineComponentService.UpdatePipelineComponent(q); } } diff --git a/SGGL/BLL/HJGL/WeldingManage/PipelineComponentService.cs b/SGGL/BLL/HJGL/WeldingManage/PipelineComponentService.cs index ccdbee57..091b54e0 100644 --- a/SGGL/BLL/HJGL/WeldingManage/PipelineComponentService.cs +++ b/SGGL/BLL/HJGL/WeldingManage/PipelineComponentService.cs @@ -11,6 +11,10 @@ namespace BLL { public class HJGL_PipelineComponentService { + /// + /// 验收不合格 + /// + public static int state_Msg = -1; /// /// 未验收 /// @@ -33,10 +37,11 @@ namespace BLL /// public static ListItem[] GetState() { - ListItem[] list = new ListItem[3]; + ListItem[] list = new ListItem[4]; list[0] = new ListItem("未验收", state_0.ToString()); list[1] = new ListItem("已验收", state_1.ToString()); list[2] = new ListItem("已出库", state_2.ToString()); + list[3] = new ListItem("验收不合格", state_Msg.ToString()); return list; } /// @@ -241,6 +246,7 @@ namespace BLL newPipeline.ReceiveDate= pipeline.ReceiveDate; newPipeline.ProductionState= pipeline.ProductionState; newPipeline.IsPrint= pipeline.IsPrint; + newPipeline.Remark = pipeline.Remark; db.HJGL_Pipeline_Component.InsertOnSubmit(newPipeline); db.SubmitChanges(); } @@ -272,6 +278,7 @@ namespace BLL newPipeline.ReceiveDate = pipeline.ReceiveDate; newPipeline.ProductionState = pipeline.ProductionState; newPipeline.IsPrint=pipeline.IsPrint; + newPipeline.Remark = pipeline.Remark; db.SubmitChanges(); } } diff --git a/SGGL/FineUIPro.Web/File/Fastreport/材料出库单.frx b/SGGL/FineUIPro.Web/File/Fastreport/材料出库单.frx index 3768949c..deaff193 100644 --- a/SGGL/FineUIPro.Web/File/Fastreport/材料出库单.frx +++ b/SGGL/FineUIPro.Web/File/Fastreport/材料出库单.frx @@ -1,5 +1,5 @@  - + using System; using System.Collections; using System.Collections.Generic; @@ -84,7 +84,7 @@ namespace FastReport } - + diff --git a/SGGL/FineUIPro.Web/File/Fastreport/材料出库计划单.frx b/SGGL/FineUIPro.Web/File/Fastreport/材料出库计划单.frx index 5eeaa159..fbc6ab3d 100644 --- a/SGGL/FineUIPro.Web/File/Fastreport/材料出库计划单.frx +++ b/SGGL/FineUIPro.Web/File/Fastreport/材料出库计划单.frx @@ -1,5 +1,5 @@  - + using System; using System.Collections; using System.Collections.Generic; @@ -84,7 +84,7 @@ namespace FastReport } - + diff --git a/SGGL/FineUIPro.Web/HJGL/PreDesign/PrePipeline.aspx.cs b/SGGL/FineUIPro.Web/HJGL/PreDesign/PrePipeline.aspx.cs index 425b1837..433c496a 100644 --- a/SGGL/FineUIPro.Web/HJGL/PreDesign/PrePipeline.aspx.cs +++ b/SGGL/FineUIPro.Web/HJGL/PreDesign/PrePipeline.aspx.cs @@ -629,7 +629,7 @@ namespace FineUIPro.Web.HJGL.PreDesign var model = HJGL_PipelineComponentService.GetPipelineComponentById(item); if (model.ProductionState==2) { - BLL.APIPipelineComponentService.GetComponentConfirmArrival(PipelineComponentId: item, this.CurrUser.PersonId); ; + BLL.APIPipelineComponentService.GetComponentConfirmArrival(PipelineComponentId: item, this.CurrUser.PersonId,""); ; } } diff --git a/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldMatMatch.aspx b/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldMatMatch.aspx index 31374bbf..121361b0 100644 --- a/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldMatMatch.aspx +++ b/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldMatMatch.aspx @@ -33,6 +33,9 @@ .f-grid-row.green { background-color: green; } + .f-grid-row { + font-size:smaller; + } @@ -154,7 +157,7 @@ + SortField="Id" SortDirection="ASC" OnSort="Grid1_Sort" > _IsPrint; + private string _Remark; + private EntityRef _HJGL_Pipeline; #region 可扩展性方法定义 @@ -95453,6 +95455,8 @@ namespace Model partial void OnProductionStateChanged(); partial void OnIsPrintChanging(System.Nullable value); partial void OnIsPrintChanged(); + partial void OnRemarkChanging(string value); + partial void OnRemarkChanged(); #endregion public HJGL_Pipeline_Component() @@ -95825,6 +95829,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Remark", DbType="NVarChar(200)")] + public string Remark + { + get + { + return this._Remark; + } + set + { + if ((this._Remark != value)) + { + this.OnRemarkChanging(value); + this.SendPropertyChanging(); + this._Remark = value; + this.SendPropertyChanged("Remark"); + this.OnRemarkChanged(); + } + } + } + [global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_HJGL_Pipeline_Component_HJGL_Pipeline", Storage="_HJGL_Pipeline", ThisKey="PipelineId", OtherKey="PipelineId", IsForeignKey=true)] public HJGL_Pipeline HJGL_Pipeline { @@ -154382,7 +154406,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AttentPerson", DbType="NVarChar(3000)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_AttentPerson", DbType="NVarChar(500)")] public string AttentPerson { get @@ -185341,7 +185365,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectDescription", DbType="VarChar(MAX)", UpdateCheck=UpdateCheck.Never)] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ProjectDescription", DbType="VarChar(255)")] public string ProjectDescription { get @@ -185461,7 +185485,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CalculationRule", DbType="VarChar(MAX)", UpdateCheck=UpdateCheck.Never)] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_CalculationRule", DbType="VarChar(255)")] public string CalculationRule { get @@ -185521,7 +185545,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ConstructionSubcontractor", DbType="VarChar(100)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ConstructionSubcontractor", DbType="VarChar(50)")] public string ConstructionSubcontractor { get @@ -185905,7 +185929,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackageEstimate", DbType="Decimal(18,3)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_WorkPackageEstimate", DbType="Decimal(18,2)")] public System.Nullable WorkPackageEstimate { get @@ -186210,16 +186234,6 @@ namespace Model private string _ProjectId; - private string _ContractId; - - private string _OrderCode; - - private System.Nullable _OrderInDate; - - private System.Nullable _OrderOutDate; - - private string _MaterialRequisitionUnit; - private System.Nullable _State; private string _InvoiceCode; @@ -186248,6 +186262,16 @@ namespace Model private string _CreateUser; + private string _ContractId; + + private System.Nullable _OrderInDate; + + private string _OrderCode; + + private System.Nullable _OrderOutDate; + + private string _MaterialRequisitionUnit; + #region 可扩展性方法定义 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -186256,16 +186280,6 @@ namespace Model partial void OnInvoiceIdChanged(); partial void OnProjectIdChanging(string value); partial void OnProjectIdChanged(); - partial void OnContractIdChanging(string value); - partial void OnContractIdChanged(); - partial void OnOrderCodeChanging(string value); - partial void OnOrderCodeChanged(); - partial void OnOrderInDateChanging(System.Nullable value); - partial void OnOrderInDateChanged(); - partial void OnOrderOutDateChanging(System.Nullable value); - partial void OnOrderOutDateChanged(); - partial void OnMaterialRequisitionUnitChanging(string value); - partial void OnMaterialRequisitionUnitChanged(); partial void OnStateChanging(System.Nullable value); partial void OnStateChanged(); partial void OnInvoiceCodeChanging(string value); @@ -186294,6 +186308,16 @@ namespace Model partial void OnCreateDateChanged(); partial void OnCreateUserChanging(string value); partial void OnCreateUserChanged(); + partial void OnContractIdChanging(string value); + partial void OnContractIdChanged(); + partial void OnOrderInDateChanging(System.Nullable value); + partial void OnOrderInDateChanged(); + partial void OnOrderCodeChanging(string value); + partial void OnOrderCodeChanged(); + partial void OnOrderOutDateChanging(System.Nullable value); + partial void OnOrderOutDateChanged(); + partial void OnMaterialRequisitionUnitChanging(string value); + partial void OnMaterialRequisitionUnitChanged(); #endregion public PHTGL_Invoice() @@ -186341,106 +186365,6 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ContractId", DbType="NVarChar(50)")] - public string ContractId - { - get - { - return this._ContractId; - } - set - { - if ((this._ContractId != value)) - { - this.OnContractIdChanging(value); - this.SendPropertyChanging(); - this._ContractId = value; - this.SendPropertyChanged("ContractId"); - this.OnContractIdChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_OrderCode", DbType="NVarChar(50)")] - public string OrderCode - { - get - { - return this._OrderCode; - } - set - { - if ((this._OrderCode != value)) - { - this.OnOrderCodeChanging(value); - this.SendPropertyChanging(); - this._OrderCode = value; - this.SendPropertyChanged("OrderCode"); - this.OnOrderCodeChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_OrderInDate", DbType="Date")] - public System.Nullable OrderInDate - { - get - { - return this._OrderInDate; - } - set - { - if ((this._OrderInDate != value)) - { - this.OnOrderInDateChanging(value); - this.SendPropertyChanging(); - this._OrderInDate = value; - this.SendPropertyChanged("OrderInDate"); - this.OnOrderInDateChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_OrderOutDate", DbType="Date")] - public System.Nullable OrderOutDate - { - get - { - return this._OrderOutDate; - } - set - { - if ((this._OrderOutDate != value)) - { - this.OnOrderOutDateChanging(value); - this.SendPropertyChanging(); - this._OrderOutDate = value; - this.SendPropertyChanged("OrderOutDate"); - this.OnOrderOutDateChanged(); - } - } - } - - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialRequisitionUnit", DbType="NVarChar(100)")] - public string MaterialRequisitionUnit - { - get - { - return this._MaterialRequisitionUnit; - } - set - { - if ((this._MaterialRequisitionUnit != value)) - { - this.OnMaterialRequisitionUnitChanging(value); - this.SendPropertyChanging(); - this._MaterialRequisitionUnit = value; - this.SendPropertyChanged("MaterialRequisitionUnit"); - this.OnMaterialRequisitionUnitChanged(); - } - } - } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_State", DbType="Int")] public System.Nullable State { @@ -186721,6 +186645,106 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ContractId", DbType="NVarChar(50)")] + public string ContractId + { + get + { + return this._ContractId; + } + set + { + if ((this._ContractId != value)) + { + this.OnContractIdChanging(value); + this.SendPropertyChanging(); + this._ContractId = value; + this.SendPropertyChanged("ContractId"); + this.OnContractIdChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_OrderInDate", DbType="Date")] + public System.Nullable OrderInDate + { + get + { + return this._OrderInDate; + } + set + { + if ((this._OrderInDate != value)) + { + this.OnOrderInDateChanging(value); + this.SendPropertyChanging(); + this._OrderInDate = value; + this.SendPropertyChanged("OrderInDate"); + this.OnOrderInDateChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_OrderCode", DbType="NVarChar(50)")] + public string OrderCode + { + get + { + return this._OrderCode; + } + set + { + if ((this._OrderCode != value)) + { + this.OnOrderCodeChanging(value); + this.SendPropertyChanging(); + this._OrderCode = value; + this.SendPropertyChanged("OrderCode"); + this.OnOrderCodeChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_OrderOutDate", DbType="Date")] + public System.Nullable OrderOutDate + { + get + { + return this._OrderOutDate; + } + set + { + if ((this._OrderOutDate != value)) + { + this.OnOrderOutDateChanging(value); + this.SendPropertyChanging(); + this._OrderOutDate = value; + this.SendPropertyChanged("OrderOutDate"); + this.OnOrderOutDateChanged(); + } + } + } + + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_MaterialRequisitionUnit", DbType="NVarChar(100)")] + public string MaterialRequisitionUnit + { + get + { + return this._MaterialRequisitionUnit; + } + set + { + if ((this._MaterialRequisitionUnit != value)) + { + this.OnMaterialRequisitionUnitChanging(value); + this.SendPropertyChanging(); + this._MaterialRequisitionUnit = value; + this.SendPropertyChanged("MaterialRequisitionUnit"); + this.OnMaterialRequisitionUnitChanged(); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; @@ -301783,7 +301807,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(200)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_Name", DbType="NVarChar(50)")] public string Name { get @@ -302360,7 +302384,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(200)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(50)")] public string PackageContent { get @@ -302551,7 +302575,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(200)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(50)")] public string PackageContent { get @@ -307862,7 +307886,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(200)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(50)")] public string PackageContent { get @@ -309334,7 +309358,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(200)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_PackageContent", DbType="NVarChar(50)")] public string PackageContent { get @@ -318885,7 +318909,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ContractNo", DbType="NVarChar(1500)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ContractNo", DbType="NVarChar(500)")] public string ContractNo { get @@ -318905,7 +318929,7 @@ namespace Model } } - [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UnitWorks", DbType="NVarChar(1500)")] + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_UnitWorks", DbType="NVarChar(500)")] public string UnitWorks { get diff --git a/SGGL/WebAPI/Controllers/HJGL/PipelineComponentController.cs b/SGGL/WebAPI/Controllers/HJGL/PipelineComponentController.cs index 6d62d70e..5a1926e0 100644 --- a/SGGL/WebAPI/Controllers/HJGL/PipelineComponentController.cs +++ b/SGGL/WebAPI/Controllers/HJGL/PipelineComponentController.cs @@ -70,12 +70,12 @@ namespace WebAPI.Controllers /// /// /// - public Model.ResponeData GetComponentConfirmArrival(string PipelineComponentId, string PersonId) + public Model.ResponeData GetComponentConfirmArrival(string PipelineComponentId, string PersonId,string Message) { var responeData = new Model.ResponeData(); try { - BLL.APIPipelineComponentService.GetComponentConfirmArrival(PipelineComponentId, PersonId); + BLL.APIPipelineComponentService.GetComponentConfirmArrival(PipelineComponentId, PersonId, Message); } catch (Exception ex) { From 92f20a5913ab53389e9d91de9d1e174b0161625d Mon Sep 17 00:00:00 2001 From: fei550 <1420031550@qq.com> Date: Wed, 6 Nov 2024 09:59:54 +0800 Subject: [PATCH 2/3] 1 --- .vs/SGGL_SeDin_New/v17/.wsuo | Bin 65536 -> 64000 bytes .../API/HJGL/APIPipelineComponentService.cs | 6 ++- .../WeldingManage/PipelineComponentService.cs | 35 ++++++++++-------- .../APIItem/HJGL/PipelineComponentItem.cs | 2 + 4 files changed, 26 insertions(+), 17 deletions(-) diff --git a/.vs/SGGL_SeDin_New/v17/.wsuo b/.vs/SGGL_SeDin_New/v17/.wsuo index aac6161431d64c86e12b00ceec5c95864a8a96d7..a6886c552170002e0ece760cd7229e6f0c330709 100644 GIT binary patch delta 1419 zcmdUvO-vI(6vubATU_dHODXlEG(gK1inh{iOF=C1QBb}F1mevEv2ZY&cxV-sq%|R) zI7mkmj|MNs#Kf={jwYI*hJ>RB&)&S4ltdDx{$FTAjV6+Ka*|)?eaxGg_uuYjvr;y1 zdUZpTmHBsHT0gNmo)!x%z|*ENm8pUth@gPMS8STv3a4TWKNxn-r23!@7NuR76;KT< z;3S~(UF2lUZg7};BVGDkB_u$qA%SixStPzV<7s^T2Ntb;I!fGB7K zG0+Y=z-iD4&VV@R0%t)t=mEW;4 zse1@MsZJFY#T?~n98B|?vZ|8i&SLC8(Ohv$qz7-XxFr&T_gH#V49BV0y zP?Wl**;uzE*+1@}#6{M~x2+lG}Y_gaO56Y!SM(>i53Qse+Br`?K^q&s# z9s3CHuLnt8FnTqd49-TvSAuhTG~Cu6nbq~ktnt#n!HiUB znXT4|IqzG=gj2Qhlk?tbIZz%*HE!{QwadtA36Z}MbtB*Om>uvi_lAis-0;hVJxQ|< z2h{K#--o>oI~11F5__k_vTQXfu6BxRRSBlD6UD0(HH0$u}^k9+RDlSri{66*0Y zf@ZSp_0jEbnVn+7BHK!_v?iTOr&6h$U=f3E8JxOiDCtdjU>J$1H^#Zi1}zJ$0hz!J zzH$S`2FMm50j_IT*tpJzdD-?|TU<1)&>fKTK>^^UYzE4AcvDamExb%+Zrie~r&{qw zd>^zH5CZ!_D>wiSfhe!5PYS1F{-(>iq3mhc3xSl5h1=nQF_hyK?BzCB$jkY zO7}A$^Ib8JBP-kUSN%q;Y)dwLm8?pK*Z#*H*8S)(ubP;YOGZgcPHDZGH;n>PAd`2E zQ$U}jY-Cab}Qb4Ov1mr(P=}0YBWx zxpc=UYJNpe1Rr??wS39a&wlk=7ZjG9?0;~gOSubd6UD4?irTDXv_)7U#cXlrq*>dr zv)Er+*;(%Od3>eiK2J%P-|wj?FZX*Q;gaI8*I!XuQr0Qo-!h%XV{H2=#`d_#ub`Rc z3!ZC*<@7)5PB}vw<(BiG1w{+75UWp)x`Kj^@$XzKN|sYax7jMI$(v@P2fkP7vb~YV zq?A3uwouFw)bfquhhC{e<|`X@OLKf<6&ppXf>fuk8QsBXs!=Vg^B35tT}Ybt z&@-!Bj+#P@o(XQz2OqCI@6QmDuDb7QD89*(MNfXW46l}rmI)KpFGLN4-|oE)A^A=1 zxIVKl($m+SKQJ&rcN&i&pLwFWfl+#>p04kkp{@ICq.Value==x.State.ToString()).Text.Trim(), PlanStartDate = string.Format("{0:g}", y.PlanStartDate), QRCode = x.QRCode, ReceiveMan = p.PersonName, ReceiveDate = string.Format("{0:g}", x.ReceiveDate), UnitWorkName=unitwork.UnitWorkName, + Remark = x.Remark }).FirstOrDefault(); bool isPower = Person_PersonsService.IsGeneralUnitByPersonId(personId, projectId); pipelineComponentDetail.pipelineComponentItem = q; @@ -83,12 +85,12 @@ namespace BLL { if (!string.IsNullOrEmpty(message)) { - q.State = HJGL_PipelineComponentService.state_Msg; + q.State = HJGL_PipelineComponentService.StatePenRec; q.Remark=message; } else { - q.State = HJGL_PipelineComponentService.state_1; + q.State = HJGL_PipelineComponentService.State1; } q.ReceiveMan = PersonId; diff --git a/SGGL/BLL/HJGL/WeldingManage/PipelineComponentService.cs b/SGGL/BLL/HJGL/WeldingManage/PipelineComponentService.cs index 091b54e0..1eb1927d 100644 --- a/SGGL/BLL/HJGL/WeldingManage/PipelineComponentService.cs +++ b/SGGL/BLL/HJGL/WeldingManage/PipelineComponentService.cs @@ -12,23 +12,27 @@ namespace BLL public class HJGL_PipelineComponentService { /// - /// 验收不合格 + /// 待整改 /// - public static int state_Msg = -1; + public static int StatePenRec = -2; + /// + /// 已整改 + /// + public static int StateRec = -1; /// /// 未验收 /// - public static int state_0 = 0; + public static int State0 = 0; /// /// 已验收 /// - public static int state_1 = 1; + public static int State1 = 1; /// /// 已装箱 /// - public static int state_2 = 2; + public static int State2 = 2; /// @@ -37,11 +41,12 @@ namespace BLL /// public static ListItem[] GetState() { - ListItem[] list = new ListItem[4]; - list[0] = new ListItem("未验收", state_0.ToString()); - list[1] = new ListItem("已验收", state_1.ToString()); - list[2] = new ListItem("已出库", state_2.ToString()); - list[3] = new ListItem("验收不合格", state_Msg.ToString()); + ListItem[] list = new ListItem[5]; + list[0] = new ListItem("未验收", State0.ToString()); + list[1] = new ListItem("已验收", State1.ToString()); + list[2] = new ListItem("已出库", State2.ToString()); + list[3] = new ListItem("待整改", StatePenRec.ToString()); + list[4] = new ListItem("已整改", StateRec.ToString()); return list; } /// @@ -199,7 +204,7 @@ namespace BLL model.PipelineId = PipelineId; model.PipelineComponentCode = model_mat.PrefabricatedComponents; model.DrawingName = model_mat.PrefabricatedComponents.Substring(0, model_mat.PrefabricatedComponents.LastIndexOf('-')).Replace("\"", ""); - model.State = state_0; + model.State = State0; model.ProductionState = 0; UpdatePipelineComponent(model); } @@ -210,7 +215,7 @@ namespace BLL model.PipelineId = PipelineId; model.PipelineComponentCode = model_mat.PrefabricatedComponents; model.DrawingName = model_mat.PrefabricatedComponents?.Substring(0, model_mat.PrefabricatedComponents.LastIndexOf('-')).Replace("\"", ""); - model.State = state_0; + model.State = State0; model.ProductionState = 0; model.IsPrint = false; AddPipelineComponent(model); @@ -290,9 +295,9 @@ namespace BLL public static void UpdateOutState(string pipelineComponentId,string BoxNumber) { var q=GetPipelineComponentById(pipelineComponentId); - if (q.State==state_1) + if (q.State==State1) { - q.State = state_2; + q.State = State2; q.BoxNumber=BoxNumber; UpdatePipelineComponent(q); @@ -408,7 +413,7 @@ namespace BLL Model.SGGLDB db = Funs.DB; var q = (from x in db.HJGL_Pipeline_Component join y in db.HJGL_Pipeline on x.PipelineId equals y.PipelineId - where y.ProjectId.Contains(projectId) && x.State.Equals(state_1) && + where y.ProjectId.Contains(projectId) && x.State.Equals(State1) && (string.IsNullOrEmpty(pipelineCode) || y.PipelineCode.Contains(pipelineCode)) && (string.IsNullOrEmpty(pipelineComponentCode) || x.PipelineComponentCode.Contains(pipelineComponentCode)) && (string.IsNullOrEmpty(flowingSection) || y.FlowingSection.Contains(flowingSection)) diff --git a/SGGL/Model/APIItem/HJGL/PipelineComponentItem.cs b/SGGL/Model/APIItem/HJGL/PipelineComponentItem.cs index 3f2c824c..bc9a91a7 100644 --- a/SGGL/Model/APIItem/HJGL/PipelineComponentItem.cs +++ b/SGGL/Model/APIItem/HJGL/PipelineComponentItem.cs @@ -14,11 +14,13 @@ namespace Model public string DrawingName { get; set; } public string BoxNumber { get; set; } public int? State { get; set; } + public string StateStr { get; set; } public string PlanStartDate { get; set; } public string QRCode { get; set; } public string ReceiveMan { get; set; } public string ReceiveDate { get; set; } public string UnitWorkName { get; set; } + public string Remark { get; set; } } public class PipelineComponentDetail { From 693c9148698a5e05cfa41afda08e35254b7d59d3 Mon Sep 17 00:00:00 2001 From: fei550 <1420031550@qq.com> Date: Wed, 6 Nov 2024 16:03:58 +0800 Subject: [PATCH 3/3] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E7=84=8A=E6=8E=A5?= =?UTF-8?q?=E4=BB=BB=E5=8A=A1=E5=8D=95=E6=89=93=E5=8D=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../API/HJGL/APIPipelineComponentService.cs | 16 +- SGGL/BLL/CLGL/TwArrivalStatisticsService.cs | 65 ++++++ SGGL/BLL/CLGL/TwInOutplanmasterService.cs | 2 +- .../File/Fastreport/材料入库单.frx | 4 +- .../File/Fastreport/材料出库计划单.frx | 4 +- .../File/Fastreport/管道焊接任务单.frx | 188 ++++++++++++++++++ .../HJGL/WeldingManage/WeldTask.aspx | 1 + .../HJGL/WeldingManage/WeldTask.aspx.cs | 80 ++++++++ .../WeldingManage/WeldTask.aspx.designer.cs | 9 + 9 files changed, 359 insertions(+), 10 deletions(-) create mode 100644 SGGL/FineUIPro.Web/File/Fastreport/管道焊接任务单.frx diff --git a/SGGL/BLL/API/HJGL/APIPipelineComponentService.cs b/SGGL/BLL/API/HJGL/APIPipelineComponentService.cs index e50ffbb2..69132cea 100644 --- a/SGGL/BLL/API/HJGL/APIPipelineComponentService.cs +++ b/SGGL/BLL/API/HJGL/APIPipelineComponentService.cs @@ -52,8 +52,7 @@ namespace BLL from t in tt.DefaultIfEmpty() from p in pp.DefaultIfEmpty() join unitwork in db.WBS_UnitWork on y.UnitWorkId equals unitwork.UnitWorkId into unitworks - from unitwork in unitworks.DefaultIfEmpty() - + from unitwork in unitworks.DefaultIfEmpty() where x.PipelineComponentId== PipelineComponentId select new PipelineComponentItem { @@ -62,8 +61,7 @@ namespace BLL PreUnit = t.UnitName, DrawingName = x.DrawingName, BoxNumber = x.BoxNumber, - State = x.State, - StateStr = HJGL_PipelineComponentService.GetState().FirstOrDefault(q=>q.Value==x.State.ToString()).Text.Trim(), + State = x.State, PlanStartDate = string.Format("{0:g}", y.PlanStartDate), QRCode = x.QRCode, ReceiveMan = p.PersonName, @@ -71,9 +69,17 @@ namespace BLL UnitWorkName=unitwork.UnitWorkName, Remark = x.Remark }).FirstOrDefault(); + if (q != null) + { + q.StateStr = HJGL_PipelineComponentService.GetState() + .FirstOrDefault(x => x.Value == q.State.ToString()) + ?.Text.Trim(); + + } bool isPower = Person_PersonsService.IsGeneralUnitByPersonId(personId, projectId); pipelineComponentDetail.pipelineComponentItem = q; - pipelineComponentDetail.isPower=isPower; + pipelineComponentDetail.isPower = isPower; + return pipelineComponentDetail; } diff --git a/SGGL/BLL/CLGL/TwArrivalStatisticsService.cs b/SGGL/BLL/CLGL/TwArrivalStatisticsService.cs index 52585cf1..4f3e753f 100644 --- a/SGGL/BLL/CLGL/TwArrivalStatisticsService.cs +++ b/SGGL/BLL/CLGL/TwArrivalStatisticsService.cs @@ -7,6 +7,7 @@ using System.Linq; using System.Text; using System.Text.RegularExpressions; using System.Threading.Tasks; +using System.Windows.Media.Animation; namespace BLL { @@ -132,6 +133,70 @@ namespace BLL } } + public static decimal? GetPipeMatch(string pipelineId) + { + using (Model.SGGLDB db = new Model.SGGLDB(Funs.ConnString)) + { + var twPipeMatMatchOutputs = new List(); + var pipelineModel = PipelineService.GetPipelineByPipelineId(pipelineId); + string warehouseCode = PipelineService + .GetPipeArea().FirstOrDefault(x => x.Value == pipelineModel.PipeArea.ToString()) + ?.Text; + // 获取所需材料列表 + var requiredMaterials = (from x in db.HJGL_PipeLineMat + join y in db.HJGL_MaterialCodeLib on x.MaterialCode equals y.MaterialCode + join z in db.HJGL_Pipeline on x.PipelineId equals z.PipelineId + join m in db.WBS_UnitWork on z.UnitWorkId equals m.UnitWorkId + where z.PipelineId== pipelineId && x.PrefabricatedComponents != "" //x.PrefabricatedComponents!="" 用于筛选非散件材料 + select new Tw_PipeMatMatchOutput + { + Id = Guid.NewGuid().ToString(), + PipelineId = x.PipelineId, + PipelineCode = z.PipelineCode, + UnitWorkId = z.UnitWorkId, + UnitWorkName = m.UnitWorkName, + PrefabricatedComponents = x.PrefabricatedComponents, + MaterialCode = x.MaterialCode, + MaterialName = y.MaterialName, + MaterialSpec = y.MaterialSpec, + MaterialUnit = y.MaterialUnit, + MaterialDef = y.MaterialDef, + NeedNum = x.Number, + } + ).ToList(); + Tw_MaterialStockOutput tw_MaterialStockOutput = new Tw_MaterialStockOutput(); + tw_MaterialStockOutput.WarehouseCode = warehouseCode; + var stockList = TwMaterialstockService.GetTw_MaterialStockByModle(tw_MaterialStockOutput).ToList();//获取库存列表 + + // 模拟库存管理 + foreach (var material in requiredMaterials) + { + var thisMaterialStockNum = stockList.FirstOrDefault(x => x.PipeLineMatCode == material.MaterialCode)?.StockNum ?? 0; + if (thisMaterialStockNum >= material.NeedNum) + { + material.MatchNum = material.NeedNum; + material.MatchRate = 1; + material.MatchRateString = "100%"; + } + else + { + material.MatchNum = thisMaterialStockNum < 0 ? 0 : thisMaterialStockNum; + material.MatchRate = (material.NeedNum == 0 ? 0 : material.MatchNum ?? 0 / material.NeedNum); + material.MatchRateString = Math.Round((decimal)material.MatchRate * 100, 2).ToString() + "%"; + + } + //修改stockList对应的库存数量 + var stock = stockList.FirstOrDefault(x => x.PipeLineMatCode == material.MaterialCode); + if (stock != null) + { + stock.StockNum -= material.MatchNum; + } + } + twPipeMatMatchOutputs = requiredMaterials; + var result = twPipeMatMatchOutputs.Count==0?0: twPipeMatMatchOutputs.Sum(x=>x.MatchRate)/ twPipeMatMatchOutputs.Count; + return result; + } + } public static List GetMatMatchByOutPlanMasterId(string outPlanMasterId) { diff --git a/SGGL/BLL/CLGL/TwInOutplanmasterService.cs b/SGGL/BLL/CLGL/TwInOutplanmasterService.cs index 993dbf03..34db1b20 100644 --- a/SGGL/BLL/CLGL/TwInOutplanmasterService.cs +++ b/SGGL/BLL/CLGL/TwInOutplanmasterService.cs @@ -547,7 +547,7 @@ namespace BLL { return; } - string WeldTaskId= unitworkid+"|"+unitid+ "|" + string.Format("{0:yyyyMMMMdd}", date); + string WeldTaskId= unitworkid+"|"+unitid+ "|" + string.Format("{0:yyyyMMdd}", date); //判断是否已经生成过出库计划单 var queryIsExitInMaster = new Tw_InOutMasterOutput(); queryIsExitInMaster.WeldTaskId = WeldTaskId; diff --git a/SGGL/FineUIPro.Web/File/Fastreport/材料入库单.frx b/SGGL/FineUIPro.Web/File/Fastreport/材料入库单.frx index c682a67c..e0b7e869 100644 --- a/SGGL/FineUIPro.Web/File/Fastreport/材料入库单.frx +++ b/SGGL/FineUIPro.Web/File/Fastreport/材料入库单.frx @@ -1,5 +1,5 @@  - + using System; using System.Collections; using System.Collections.Generic; @@ -84,7 +84,7 @@ namespace FastReport } - + diff --git a/SGGL/FineUIPro.Web/File/Fastreport/材料出库计划单.frx b/SGGL/FineUIPro.Web/File/Fastreport/材料出库计划单.frx index fbc6ab3d..9768ed7f 100644 --- a/SGGL/FineUIPro.Web/File/Fastreport/材料出库计划单.frx +++ b/SGGL/FineUIPro.Web/File/Fastreport/材料出库计划单.frx @@ -1,5 +1,5 @@  - + using System; using System.Collections; using System.Collections.Generic; @@ -84,7 +84,7 @@ namespace FastReport } - + diff --git a/SGGL/FineUIPro.Web/File/Fastreport/管道焊接任务单.frx b/SGGL/FineUIPro.Web/File/Fastreport/管道焊接任务单.frx new file mode 100644 index 00000000..15f229ee --- /dev/null +++ b/SGGL/FineUIPro.Web/File/Fastreport/管道焊接任务单.frx @@ -0,0 +1,188 @@ + + + using System; +using System.Collections; +using System.Collections.Generic; +using System.ComponentModel; +using System.Windows.Forms; +using System.Drawing; +using System.Data; +using FastReport; +using FastReport.Data; +using FastReport.Dialog; +using FastReport.Barcode; +using FastReport.Table; +using FastReport.Utils; + +namespace FastReport +{ + public class ReportScript + {   + private int x; + private void Tabel_Data_ManualBuild(object sender, EventArgs e) + { + DataSourceBase rowData = Report.GetDataSource("Data"); + // init the data source + rowData.Init(); + + // print the first table row - it is a header + Tabel_Data.PrintRow(0); + // each PrintRow call must be followed by either PrintColumn or PrintColumns call + // to print cells on the row + Tabel_Data.PrintColumns(); + x=0; + // now enumerate the data source and print the table body + while (rowData.HasMoreRows) + { + x++; + // print the table body + Tabel_Data.PrintRow(1); + Tabel_Data.PrintColumns(); + + // go next data source row + rowData.Next(); + }   + } + } +} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldTask.aspx b/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldTask.aspx index c6bc54bd..24e47ec2 100644 --- a/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldTask.aspx +++ b/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldTask.aspx @@ -86,6 +86,7 @@ + diff --git a/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldTask.aspx.cs b/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldTask.aspx.cs index 3b06ecb5..f11a2a25 100644 --- a/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldTask.aspx.cs +++ b/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldTask.aspx.cs @@ -1,4 +1,5 @@ using BLL; +using FineUIPro.Web.HJGL.HotProcessHard; using Newtonsoft.Json.Linq; using System; using System.Collections.Generic; @@ -1332,5 +1333,84 @@ namespace FineUIPro.Web.HJGL.WeldingManage ShowNotify("请选择焊口", MessageBoxIcon.Question); } } + + protected void btnPrintTask_Click(object sender, EventArgs e) + { + DateTime? taskTime = Funs.GetNewDateTime(tvControlItem.SelectedNodeID.Split('|')[2]); + if (taskTime != null) + { + var weldTaskList = BLL.WeldTaskService.GetWeldingTaskList(this.CurrUser.LoginProjectId, tvControlItem.SelectedNodeID.Split('|')[0], tvControlItem.SelectedNodeID.Split('|')[1], Convert.ToDateTime(taskTime), this.rbIsAudit.SelectedValue); + var pipelines = weldTaskList.Select(x => x.PipelineId).Distinct().ToList(); + + if (pipelines.Any()) + { + BLL.FastReportService.ResetData(); + + //var result = HJGL_PipelineComponentService.GetPrintModelByPipelineComponentIds(null, pipelines.ToArray(), true); + //var PipelineComponentIds = result.Select(x => x.PipelineComponentId).ToArray(); + //var tb = LINQToDataTable(result); + //if (tb != null && tb.Rows.Count > 0) + //{ + // tb.TableName = "Table1"; + //} + //else + //{ + // ShowNotify("该管线已打印完成", MessageBoxIcon.Question); + // return; + //} + Dictionary keyValuePairs = new Dictionary(); + keyValuePairs.Add("Code", UnitWorkService.getUnitWorkByUnitWorkId(tvControlItem.SelectedNodeID.Split('|')[0]).UnitWorkCode+ string.Format("{0:yyyyMMdd}", taskTime.Value)); + keyValuePairs.Add("TaskDate", string.Format("{0:yyyy-MM-dd}", taskTime.Value)); + keyValuePairs.Add("UnitName", UnitService.GetUnitNameByUnitId(tvControlItem.SelectedNodeID.Split('|')[1])); + keyValuePairs.Add("UnitWorkName]", UnitWorkService.getUnitWorkByUnitWorkId(tvControlItem.SelectedNodeID.Split('|')[0]).UnitWorkName); + // 创建一个新的DataTable + DataTable dataTable = new DataTable(); + dataTable.TableName = "Data"; + // 添加列 + dataTable.Columns.Add("PipelineCode", typeof(string)); + dataTable.Columns.Add("FlowingSection", typeof(string)); + dataTable.Columns.Add("MaterialCode", typeof(string)); + dataTable.Columns.Add("MaterialSpec", typeof(string)); + dataTable.Columns.Add("MatchRate", typeof(string)); + + foreach (string pipeline in pipelines) + { + DataRow dr = dataTable.NewRow(); + var pipelineModel = PipelineService.GetPipelineByPipelineId(pipeline); + List list=new List { pipeline }; + + dr["PipelineCode"] = pipelineModel.PipelineCode; + dr["FlowingSection"] = pipelineModel.FlowingSection; + dr["MaterialCode"] = Base_MaterialService.GetMaterialByMaterialId(pipelineModel.MaterialId).MaterialCode ; + dr["MaterialSpec"] = string.Join(",", weldTaskList.Select(x => x.Specification).Distinct().ToList()) ; + dr["MatchRate"] = Math.Round((decimal)TwArrivalStatisticsService.GetPipeMatch(pipeline) * 100, 2).ToString() + "%" ; + dataTable.Rows.Add(dr); + } + BLL.FastReportService.AddFastreportTable(dataTable); + BLL.FastReportService.AddFastreportParameter(keyValuePairs); + string initTemplatePath = ""; + string rootPath = Server.MapPath("~/"); + initTemplatePath = "File\\Fastreport\\管道焊接任务单.frx"; + + if (File.Exists(rootPath + initTemplatePath)) + { + PageContext.RegisterStartupScript(Window2.GetShowReference(String.Format("~/Controls/Fastreport.aspx?ReportPath={0}", rootPath + initTemplatePath))); + + } + + } + else + { + ShowNotify("无关联管线", MessageBoxIcon.Question); + + } + + + } + else + { + ShowNotify("请选择任务单", MessageBoxIcon.Question); + } + } } } \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldTask.aspx.designer.cs b/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldTask.aspx.designer.cs index 1eb7c146..1766260e 100644 --- a/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldTask.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/HJGL/WeldingManage/WeldTask.aspx.designer.cs @@ -221,6 +221,15 @@ namespace FineUIPro.Web.HJGL.WeldingManage /// protected global::FineUIPro.Button btnPrint; + /// + /// btnPrintTask 控件。 + /// + /// + /// 自动生成的字段。 + /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 + /// + protected global::FineUIPro.Button btnPrintTask; + /// /// txtTaskDate 控件。 ///