diff --git a/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsDetailCancelInterface.cs b/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsDetailCancelInterface.cs
index d5830d70..efd4ac40 100644
--- a/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsDetailCancelInterface.cs
+++ b/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsDetailCancelInterface.cs
@@ -30,6 +30,9 @@ using Win.Sfs.Shared.Filter;
namespace Win.Sfs.SettleAccount.Entities.WMS
{
+ ///
+ /// 撤销出库清单
+ ///
[Authorize(SettleAccountPermissions.WMSJIT.Default)]
[Route("api/settleaccount/WMSOutputDetailCancelDiffReport")]
public class WMSOutputDetailCancelDiffReportAppService :
diff --git a/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsDetailUnInterface.cs b/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsDetailUnInterface.cs
index e35bdee5..4699d824 100644
--- a/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsDetailUnInterface.cs
+++ b/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsDetailUnInterface.cs
@@ -30,6 +30,9 @@ using Win.Sfs.Shared.Filter;
namespace Win.Sfs.SettleAccount.Entities.WMS
{
+ ///
+ /// 出库差异清单
+ ///
[Authorize(SettleAccountPermissions.WMSJIT.Default)]
[Route("api/settleaccount/WMSOutputDetailDiffReport")]
public class WMSOutputDetailDiffReportAppService :
diff --git a/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsUnSumInterface.cs b/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsUnSumInterface.cs
index a87e60d0..3dce74fb 100644
--- a/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsUnSumInterface.cs
+++ b/src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsUnSumInterface.cs
@@ -24,6 +24,9 @@ using Win.Sfs.Shared.Filter;
namespace Win.Sfs.SettleAccount.Entities.WMS
{
+ ///
+ /// 已结算出库查询
+ ///
[Authorize(SettleAccountPermissions.WMSJIT.Default)]
[Route("api/settleaccount/WMSOutputDetailWithCodeReport")]
public class WMSOutputDetailWithCodeReportAppService :
diff --git a/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/WMS/TaskList.cs b/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/WMS/TaskList.cs
index cde2f7db..5a0c6a68 100644
--- a/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/WMS/TaskList.cs
+++ b/src/Modules/SettleAccount/src/SettleAccount.Domain/Entities/WMS/TaskList.cs
@@ -205,8 +205,91 @@ namespace Win.Sfs.SettleAccount.Entities.WMS
}
+ ///
+ /// 根据DTO自动生成模板,供前端下载模板用
+ ///
+ public class WmsCustomerKanbanOutPutDetialDTO
+ {
+ public WmsCustomerKanbanOutPutDetialDTO()
+ {
+ }
+ [ImporterHeader(Name = "客户编码")]
+ [ExporterHeader(DisplayName = "客户编码")]
+ public string CustomerCode { set; get; }
+
+ [ImporterHeader(Name = "看板编号")]
+ [ExporterHeader(DisplayName = "看板编号")]
+ //KENN号
+ public string Kanban { set; get; }
+ [ImporterHeader(Name = "客户零件号", IsIgnore = true)]
+ [ExporterHeader(DisplayName = "客户零件号", IsIgnore = true)]
+ public string MaterialCode { set; get; }
+ [ImporterHeader(Name = "交货单号")]
+ [ExporterHeader(DisplayName = "交货单号")]
+ public string WmsBillNum { set; get; }
+ //[ImporterHeader(Name = "订货看板编号")]
+ ////KENN号
+ //public string OrderBillNum { set; get; }
+ [ImporterHeader(Name = "SAP零件号")]
+ [ExporterHeader(DisplayName = "SAP零件号")]
+ //物料号
+ public string SapMaterialCode { set; get; }
+ [ImporterHeader(Name = "零件中文名称")]
+ [ExporterHeader(DisplayName = "零件中文名称")]
+ //物料描述
+ public string MaterialDesc { set; get; }
+ [ImporterHeader(Name = "物料组(车型)")]
+ [ExporterHeader(DisplayName = "物料组(车型)")]
+ //物料组(车型)
+ public string MaterialGroup { set; get; }
+ [ImporterHeader(Name = "出库库位", IsIgnore = true)]
+ [ExporterHeader(DisplayName = "出库库位", IsIgnore = true)]
+ //出库库位
+ public string OutPut { set; get; }
+ [ImporterHeader(Name = "入库库位", IsIgnore = true)]
+ [ExporterHeader(DisplayName = "入库库位", IsIgnore = true)]
+ //入库库位
+ public string InPut { set; get; }
+ [ImporterHeader(Name = "状态", IsIgnore = true)]
+ [ExporterHeader(DisplayName = "状态", IsIgnore = true)]
+ public int State { get; set; }
+ [ImporterHeader(Name = "发货零件号", IsIgnore = true)]
+ [ExporterHeader(DisplayName = "发货零件号", IsIgnore = true)]
+ ///
+ /// 扩展字段1
+ ///
+ public string Extend1 { set; get; }
+
+ [ImporterHeader(Name = "收货仓库", IsIgnore = true)]
+ [ExporterHeader(DisplayName = "收货仓库", IsIgnore = true)]
+ public string Extend2 { set; get; }
+ ///
+ /// 扩展字段3
+ ///
+ [ImporterHeader(Name = "版本号", IsIgnore = true)]
+ [ExporterHeader(DisplayName = "版本号", IsIgnore = true)]
+ public string Version { set; get; }
+ [ImporterHeader(Name = "结算数量")]
+ [ExporterHeader(DisplayName = "结算数量")]
+ public decimal Qty { set; get; }
+ [ImporterHeader(Name = "结算单价")]
+ [ExporterHeader(DisplayName = "结算单价")]
+ public decimal Price { set; get; }
+ [ImporterHeader(Name = "结算金额")]
+ [ExporterHeader(DisplayName = "结算金额")]
+ public decimal Amt { set; get; }
+ [ImporterHeader(Name = "数量", IsIgnore = true)]
+ [ExporterHeader(DisplayName = "数量", IsIgnore = true)]
+ public string BillNum { set; get; }
+ [ImporterHeader(Name = "任务描述", IsIgnore = true)]
+ [ExporterHeader(DisplayName = "任务描述", IsIgnore = true)]
+ public Guid TaskId { set; get; }
+
+
+
+ }
diff --git a/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Repository/SettleAccountJob/Report/WmsOutputSumDapperRepository.cs b/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Repository/SettleAccountJob/Report/WmsOutputSumDapperRepository.cs
index 6e1618f5..7e5afeb7 100644
--- a/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Repository/SettleAccountJob/Report/WmsOutputSumDapperRepository.cs
+++ b/src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Repository/SettleAccountJob/Report/WmsOutputSumDapperRepository.cs
@@ -1107,6 +1107,7 @@ namespace Win.Sfs.SettleAccount.Repository.SettleAccountJob.Report
"WHERE\n" +
" VERSION = '{0}' \n" +
" AND STATE = 3 union all \n"+
+
"SELECT\n" +
"'自定义发货出库' AS Type,\n" +
"customercode Client,\n" +
@@ -1300,7 +1301,26 @@ namespace Win.Sfs.SettleAccount.Repository.SettleAccountJob.Report
" AND State =2 \n" +
- "Union All\n"+
+ "UNION ALL\n" +
+"SELECT\n" +
+" '一次性销售' AS TYPE,\n" +
+" '一次性销售' Client,\n" +
+" BillNum,\n" +
+" SapMaterialCode,\n" +
+" Qty Qty,\n" +
+" RealityNumber OutputQty,\n" +
+" 0 IsBack,\n" +
+" Price,\n" +
+" '' CNumber,\n" +
+" Remark \n" +
+"FROM\n" +
+" Set_WmsOneTimeSaleOutPutDetial \n" +
+"WHERE\n" +
+" VERSION = '{0}' \n" +
+" AND STATE = 2 \n" +
+
+
+ "Union All\n" +
"SELECT\n" +
"'自定义发货出库' AS Type,\n" +
diff --git a/src/Modules/SettleAccount/src/SettleAccount.HttpApi/BlobFileController.cs b/src/Modules/SettleAccount/src/SettleAccount.HttpApi/BlobFileController.cs
index 4e770381..f4ce3929 100644
--- a/src/Modules/SettleAccount/src/SettleAccount.HttpApi/BlobFileController.cs
+++ b/src/Modules/SettleAccount/src/SettleAccount.HttpApi/BlobFileController.cs
@@ -38,12 +38,16 @@ namespace Win.Sfs.SettleAccount
return File(fileDto.Content, "application/octet-stream", fileDto.Name);
}
+ ///
+ /// 生成其他出库导入模板
+ ///
+ ///
[HttpPost]
[Route("saveCustomExcelTemplate")]
- public async Task SaveSalesContractExcelImportTemplate()
+ public async Task SaveCustomExcelImportTemplate()
{
- string fileName = "大众通用看板模板.xlsx";
- var result = await Importer.GenerateTemplateBytes();
+ string fileName = "客户自定义发货结算导入模板.xlsx";
+ var result = await Importer.GenerateTemplateBytes();
result.ShouldNotBeNull();
result.Length.ShouldBeGreaterThan(0);
await _excelImportService.SaveBlobAsync(
@@ -53,15 +57,6 @@ namespace Win.Sfs.SettleAccount
Content = result
}
);
- Stream stream = new MemoryStream(result);
- using (var pck = new ExcelPackage(stream))
- {
- pck.Workbook.Worksheets.Count.ShouldBe(1);
- var sheet = pck.Workbook.Worksheets.First();
- var attr = typeof(WmsCustomerKanbanOutPutDetial).GetAttribute();
- var text = sheet.Cells["A1"].Text.Replace("\n", string.Empty).Replace("\r", string.Empty);
- text.ShouldBe(attr.ImportDescription.Replace("\n", string.Empty).Replace("\r", string.Empty));
- }
return fileName;
}