From 87bbd83e25c50787f748850cc8c5476c26f7079a Mon Sep 17 00:00:00 2001 From: fei550 <1420031550@qq.com> Date: Thu, 28 Aug 2025 15:41:32 +0800 Subject: [PATCH] =?UTF-8?q?=E7=84=8A=E6=8E=A5=E7=AE=A1=E7=90=86=E4=BF=AE?= =?UTF-8?q?=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 72704 -> 73216 bytes .vs/SGGL_SeDin_New/v17/DocumentLayout.json | 6 +- .../版本日志/SGGLDB_V2025-08-28-001-lpf.sql | 6 + .../HJGL/PreDesign/PackagingManageService .cs | 60 +++++++-- .../PreDesign/TrainNumberManageService.cs | 34 +---- .../File/Excel/DataIn/试压包导入模版.xlsx | Bin 9614 -> 9620 bytes SGGL/FineUIPro.Web/File/Fastreport/发货单.frx | 123 ++++++++++++++++++ SGGL/FineUIPro.Web/File/Fastreport/装箱单.frx | 6 +- .../HJGL/PreDesign/PackagingManage.aspx.cs | 37 +----- .../PreDesign/PackagingManageView.aspx.cs | 11 +- .../HJGL/PreDesign/TrainNumberManager.aspx | 3 + .../HJGL/PreDesign/TrainNumberManager.aspx.cs | 99 +++++++++++--- .../HJGL/TestPackage/ItemEndCheck.aspx | 2 +- .../HJGL/TestPackage/TestPackageAudit.aspx | 4 +- .../HJGL/TestPackage/TestPackageComplete.aspx | 4 +- .../HJGL/TestPackage/TestPackageData.aspx | 2 +- .../HJGL/TestPackage/TestPackageData.aspx.cs | 123 +++++++++++++----- .../TestPackageData.aspx.designer.cs | 42 +++--- .../HJGL/TestPackage/TestPackageEdit.aspx | 4 +- .../HJGL/TestPackage/TestPackageImport.aspx | 2 +- .../HJGL/TestPackage/TestPackageItemEdit.aspx | 2 +- SGGL/Model/HJGL/PackagingManagePrintOutput.cs | 19 +++ SGGL/Model/Model.cs | 24 ++++ SGGL/Model/Model.csproj | 1 + 24 files changed, 444 insertions(+), 170 deletions(-) create mode 100644 DataBase/版本日志/SGGLDB_V2025-08-28-001-lpf.sql create mode 100644 SGGL/FineUIPro.Web/File/Fastreport/发货单.frx create mode 100644 SGGL/Model/HJGL/PackagingManagePrintOutput.cs diff --git a/.vs/SGGL_SeDin_New/v17/.wsuo b/.vs/SGGL_SeDin_New/v17/.wsuo index 9af64ada3cbf77d590569d186d1fa7c817edf295..c92d44ad39226b364f8c6200bf8e580893ce7719 100644 GIT binary patch delta 1723 zcmc&!&u<%55Z&88*v|F+3`MS+>gGml6kx&V$kc5!;X(To;DzhVEznZ z1QA9=5yub;;#tIls(O747Pa43L&THQ1TZkz* z>ggGnZDFX4zB2i9j<;X-_}Ra+koOv6FT#FTiM;^D?h=c@e)p{C#*IiO+_UkR?1FEO z7kP(ivaok(;ehLrvYzrEmh1ZtZt)R&@36?K0S(Go4VEsHtHB!70@}`VeAS=yGI~}= zn=2g*4%=_}-(xpJxA=#1r2;z(MQIjNQVf2QuE3rYfU8f$#Dh4m`4Z{ni)S1H9k&zW z-CO8CsANX$MEEwVYzjArQ%t0{7(z6gu?tUa^VM`pq`w8-<%a|5?LRwth_6NqYypbV zI?F&&DX}?wUn#lVFX7~X{r1>5!h^nOAu?$6b?RFlQogWV7{B8ZspY{(_Daq&FBe0K z&excQ9oc)SvYUmVIQ1@@wtt>#Kfoq|WyeK^MTFBc=>_OsKHitgZ{|15{6K7*<%nP8c^tNCD z?yj7G8gf_DCzt?R`gqk4Af->bmN^dI*C(LUh{Nv6p~mDz<7v>0%Y9tJ>fOD+8=C&; zx_RTn(2wdgcjrr}8H@dLETM;GRX3t?LN!!nR2{R_d<52WSuKEfj6SfWD`RoPR2A7W z%(xsg&Ae>H)KNJX%~^Wf(!-XTXb8fnb+Stu{>pbu>@}xB#2T~*tqoqJe>dG*GWcY5 x!2V@*MwG0C5>M#LsB9XE*k7E-UN5e6z=$0YMDG;QHZDjs!JS6`g8#q`>=b=Joti4quuxC(s!*<) z0!u4)eO3?{3-gqD#Lny{lSu$yFnG4c#e#g(+s}r7zJT428zv2!#@MY!2~!5inZ(6@DFp z@XcL|te>Z97FiqLtO@bg?rvSH9TjY5%-aL7gm3>N-`G7?SyqzJwfgk74vp{ZjLwL= z^udiL8_Tu!*-Z{3YxL~Y=X%}ZxeD( zjScgZGh}n2D_s#kR;snP^4j(|8|10>kd4v}CFNfF?yPzSoRbge5RZ2Jx@R-z|p?0g=v<2}pC>wMk)oNL}p zLDtM%JCrE|`Yhjtq{*ozCMF@@3Ov}dR#1ax8;MVMoKeNH`a%qiBz+^8F4MKq49gEy z od!immbW2K1l&P=cjk?8vKj4qb-fmyF6xF9wQ&l_axKQ`xE4jf{VE_OC diff --git a/.vs/SGGL_SeDin_New/v17/DocumentLayout.json b/.vs/SGGL_SeDin_New/v17/DocumentLayout.json index d1ae1f9c..75ab69a7 100644 --- a/.vs/SGGL_SeDin_New/v17/DocumentLayout.json +++ b/.vs/SGGL_SeDin_New/v17/DocumentLayout.json @@ -8,7 +8,7 @@ "VerticalTabListWidth": 256, "DocumentGroups": [ { - "DockedWidth": 217, + "DockedWidth": 200, "SelectedChildIndex": -1, "Children": [ { @@ -70,10 +70,6 @@ { "$type": "Bookmark", "Name": "ST:0:0:{aa2115a1-9712-457b-9047-dbb71ca2cdd2}" - }, - { - "$type": "Bookmark", - "Name": "ST:129:0:{116d2292-e37d-41cd-a077-ebacac4c8cc4}" } ] } diff --git a/DataBase/版本日志/SGGLDB_V2025-08-28-001-lpf.sql b/DataBase/版本日志/SGGLDB_V2025-08-28-001-lpf.sql new file mode 100644 index 00000000..2e52a609 --- /dev/null +++ b/DataBase/版本日志/SGGLDB_V2025-08-28-001-lpf.sql @@ -0,0 +1,6 @@ + alter table HJGL_TrainNumberManage add + ReceiveDate datetime; +go +update HJGL_PackagingManage set TypeInt=10 where TypeInt is null +update Sys_Menu set MenuName='ι' ,SortIndex='50' where MenuId='EEC0D060-C15E-4D25-B015-C2B91F735DAC' +update Sys_Menu set MenuName='' ,SortIndex='60' where MenuId='25DED954-10C9-47CC-99F2-C44FDE9E0A81' \ No newline at end of file diff --git a/SGGL/BLL/HJGL/PreDesign/PackagingManageService .cs b/SGGL/BLL/HJGL/PreDesign/PackagingManageService .cs index f2ee57c6..242e88bb 100644 --- a/SGGL/BLL/HJGL/PreDesign/PackagingManageService .cs +++ b/SGGL/BLL/HJGL/PreDesign/PackagingManageService .cs @@ -94,16 +94,12 @@ namespace BLL public static string GetMinPlanStartDate(string PackagingManageId) { string PlanStartDate = ""; - DataTable tb = BLL.HJGL_PackagingmanageService.GetPackagingDetailById(PackagingManageId); - if (tb == null || tb.Rows.Count == 0) + var tb = GetPackagingDetailById(PackagingManageId); + if (tb == null || tb.Count == 0) { return PlanStartDate; } - var dtTable = tb.AsEnumerable().OrderBy(o => o["PlanStartDate"]).CopyToDataTable(); - if (dtTable.Rows != null && dtTable.Rows.Count > 0) - { - PlanStartDate = dtTable.Rows[0]["PlanStartDate"].ToString(); - } + PlanStartDate = tb.OrderBy(x => x.PlanStartDate).FirstOrDefault()?.PlanStartDate.ToString(); return PlanStartDate; } @@ -172,7 +168,7 @@ namespace BLL /// /// /// - public static DataTable GetPackagingDetailById(string PackagingManageId) + /* public static DataTable GetPackagingDetailById(string PackagingManageId) { DataTable tb = new DataTable(); var model = GetHJGL_PackagingManageById(PackagingManageId); @@ -191,8 +187,54 @@ namespace BLL tb = SQLHelper.GetDataTableRunText(strSql, parameter); } return tb; - } + }*/ + public static List GetPackagingDetailById(string PackagingManageId) + { + var model = GetHJGL_PackagingManageById(PackagingManageId); + var result = new List(); + if (string.IsNullOrEmpty(model.PipelineComponentId)) + return new List(); + var PipelineComponentIds = model.PipelineComponentId.Split(','); + + if (model.TypeInt == (int)HJGL_PackagingmanageService.TypeInt.预制组件) + { + var query = from com in Funs.DB.HJGL_Pipeline_Component + join pipe in Funs.DB.HJGL_Pipeline on com.PipelineId equals pipe.PipelineId into pipeGroup + from pipe in pipeGroup.DefaultIfEmpty() + join unitwork in Funs.DB.WBS_UnitWork on pipe.UnitWorkId equals unitwork.UnitWorkId into unitworkGroup + from unitwork in unitworkGroup.DefaultIfEmpty() + where PipelineComponentIds.Contains(com.PipelineComponentId) + orderby com.PipelineComponentCode + select new Model.PackagingManagePrintOutput + { + PipelineComponentId = com.PipelineComponentId, + PipelineComponentCode = com.PipelineComponentCode, + PlanStartDate = pipe != null && pipe.PlanStartDate != null ? pipe.PlanStartDate : DateTime.Now, + UnitWorkName = unitwork != null ? unitwork.UnitWorkName : "", + num = "1", + CU = "个", + FlowingSection = pipe != null ? pipe.FlowingSection : "" + }; + result = query.ToList(); + } + else + { + var query = HJGLPackagingmanagedetailService.GetPackagingData(PackagingManageId).ToList(); + var detailList = from x in query + select new Model.PackagingManagePrintOutput + { + PipelineComponentId = x.Id, + PipelineComponentCode = x.MaterialCode, + num = x.Number.ToString(), + CU = x.MaterialUnit, + UnitWorkName = x.UnitWorkId == null ? "" : UnitWorkService.GetNameById(x.UnitWorkId), + FlowingSection = x.FlowingSection, + }; + result = detailList.ToList(); + } + return result; + } /// /// 根据项目号获取包装编号历史记录 /// diff --git a/SGGL/BLL/HJGL/PreDesign/TrainNumberManageService.cs b/SGGL/BLL/HJGL/PreDesign/TrainNumberManageService.cs index acb3a45f..1f4ec522 100644 --- a/SGGL/BLL/HJGL/PreDesign/TrainNumberManageService.cs +++ b/SGGL/BLL/HJGL/PreDesign/TrainNumberManageService.cs @@ -87,38 +87,6 @@ namespace BLL return (pagedData, totalCount); } - /// - /// 获取分页列表 - /// - /// - /// - /// - public static IEnumerable GetListData(Model.HJGL_TrainNumberManage table, Grid grid1) - { - var q = GetByQueryModle(table); - Count = q.Count(); - if (Count == 0) - { - return null; - } - q = q.Skip(grid1.PageSize * grid1.PageIndex).Take(grid1.PageSize); - // q = SortConditionHelper.SortingAndPaging(q, Grid1.SortField, Grid1.SortDirection, Grid1.PageIndex, Grid1.PageSize); - return from x in q - select new - { - x.Id, - x.TrainNumber, - x.ProjectId, - x.State, - x.DriverName, - x.DriverPhone, - x.LicensePlateNumber, - x.ContactName, - x.ContactPhone, - x.Remark, - }; - } - public static Model.HJGL_TrainNumberManage GetModelById(string Id) { return Funs.DB.HJGL_TrainNumberManage.FirstOrDefault(x => x.Id == Id); @@ -150,6 +118,7 @@ namespace BLL ContactName = newtable.ContactName, ContactPhone = newtable.ContactPhone, Remark = newtable.Remark, + ReceiveDate=newtable.ReceiveDate, }; Funs.DB.HJGL_TrainNumberManage.InsertOnSubmit(table); Funs.DB.SubmitChanges(); @@ -170,6 +139,7 @@ namespace BLL table.ContactName = newtable.ContactName; table.ContactPhone = newtable.ContactPhone; table.Remark = newtable.Remark; + table.ReceiveDate = newtable.ReceiveDate; Funs.DB.SubmitChanges(); } } diff --git a/SGGL/FineUIPro.Web/File/Excel/DataIn/试压包导入模版.xlsx b/SGGL/FineUIPro.Web/File/Excel/DataIn/试压包导入模版.xlsx index 87bfc63b577ae6c10bc9bacafaedc60d1a4bb5a8..3319b5d828779c57c78b3e92a1c548ffc29a21df 100644 GIT binary patch delta 2364 zcmV-C3B&e|OO#8n+6I5#H=|-w0ssIO1pojK0001ZY%h0ja%*C5Z)+}iZEU1eQE%HI z5PqMu|A2URZHVJER-LMuTP@NyMQYbRRuq#M)dmZ2;;8C>-{I8By1Z1KW#3Zh~`+tYfNRl~y9dJ7ItE)@#Pg*}C z08lo=rE^UhhL)G2X7)@sLV;(cP0buE%{sJ=5v;JK5U#F58bwK1GpX<%AvGVt(5sc? zBGrikBP!;AzAa^A2eg`h1g>W0xorZj>jog6WF_6M2gRu7>0+(4VNVsv?#LK* z2HpgIB!Ynsk-&d-5~`NmXscK544}h3=@b1V3JH0ag6=d2A47^mBR104@W9F>pJbIB zu#zJfiT)dnKx_5Al0x!6i8elPqj+|)l9jmMw=QB$^NZEKQWZuOv+lZ(P81oQz*29; z(GX)~+GgI$3cPe0(J2mRhjv~X1h7t+rI8!PcW@>!D#U+^wUxVr)*b?aoyL?V{@c!^ zL;9D_Ao#z?e*lGBwgEyQyLju@1w?^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EP*hQPy@q+Q;X9-RA+M5I$k6bk0V?XM2s!n zx}#FyuZg!G&F)X_IXzj>_%!g2?`uk?-#y(K?;uhATQf!)&Dzbft#Vq!2gL7MG^;Uo z^`b<@Wbq;rG**^5gcl=+AXb~s)3cojD~uhxi{l0!t0!~E&v@8&)CCvmEnnQ^LMTD` z-rLTtR#ElS@waWlx<#}`vy@xEw)h$9E2}EdtnC;(hT-oLM!@ zwSRib%22T36a3%P0xT-qflmR3s3WrfT$Mdh^$LPOh&>toYa}5cM@R<9Lt()_Kqm?Z z76k;+ipc-h-M + + 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 + { + public int x; + + private void Table2_ManualBuild(object sender, EventArgs e) + { + DataSourceBase rowData = Report.GetDataSource("Data"); + // init the data source + rowData.Init(); + x=0; + // now enumerate the data source and print the table body + while (rowData.HasMoreRows) + { + x++; + // print the table body + Table_Data.PrintRow(0); + Table_Data.PrintColumns(); + + // go next data source row + rowData.Next(); + } + } + } +} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/SGGL/FineUIPro.Web/File/Fastreport/装箱单.frx b/SGGL/FineUIPro.Web/File/Fastreport/装箱单.frx index 124997e3..48e59e9e 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; @@ -42,7 +42,7 @@ namespace FastReport } - + @@ -62,7 +62,7 @@ namespace FastReport - + diff --git a/SGGL/FineUIPro.Web/HJGL/PreDesign/PackagingManage.aspx.cs b/SGGL/FineUIPro.Web/HJGL/PreDesign/PackagingManage.aspx.cs index 31f06ce4..083ab0a8 100644 --- a/SGGL/FineUIPro.Web/HJGL/PreDesign/PackagingManage.aspx.cs +++ b/SGGL/FineUIPro.Web/HJGL/PreDesign/PackagingManage.aspx.cs @@ -32,40 +32,7 @@ namespace FineUIPro.Web.HJGL.PreDesign /// 绑定数据 /// private void BindGrid() - { - // string strSql = @"select pack.PackagingManageId, - // pack.PackagingCode, - // com.PipelineComponentCode, - // unit.UnitWorkName, - // pipe.PlanStartDate, - // pack.ProjectId, - // pack.StackingPosition, - // pack.State, - // pack.ContactName, - // pack.ContactPhone, - //pack.ReceiveDate, - //person.PersonName - // from HJGL_PackagingManage as pack - // left join HJGL_Pipeline_Component com on com.PipelineComponentId=pack.PipelineComponentId - // left join HJGL_Pipeline pipe on pipe.PipelineId =com.PipelineId - // left join WBS_UnitWork unit on pipe.UnitWorkId=unit.UnitWorkId - // left join Person_Persons person on pack.ReceiveMan=person.PersonId - // WHERE pack.ProjectId = @ProjectId "; - // List listStr = new List(); - // listStr.Add(new SqlParameter("@ProjectId", this.CurrUser.LoginProjectId)); - // if (!string.IsNullOrEmpty(this.txtPackagingCode.Text.Trim())) - // { - // strSql += " AND pack.PackagingCode LIKE @PackagingCode"; - // listStr.Add(new SqlParameter("@PackagingCode", "%" + this.txtPackagingCode.Text.Trim() + "%")); - // } - // SqlParameter[] parameter = listStr.ToArray(); - // DataTable tb = SQLHelper.GetDataTableRunText(strSql, parameter); - - //Grid1.RecordCount = tb.Rows.Count; - //tb = GetFilteredTable(Grid1.FilteredData, tb); - //var table = this.GetPagedDataTable(Grid1, tb); - //Grid1.DataSource = table; - //Grid1.DataBind(); + { var list = BLL.HJGL_PackagingmanageService.GetPackagingManageList(this.CurrUser.LoginProjectId, this.txtPackagingCode.Text.Trim(), this.Grid1.PageIndex, this.Grid1.PageSize); Grid1.RecordCount = list.Total; Grid1.DataSource = list.Data; @@ -341,7 +308,7 @@ namespace FineUIPro.Web.HJGL.PreDesign ShowNotify("请选择要打印的项", MessageBoxIcon.Warning); return; } - DataTable tb = BLL.HJGL_PackagingmanageService.GetPackagingDetailById(Id); + DataTable tb = LINQToDataTable(BLL.HJGL_PackagingmanageService.GetPackagingDetailById(Id)); if (tb.Rows.Count > 0) { var model = HJGL_PackagingmanageService.GetHJGL_PackagingManageById(Id); diff --git a/SGGL/FineUIPro.Web/HJGL/PreDesign/PackagingManageView.aspx.cs b/SGGL/FineUIPro.Web/HJGL/PreDesign/PackagingManageView.aspx.cs index 51b03139..7df62d97 100644 --- a/SGGL/FineUIPro.Web/HJGL/PreDesign/PackagingManageView.aspx.cs +++ b/SGGL/FineUIPro.Web/HJGL/PreDesign/PackagingManageView.aspx.cs @@ -47,7 +47,12 @@ namespace FineUIPro.Web.HJGL.PreDesign { var pack = HJGL_PackagingmanageService.GetHJGL_PackagingManageById(PackagingManageId); if (pack == null) return; - if (pack.TypeInt == (int)HJGL_PackagingmanageService.TypeInt.预制组件) + var detailList= HJGL_PackagingmanageService.GetPackagingDetailById(PackagingManageId); + Grid1.RecordCount = detailList.Count(); + Grid1.DataSource = detailList; + Grid1.DataBind(); + + /* if (pack.TypeInt == (int)HJGL_PackagingmanageService.TypeInt.预制组件) { DataTable tb = BLL.HJGL_PackagingmanageService.GetPackagingDetailById(PackagingManageId); @@ -73,9 +78,9 @@ namespace FineUIPro.Web.HJGL.PreDesign Grid1.RecordCount = detailList.Count(); Grid1.DataSource = detailList; Grid1.DataBind(); - } - + }*/ + } #endregion diff --git a/SGGL/FineUIPro.Web/HJGL/PreDesign/TrainNumberManager.aspx b/SGGL/FineUIPro.Web/HJGL/PreDesign/TrainNumberManager.aspx index 2aea6e55..abd202d5 100644 --- a/SGGL/FineUIPro.Web/HJGL/PreDesign/TrainNumberManager.aspx +++ b/SGGL/FineUIPro.Web/HJGL/PreDesign/TrainNumberManager.aspx @@ -75,6 +75,9 @@ + + diff --git a/SGGL/FineUIPro.Web/HJGL/PreDesign/TrainNumberManager.aspx.cs b/SGGL/FineUIPro.Web/HJGL/PreDesign/TrainNumberManager.aspx.cs index fab1b868..c86b1e1a 100644 --- a/SGGL/FineUIPro.Web/HJGL/PreDesign/TrainNumberManager.aspx.cs +++ b/SGGL/FineUIPro.Web/HJGL/PreDesign/TrainNumberManager.aspx.cs @@ -1,6 +1,9 @@ using BLL; +using MiniExcelLibs; using System; using System.Collections.Generic; +using System.Data; +using System.IO; using System.Linq; using System.Text; using System.Web; @@ -11,7 +14,7 @@ namespace FineUIPro.Web.HJGL.PreDesign { public partial class TrainNumberManager : PageBase { - + public static List hJGL_TrainNumberManages=new List(); protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) @@ -35,6 +38,7 @@ namespace FineUIPro.Web.HJGL.PreDesign Grid1.RecordCount = tb.Total; Grid1.DataSource = tb.Data; Grid1.DataBind(); + hJGL_TrainNumberManages= tb.Data; } #endregion @@ -187,7 +191,7 @@ namespace FineUIPro.Web.HJGL.PreDesign } } } - #endregion + #endregion #region 导出按钮 /// 导出按钮 @@ -196,17 +200,39 @@ namespace FineUIPro.Web.HJGL.PreDesign /// protected void btnOut_Click(object sender, EventArgs e) { - Response.ClearContent(); - string filename = Funs.GetNewFileName(); - Response.AddHeader("content-disposition", "attachment; filename=" + System.Web.HttpUtility.UrlEncode("发货管理" + filename, System.Text.Encoding.UTF8) + ".xls"); - Response.ContentType = "application/excel"; - Response.ContentEncoding = System.Text.Encoding.UTF8; - this.Grid1.PageSize = 500; - this.BindGrid(); - Response.Write(GetGridTableHtml(Grid1)); - Response.End(); - } + if (hJGL_TrainNumberManages != null) + { + var q = hJGL_TrainNumberManages + .Select((x, index) => new + { + 序号 = index + 1, // 自增序号,从 1 开始 + 车次 = x.TrainNumber, + 驾驶员姓名 = x.DriverName, + 驾驶员电话 = x.DriverPhone, + 车牌号 = x.LicensePlateNumber, + 联系人姓名 = x.ContactName, + 联系人电话 = x.ContactPhone, + 备注 = x.Remark + }); + string path = Funs.RootPath + @"File\Excel\Temp\TrainNumberManager.xlsx"; + path = path.Replace(".xlsx", string.Format("{0:yyyy-MM-dd}", DateTime.Now) + ".xlsx"); + + MiniExcel.SaveAs(path, q); + + string fileName = $"车次管理-"+ string.Format("{0:yyyy-MM-dd}", DateTime.Now) + ".xlsx"; + FileInfo info = new FileInfo(path); + long fileSize = info.Length; + System.Web.HttpContext.Current.Response.Clear(); + System.Web.HttpContext.Current.Response.ContentType = "application/x-zip-compressed"; + System.Web.HttpContext.Current.Response.AddHeader("Content-Disposition", "attachment;filename=" + System.Web.HttpUtility.UrlEncode(fileName, System.Text.Encoding.UTF8)); + System.Web.HttpContext.Current.Response.AddHeader("Content-Length", fileSize.ToString()); + System.Web.HttpContext.Current.Response.TransmitFile(path, 0, fileSize); + System.Web.HttpContext.Current.Response.Flush(); + System.Web.HttpContext.Current.Response.Close(); + File.Delete(path); + } + } /// /// 导出方法 /// @@ -257,17 +283,50 @@ namespace FineUIPro.Web.HJGL.PreDesign protected void btnPrint_Click(object sender, EventArgs e) { - if (!string.IsNullOrEmpty(this.Grid1.SelectedRowID)) + string Id = this.Grid1.SelectedRowID; + Pring(Id); + } + + private void Pring(string Id) + { + BLL.FastReportService.ResetData(); + if (string.IsNullOrEmpty(Id)) { - string id = Grid1.SelectedRowID; - string url = "TrainNumberManagerPrint.aspx?TrainNumberId={0}"; - PageContext.RegisterStartupScript(Window2.GetShowReference(String.Format(url, id, "打印 - "))); - } - else - { - Alert.ShowInTop("请选择要打印的数据", MessageBoxIcon.Warning); + + ShowNotify("请选择要打印的项", MessageBoxIcon.Warning); return; } + DataTable tb = LINQToDataTable(HJGL_PackagingmanageService.GetPackagingManage(Id)); + if (tb.Rows.Count > 0) + { + var model = TrainNumberManageService.GetModelById(Id); + Dictionary keyValuePairs = new Dictionary(); + keyValuePairs.Add("ProjectName", ProjectService.GetProjectNameByProjectId(this.CurrUser.LoginProjectId)); + keyValuePairs.Add("TrainNumber", model.TrainNumber); + keyValuePairs.Add("Remark", model.Remark); + keyValuePairs.Add("ContactName", model.ContactName ); + keyValuePairs.Add("ContactPhone", model.ContactPhone); + keyValuePairs.Add("ID", "TrainNumberManager$" + model.Id); + DataRow dataRow = tb.NewRow(); + dataRow["PackagingCode"] = "合计:" + tb.Rows.Count; + tb.Rows.Add(dataRow); + if (tb != null) + { + tb.TableName = "Data"; + } + BLL.FastReportService.AddFastreportTable(tb); + 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))); + + } + } } + } } \ No newline at end of file diff --git a/SGGL/FineUIPro.Web/HJGL/TestPackage/ItemEndCheck.aspx b/SGGL/FineUIPro.Web/HJGL/TestPackage/ItemEndCheck.aspx index 33fe1cfc..602fbe1e 100644 --- a/SGGL/FineUIPro.Web/HJGL/TestPackage/ItemEndCheck.aspx +++ b/SGGL/FineUIPro.Web/HJGL/TestPackage/ItemEndCheck.aspx @@ -62,7 +62,7 @@ + HeaderTextAlign="Center" HeaderText="试压包号" TextAlign="Left"> diff --git a/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageAudit.aspx b/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageAudit.aspx index 2dae47b0..5b476249 100644 --- a/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageAudit.aspx +++ b/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageAudit.aspx @@ -67,9 +67,9 @@ - + - + diff --git a/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageComplete.aspx b/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageComplete.aspx index 0037daf8..c30c758c 100644 --- a/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageComplete.aspx +++ b/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageComplete.aspx @@ -72,9 +72,9 @@ - + - + diff --git a/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageData.aspx b/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageData.aspx index dc6547f3..3b29f2c8 100644 --- a/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageData.aspx +++ b/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageData.aspx @@ -49,7 +49,7 @@ - <%-- printFiles = new Dictionary(); + foreach (var ptp_id in selectedRows) { - exportWord(ptp_id); - - } + var item = exportWord(ptp_id); + printFiles.Add(item.FirstOrDefault().Key, item.FirstOrDefault().Value); + } + if (printFiles.Count>1) + { + string rootPath = Funs.RootPath; + string startPath = rootPath + "FileUpload\\试压包资料" + DateTime.Now.GetHashCode(); + if (!Directory.Exists(startPath)) + { + Directory.CreateDirectory(startPath); + } + string zipPath = rootPath + "FileUpload\\试压包资料" + DateTime.Now.GetHashCode() + ".zip"; + foreach (var item in printFiles) + { + var sourceFile = item.Key; + var destFile = startPath + "\\" + item.Value; + if (File.Exists(sourceFile)) + { + File.Copy(sourceFile, destFile, true); + File.Delete(sourceFile); + } + } + System.IO.Compression.ZipFile.CreateFromDirectory(startPath, zipPath); + FileInfo info = new FileInfo(zipPath); + long fileSize = info.Length; + System.Web.HttpContext.Current.Response.Clear(); + System.Web.HttpContext.Current.Response.ContentType = "application/x-zip-compressed"; + System.Web.HttpContext.Current.Response.AddHeader("Content-Disposition", "attachment;filename=" + System.Web.HttpUtility.UrlEncode("试压包资料.zip", System.Text.Encoding.UTF8)); + System.Web.HttpContext.Current.Response.AddHeader("Content-Length", fileSize.ToString()); + System.Web.HttpContext.Current.Response.TransmitFile(zipPath, 0, fileSize); + System.Web.HttpContext.Current.Response.Flush(); + System.Web.HttpContext.Current.Response.Close(); + Funs.DeleteDir(startPath); + File.Delete(zipPath); + } + else + { + FileInfo info = new FileInfo(printFiles.FirstOrDefault().Key); + long fileSize = info.Length; + System.Web.HttpContext.Current.Response.Clear(); + System.Web.HttpContext.Current.Response.ContentType = "application/x-zip-compressed"; + System.Web.HttpContext.Current.Response.AddHeader("Content-Disposition", "attachment;filename=" + System.Web.HttpUtility.UrlEncode(printFiles.FirstOrDefault().Value, System.Text.Encoding.UTF8)); + System.Web.HttpContext.Current.Response.AddHeader("Content-Length", fileSize.ToString()); + System.Web.HttpContext.Current.Response.TransmitFile(printFiles.FirstOrDefault().Key, 0, fileSize); + System.Web.HttpContext.Current.Response.Flush(); + System.Web.HttpContext.Current.Response.Close(); + } + } - protected void exportWord(string ptp_id) + protected Dictionary exportWord(string ptp_id) { + Dictionary keyValuePairs = new Dictionary(); if (string.IsNullOrEmpty(ptp_id)) { Alert.ShowInTop("请选择要打印的单据!", MessageBoxIcon.Warning); - return; + return null; } //修改试压包打印状态 var updateTestPackage = Funs.DB.PTP_TestPackage.FirstOrDefault(x => x.PTP_ID == ptp_id); @@ -286,6 +334,7 @@ namespace FineUIPro.Web.HJGL.TestPackage if (this.drpPrintType.SelectedValue == "1")//pdf格式 { + exportName+=".pdf"; ListItem[] list = new ListItem[10]; list[0] = new ListItem("0", "File\\Fastreport\\JGZL\\管道试压包文件资料.frx"); list[1] = new ListItem("1", "File\\Fastreport\\JGZL\\管道压力试验技术要求.frx"); @@ -301,26 +350,28 @@ namespace FineUIPro.Web.HJGL.TestPackage List FastReportItemList = new List(); foreach (var item in list) { - FastReportItemList.Add(GetFastReportItem(updateTestPackage, item.Text)); + FastReportItemList.Add(GetFastReportItem(updateTestPackage, item.Text, ptp_id)); } - var Path = Funs.RootPath + "FileUpload/" + ptp_id + ".pdf"; + string Path = Funs.RootPath + "FileUpload/" + ptp_id + ".pdf"; BLL.FastReportService.ExportMergeReport(FastReportItemList, Path, this.drpPrintType.SelectedValue); - FileInfo info = new FileInfo(Path); - long fileSize = info.Length; - + keyValuePairs.Add(Path, exportName); + /* FileInfo info = new FileInfo(Path); + long fileSize = info.Length; System.Web.HttpContext.Current.Response.Clear(); + System.Web.HttpContext.Current.Response.ClearHeaders(); System.Web.HttpContext.Current.Response.ContentType = "application/x-zip-compressed"; System.Web.HttpContext.Current.Response.AddHeader("Content-Disposition", "attachment;filename=" + System.Web.HttpUtility.UrlEncode(exportName + ".pdf", System.Text.Encoding.UTF8)); System.Web.HttpContext.Current.Response.AddHeader("Content-Length", fileSize.ToString()); System.Web.HttpContext.Current.Response.TransmitFile(Path, 0, fileSize); System.Web.HttpContext.Current.Response.Flush(); System.Web.HttpContext.Current.Response.Close(); - File.Delete(Path); + File.Delete(Path);*/ } else if (this.drpPrintType.SelectedValue == "2")//word格式 { + exportName += ".docx"; ListItem[] list = new ListItem[3]; list[0] = new ListItem("0", "File\\Fastreport\\JGZL\\管道试压包文件资料.frx"); list[1] = new ListItem("1", "File\\Fastreport\\JGZL\\管道压力试验技术要求.frx"); @@ -329,7 +380,7 @@ namespace FineUIPro.Web.HJGL.TestPackage List FastReportItemList = new List(); foreach (var item in list) { - FastReportItemList.Add(GetFastReportItem(updateTestPackage, item.Text)); + FastReportItemList.Add(GetFastReportItem(updateTestPackage, item.Text, ptp_id)); } var PathA = Funs.RootPath + "FileUpload/" + ptp_id + ".docx"; BLL.FastReportService.ExportMergeReport(FastReportItemList, PathA, this.drpPrintType.SelectedValue); @@ -340,7 +391,7 @@ namespace FineUIPro.Web.HJGL.TestPackage List FastReportItemList2 = new List(); foreach (var item in list2) { - FastReportItemList2.Add(GetFastReportItem(updateTestPackage, item.Text)); + FastReportItemList2.Add(GetFastReportItem(updateTestPackage, item.Text, ptp_id)); } var PathB = Funs.RootPath + "FileUpload/" + ptp_id + "2.docx"; BLL.FastReportService.ExportMergeReport(FastReportItemList2, PathB, this.drpPrintType.SelectedValue); @@ -355,7 +406,7 @@ namespace FineUIPro.Web.HJGL.TestPackage List FastReportItemList3 = new List(); foreach (var item in list3) { - FastReportItemList3.Add(GetFastReportItem(updateTestPackage, item.Text)); + FastReportItemList3.Add(GetFastReportItem(updateTestPackage, item.Text, ptp_id)); } var PathC = Funs.RootPath + "FileUpload/" + ptp_id + "3.docx"; BLL.FastReportService.ExportMergeReport(FastReportItemList3, PathC, this.drpPrintType.SelectedValue); @@ -369,7 +420,7 @@ namespace FineUIPro.Web.HJGL.TestPackage List FastReportItemList4 = new List(); foreach (var item in list4) { - FastReportItemList4.Add(GetFastReportItem(updateTestPackage, item.Text)); + FastReportItemList4.Add(GetFastReportItem(updateTestPackage, item.Text, ptp_id)); } var PathD = Funs.RootPath + "FileUpload/" + ptp_id + "4.docx"; BLL.FastReportService.ExportMergeReport(FastReportItemList4, PathD, this.drpPrintType.SelectedValue); @@ -384,7 +435,7 @@ namespace FineUIPro.Web.HJGL.TestPackage List FastReportItemList5 = new List(); foreach (var item in list5) { - FastReportItemList5.Add(GetFastReportItem(updateTestPackage, item.Text)); + FastReportItemList5.Add(GetFastReportItem(updateTestPackage, item.Text, ptp_id)); } var PathE = Funs.RootPath + "FileUpload/" + ptp_id + "5.docx"; BLL.FastReportService.ExportMergeReport(FastReportItemList5, PathE, this.drpPrintType.SelectedValue); @@ -393,10 +444,12 @@ namespace FineUIPro.Web.HJGL.TestPackage doc1.AppendDocument(doc5, Aspose.Words.ImportFormatMode.KeepSourceFormatting); //将合并的文档保存为 DOCX 文件 - doc1.Save(Funs.RootPath + "FileUpload/doc.docx"); + var Path = Funs.RootPath + "FileUpload/"+ ptp_id + "Result.docx"; + doc1.Save(Path); - var Path = Funs.RootPath + "FileUpload/doc.docx"; - FileInfo info = new FileInfo(Path); + keyValuePairs.Add(Path, exportName); + + /* FileInfo info = new FileInfo(Path); long fileSize = info.Length; System.Web.HttpContext.Current.Response.Clear(); @@ -405,20 +458,22 @@ namespace FineUIPro.Web.HJGL.TestPackage System.Web.HttpContext.Current.Response.AddHeader("Content-Length", fileSize.ToString()); System.Web.HttpContext.Current.Response.TransmitFile(Path, 0, fileSize); System.Web.HttpContext.Current.Response.Flush(); - System.Web.HttpContext.Current.Response.Close(); - File.Delete(Path); + System.Web.HttpContext.Current.Response.Close();*/ + //File.Delete(Path); File.Delete(PathA); File.Delete(PathB); File.Delete(PathC); File.Delete(PathD); File.Delete(PathE); } + } + return keyValuePairs; } - protected Model.FastReportItem GetFastReportItem(Model.PTP_TestPackage updateTestPackage, string printType) + protected Model.FastReportItem GetFastReportItem(Model.PTP_TestPackage updateTestPackage, string printType, string ptp_id) { string initTemplatePath = ""; Model.FastReportItem fastReportItem = new Model.FastReportItem(); @@ -483,7 +538,7 @@ namespace FineUIPro.Web.HJGL.TestPackage where PTP_ItemEndCheckList.PTP_ID=@ptp_id"; List listStr = new List { - new SqlParameter("@ptp_id", this.PTP_ID), + new SqlParameter("@ptp_id", ptp_id), }; SqlParameter[] parameter = listStr.ToArray(); DataTable tb = SQLHelper.GetDataTableRunText(sql, parameter); @@ -539,7 +594,7 @@ namespace FineUIPro.Web.HJGL.TestPackage where ptpPipe.PTP_ID=@ptp_id"; List listStr = new List { - new SqlParameter("@ptp_id", this.PTP_ID), + new SqlParameter("@ptp_id", ptp_id), }; SqlParameter[] parameter = listStr.ToArray(); DataTable tb = SQLHelper.GetDataTableRunText(sql, parameter); @@ -596,7 +651,7 @@ namespace FineUIPro.Web.HJGL.TestPackage where PTP_ID=@ptp_id"; List listStr = new List { - new SqlParameter("@ptp_id", this.PTP_ID), + new SqlParameter("@ptp_id", ptp_id), }; SqlParameter[] parameter = listStr.ToArray(); DataTable tb = SQLHelper.GetDataTableRunText(sql, parameter); @@ -636,7 +691,7 @@ namespace FineUIPro.Web.HJGL.TestPackage break; case "7"://管道焊接工作记录 { - var iosList = BLL.TestPackageEditService.GetPipeLineListByPTP_ID(this.PTP_ID); + var iosList = BLL.TestPackageEditService.GetPipeLineListByPTP_ID(ptp_id); if (iosList.Count > 0) { var q = iosList[0]; @@ -659,11 +714,13 @@ namespace FineUIPro.Web.HJGL.TestPackage else material1.MaterialCode end) as MaterialCode, --材质 weldJoint.WeldingLocationId,--焊接位置 weldingMethod.WeldingMethodCode,--焊接方法 - (case when consumables1.ConsumablesName is not null then - case when consumables2.ConsumablesName is not null and consumables1.ConsumablesName<>consumables2.ConsumablesName - then consumables1.ConsumablesName+'+'+consumables2.ConsumablesName - else consumables2.ConsumablesName end - else consumables1.ConsumablesName end) as WeldingMaterial,--焊材牌号 + (case + when consumables1.ConsumablesName is not null then + case + when consumables2.ConsumablesName is not null and consumables1.ConsumablesName <> consumables2.ConsumablesName + then consumables1.ConsumablesName + '+' + consumables2.ConsumablesName + else consumables1.ConsumablesName end + else consumables2.ConsumablesName end) as WeldingMaterial,--焊材牌号 convert(varchar(10),weldingDaily.WeldingDate,111) as WeldingDate --焊接日期 from HJGL_WeldJoint as weldJoint left join HJGL_Pipeline as pipeline on pipeline.PipelineId = weldJoint.PipelineId @@ -732,7 +789,7 @@ namespace FineUIPro.Web.HJGL.TestPackage break; case "8"://管道无损检测数量统计表 { - var iosList = BLL.TestPackageEditService.GetPipeLineListByPTP_ID(this.PTP_ID); + var iosList = BLL.TestPackageEditService.GetPipeLineListByPTP_ID(ptp_id); if (iosList.Count > 0) { var q = iosList[0]; @@ -937,7 +994,7 @@ namespace FineUIPro.Web.HJGL.TestPackage break; case "9"://无损检测结果汇总表 { - var iosList = BLL.TestPackageEditService.GetPipeLineListByPTP_ID(this.PTP_ID); + var iosList = BLL.TestPackageEditService.GetPipeLineListByPTP_ID(ptp_id); if (iosList.Count > 0) { var q = iosList[0]; diff --git a/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageData.aspx.designer.cs b/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageData.aspx.designer.cs index 9e2309bc..196af0e0 100644 --- a/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageData.aspx.designer.cs +++ b/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageData.aspx.designer.cs @@ -7,11 +7,13 @@ // //------------------------------------------------------------------------------ -namespace FineUIPro.Web.HJGL.TestPackage { - - - public partial class TestPackageData { - +namespace FineUIPro.Web.HJGL.TestPackage +{ + + + public partial class TestPackageData + { + /// /// form1 控件。 /// @@ -20,7 +22,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::System.Web.UI.HtmlControls.HtmlForm form1; - + /// /// PageManager1 控件。 /// @@ -29,7 +31,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.PageManager PageManager1; - + /// /// Panel1 控件。 /// @@ -38,7 +40,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Panel Panel1; - + /// /// panelLeftRegion 控件。 /// @@ -47,7 +49,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Panel panelLeftRegion; - + /// /// tvControlItem 控件。 /// @@ -56,7 +58,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Tree tvControlItem; - + /// /// hdPTP_ID 控件。 /// @@ -65,7 +67,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.HiddenField hdPTP_ID; - + /// /// Panel2 控件。 /// @@ -74,7 +76,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Panel Panel2; - + /// /// Grid1 控件。 /// @@ -83,7 +85,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Grid Grid1; - + /// /// Toolbar2 控件。 /// @@ -92,7 +94,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Toolbar Toolbar2; - + /// /// txtTestPackageNo 控件。 /// @@ -101,7 +103,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.TextBox txtTestPackageNo; - + /// /// ToolbarFill1 控件。 /// @@ -110,7 +112,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.ToolbarFill ToolbarFill1; - + /// /// drpPrintType 控件。 /// @@ -119,7 +121,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.DropDownList drpPrintType; - + /// /// btnPrint 控件。 /// @@ -128,7 +130,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.Button btnPrint; - + /// /// ToolbarSeparator1 控件。 /// @@ -137,7 +139,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.ToolbarSeparator ToolbarSeparator1; - + /// /// ToolbarText1 控件。 /// @@ -146,7 +148,7 @@ namespace FineUIPro.Web.HJGL.TestPackage { /// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。 /// protected global::FineUIPro.ToolbarText ToolbarText1; - + /// /// ddlPageSize 控件。 /// diff --git a/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageEdit.aspx b/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageEdit.aspx index 2a5daf9c..dd67bfc2 100644 --- a/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageEdit.aspx +++ b/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageEdit.aspx @@ -60,9 +60,9 @@ - + - + diff --git a/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageImport.aspx b/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageImport.aspx index 5e1841b8..8487ddb3 100644 --- a/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageImport.aspx +++ b/SGGL/FineUIPro.Web/HJGL/TestPackage/TestPackageImport.aspx @@ -66,7 +66,7 @@ TextAlign="Left"> - + diff --git a/SGGL/Model/HJGL/PackagingManagePrintOutput.cs b/SGGL/Model/HJGL/PackagingManagePrintOutput.cs new file mode 100644 index 00000000..7e56c089 --- /dev/null +++ b/SGGL/Model/HJGL/PackagingManagePrintOutput.cs @@ -0,0 +1,19 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Model +{ + public class PackagingManagePrintOutput + { + public string PipelineComponentId { get; set; } + public string PipelineComponentCode { get; set; } + public DateTime? PlanStartDate { get; set; } + public string UnitWorkName { get; set; } + public string num { get; set; } + public string CU { get; set; } + public string FlowingSection { get; set; } + } +} diff --git a/SGGL/Model/Model.cs b/SGGL/Model/Model.cs index fce7a898..4692ee58 100644 --- a/SGGL/Model/Model.cs +++ b/SGGL/Model/Model.cs @@ -103845,6 +103845,8 @@ namespace Model private string _Remark; + private System.Nullable _ReceiveDate; + #region 可扩展性方法定义 partial void OnLoaded(); partial void OnValidate(System.Data.Linq.ChangeAction action); @@ -103869,6 +103871,8 @@ namespace Model partial void OnContactPhoneChanged(); partial void OnRemarkChanging(string value); partial void OnRemarkChanged(); + partial void OnReceiveDateChanging(System.Nullable value); + partial void OnReceiveDateChanged(); #endregion public HJGL_TrainNumberManage() @@ -104076,6 +104080,26 @@ namespace Model } } + [global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_ReceiveDate", DbType="DateTime")] + public System.Nullable ReceiveDate + { + get + { + return this._ReceiveDate; + } + set + { + if ((this._ReceiveDate != value)) + { + this.OnReceiveDateChanging(value); + this.SendPropertyChanging(); + this._ReceiveDate = value; + this.SendPropertyChanged("ReceiveDate"); + this.OnReceiveDateChanged(); + } + } + } + public event PropertyChangingEventHandler PropertyChanging; public event PropertyChangedEventHandler PropertyChanged; diff --git a/SGGL/Model/Model.csproj b/SGGL/Model/Model.csproj index 3ae5354e..4fd03303 100644 --- a/SGGL/Model/Model.csproj +++ b/SGGL/Model/Model.csproj @@ -235,6 +235,7 @@ +