diff --git a/B3QingDaoWanFu.Web/B3QingDaoWanFu.Web.csproj b/B3QingDaoWanFu.Web/B3QingDaoWanFu.Web.csproj index 83b204f..136e4b1 100644 --- a/B3QingDaoWanFu.Web/B3QingDaoWanFu.Web.csproj +++ b/B3QingDaoWanFu.Web/B3QingDaoWanFu.Web.csproj @@ -69,11 +69,11 @@ False ..\..\..\tsref\Debug\B3Sale.dll - + False False ..\..\..\tsref\Debug\B3Sale.Web.dll - + False False D:\BwpB3Project\tsref\Debug\B3UnitedInfos.dll @@ -176,7 +176,7 @@ {b47ce3c3-c269-48b8-84a7-32360e5a9e8e} B3QingDaoWanFu - + False diff --git a/B3QingDaoWanFu.Web/Pages/TypeIOCs/CarLoadingTypeIOC.cs b/B3QingDaoWanFu.Web/Pages/TypeIOCs/CarLoadingTypeIOC.cs index be99900..2820beb 100644 --- a/B3QingDaoWanFu.Web/Pages/TypeIOCs/CarLoadingTypeIOC.cs +++ b/B3QingDaoWanFu.Web/Pages/TypeIOCs/CarLoadingTypeIOC.cs @@ -14,6 +14,7 @@ using Forks.EnterpriseServices.DataForm; using Forks.Utils; using TSingSoft.WebControls2.BillReports; using TSingSoft.WebPluginFramework; +using Forks.EnterpriseServices.BusinessInterfaces; namespace BWP.Web.Pages.TypeIOCs { @@ -27,10 +28,44 @@ namespace BWP.Web.Pages.TypeIOCs AddParameterss(dic, dmo); } + public class CarLoadingGoodsSumDetailData + { + public string Goods_Name { get; set; } + public string Goods_Code { get; set; } + public string Goods_Spec { get; set; } + public Money? Number { get; set; } + public string Goods_MainUnit { get; set; } + public Money? SecondNumber { get; set; } + public string Goods_SecondUnit { get; set; } + public string Remark { get; set; } + } + //定制打印格式【装车单】 protected void AddParameterss(IDictionary dic, CarLoading Dmo) { - + var list = new List(); + if (Dmo.BillDetails.Count > 0) { + var billInfo = Dmo.BillDetails.Select(detail => new Tuple(detail.BillTypeID, detail.BillID)).ToList(); + var query = CarLoadingUtil.GoodsSumDetailQuery(billInfo); + + using (var context = new TransactionContext()) { + using (var reader = context.Session.ExecuteReader(query)) { + while (reader.Read()) { + var data = new CarLoadingGoodsSumDetailData(); + data.Goods_Name = (string)reader[0]; + data.Goods_Code = (string)reader[1]; + data.Goods_Spec = (string)reader[2]; + data.Number = (Money?)reader[3]; + data.Goods_MainUnit = (string)reader[4]; + data.SecondNumber = (Money?)reader[5]; + data.Goods_SecondUnit = (string)reader[6]; + data.Remark = (string)reader[7]; + list.Add(data); + } + } + } + } + dic.Add("$DetailInfo3", list); PageSize = 100; dic.Add("$DetailInfo2", new Func(() => GetPrintStyle(Dmo))); diff --git a/B3QingDaoWanFu/B3QingDaoWanFu.csproj b/B3QingDaoWanFu/B3QingDaoWanFu.csproj index 1ef3550..c39bf0e 100644 --- a/B3QingDaoWanFu/B3QingDaoWanFu.csproj +++ b/B3QingDaoWanFu/B3QingDaoWanFu.csproj @@ -69,11 +69,11 @@ False ..\..\..\tsref\Debug\B3Sale.dll - + False False ..\..\..\tsref\Debug\b3saleinterface.dll - + False False D:\BwpB3Project\tsref\Debug\B3UnitedInfos.dll