diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/BQ/Dtos/BBAC_CAN_SA_DTO.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/BQ/Dtos/BBAC_CAN_SA_DTO.cs index 5b0feba9..61de0431 100644 --- a/code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/BQ/Dtos/BBAC_CAN_SA_DTO.cs +++ b/code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/BQ/Dtos/BBAC_CAN_SA_DTO.cs @@ -74,14 +74,10 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Dtos /// 零件号 /// public string LU { get; set; } - - /// /// 物料描述 /// public string MaterialDesc { get; set; } - - /// /// 生产号 /// @@ -98,20 +94,15 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Dtos /// 金额 /// public decimal Amt { get; set; } - - + /// + /// 合同号 + /// public string ContractDocID { set; get; } - - /// /// 客户零件号 /// - public string PartCode { get; set; } - - - } public class BBAC_CAN_SA_DETAIL_EXP_DTO { @@ -152,8 +143,6 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Dtos [ExporterHeader(DisplayName = "物料描述")] public string MaterialDesc { get; set; } - - [ExporterHeader(DisplayName = "生产码")] public string PN { get; set; } public string KeyCode { get; set; } @@ -231,10 +220,11 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Dtos public int Version { get; set; } //[Display(Name = "单价")] //public decimal Price { get; set; } - [Display(Name = "发票分组号")] /// /// /// + [Display(Name = "发票分组号")] + public string BillNum { get; set; } [Display(Name = "下线日期")] public DateTime SettleDate { get; set; } diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/BQ/Dtos/INVOICE_GRP_DTO.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/BQ/Dtos/INVOICE_GRP_DTO.cs index cbb6f8f7..23706fcd 100644 --- a/code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/BQ/Dtos/INVOICE_GRP_DTO.cs +++ b/code/src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/BQ/Dtos/INVOICE_GRP_DTO.cs @@ -172,7 +172,6 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Dtos /// 发票明细 /// public List INVOICE_WAIT_DETAIL { get; set; } - /// /// 发票和结算分组对应关系 /// @@ -181,15 +180,11 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Dtos /// 已结分组包含不可结算零件 /// public List INVOICE_NOT_SETTLE { get; set; } - /// /// 发票调整明细 /// public List ADJ_DETAIL { get; set; } - - - } public class INVOICE_WAIT_DETAIL_DTO : EntityDto @@ -216,6 +211,15 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Dtos /// [Display(Name = "零件号")] public string LU { get; set; } + + /// + ///零件号 + /// + [Display(Name = "客户零件号")] + public string PartCode { get; set; } + + + /// ///单价 /// @@ -241,20 +245,16 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Dtos /// [Display(Name = "扩展字段1")] public string Extend1 { get; set; } - /// - ///扩展字段2 - /// - [Display(Name = "扩展字段2")] - public string Extend2 { get; set; } + /// ///扩展字段3 /// - [Display(Name = "扩展字段3")] + [Display(Name = "价格开始日期")] public DateTime BeginDate { get; set; } /// ///扩展字段4 /// - [Display(Name = "扩展字段4")] + [Display(Name = "价格结束日期")] public DateTime EndDate { get; set; } } diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/INVOICE_WAIT_DETAIL.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/INVOICE_WAIT_DETAIL.cs index 17b8f913..ce5d27cf 100644 --- a/code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/INVOICE_WAIT_DETAIL.cs +++ b/code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/INVOICE_WAIT_DETAIL.cs @@ -20,6 +20,11 @@ public class INVOICE_WAIT_DETAIL :FullAuditedAggregateRoot [Display(Name = "零件号")] public string LU { get; set; } = null!; + + [Display(Name = "客户零件号")] + public string PartCode { get; set; } = null!; + + [Display(Name = "单价")] public decimal PRICE { get; set; } @@ -48,7 +53,7 @@ public class INVOICE_WAIT_DETAIL :FullAuditedAggregateRoot - public INVOICE_WAIT_DETAIL(Guid guid, int version, string invbillNum, string invGroupNum, string lU, decimal pRICE, decimal qty, decimal amt, EnumBusinessType bussiessType, string extend1, string extend2,DateTime beginDate,DateTime endDate) + public INVOICE_WAIT_DETAIL(Guid guid, int version, string invbillNum, string invGroupNum, string lU, decimal pRICE, decimal qty, decimal amt, EnumBusinessType bussiessType, string extend1, string extend2,DateTime beginDate,DateTime endDate,string partcode) { Id = guid; Version = version; @@ -63,6 +68,7 @@ public class INVOICE_WAIT_DETAIL :FullAuditedAggregateRoot Extend2 = extend2; BeginDate = beginDate; EndDate = endDate; + PartCode = partcode; } diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/Managers/INV_MNG.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/Managers/INV_MNG.cs index b61d082d..a64ed0ff 100644 --- a/code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/Managers/INV_MNG.cs +++ b/code/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/BQ/Managers/INV_MNG.cs @@ -840,16 +840,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers public virtual async Task Reject(string groupbillNum) { - - var ls = await _repository.Where(p => p.InvGroupNum == groupbillNum).ToListAsync(); - - - - - - - if (ls != null && ls.Count > 0) { var count=ls.Select(p => p.State).Distinct().Count(); @@ -1030,7 +1021,6 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers where tm == null select new TMEP_INV { - LU = itm.LU, Amt = itm.Amt, Qty = itm.Qty, @@ -1100,7 +1090,8 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers extend1: string.Empty, extend2: string.Empty, beginDate: detail.BeginDate, - endDate: detail.EndDate + endDate: detail.EndDate, + partcode:detail.PartCode )); } if (_entityDetailList.Count > 0) @@ -1335,7 +1326,9 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers extend1: string.Empty, extend2: string.Empty, beginDate: detail.BeginDate, - endDate: detail.EndDate + endDate: detail.EndDate, + partcode:detail.PartCode + )); } if (_entityDetailList.Count > 0) @@ -1406,14 +1399,8 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers _invls = invlist.Select(p => p.InvbillNum).ToList(); } return _invls; - } - - - - - /// /// 第一次开票 /// @@ -1509,7 +1496,7 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers var detailDtos = dtos.Where(p => ls.Contains(p.GroupNum)).GroupBy(p => new { p.InvGroupNum, p.PartCode, p.Price, p.BeginDate, p.EndDate, p.ContractDocID }) .Select(itm => new { - + PartCode=itm.Key.PartCode, InvGroupNum = itm.Key.InvGroupNum, LU = itm.Key.PartCode, ContactDocID = itm.Key.ContractDocID, @@ -1551,7 +1538,6 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers invbillNum: key, invGroupNum: p_InvGroupNum, lU: detail.LU, - qty: detail.Qty, bussiessType: businessType, amt: detail.Amt, @@ -1559,7 +1545,8 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers extend1: string.Empty, extend2: string.Empty, beginDate: detail.BeginDate, - endDate: detail.EndDate + endDate: detail.EndDate, + partcode:detail.PartCode )); } if (_entityDetailList.Count > 0) @@ -1625,8 +1612,6 @@ namespace Win.Sfs.SettleAccount.Entities.BQ.Managers { await _repository.DbContext.BulkInsertAsync(notDetialList); } - - _invls = invlist.Select(p => p.InvbillNum).ToList(); } diff --git a/code/src/Modules/SettleAccount/src/SettleAccount.Domain/EnumBillState.cs b/code/src/Modules/SettleAccount/src/SettleAccount.Domain/EnumBillState.cs index bb130304..5c527381 100644 --- a/code/src/Modules/SettleAccount/src/SettleAccount.Domain/EnumBillState.cs +++ b/code/src/Modules/SettleAccount/src/SettleAccount.Domain/EnumBillState.cs @@ -39,14 +39,9 @@ namespace Win.Sfs.SettleAccount 正常 = 1, [Description("报废")] 报废 = 2, - [Description("替换")] - 替换 = 3, - [Description("提交")] 提交 = 3, - - } public enum BusinessType