Browse Source

加权限

FoShanPG
44673626 3 years ago
parent
commit
e8a9e6432d
  1. 20
      src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/SettleAccountHttpApiHostModule.cs
  2. 2
      src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/UnSettleAccounts/UnSettleAccountRequestDto.cs
  3. 7
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BT_Car/BT_Car_PlatformAppService.cs
  4. 2
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/CodeSettingTables/CodeSettingAppService.cs
  5. 8
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/HQ_H/HQ_H_PlatformAppService.cs
  6. 4
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/Invoices/InvoiceAppService.cs
  7. 4
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/Prices/PriceListAppService.cs
  8. 4
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/SettleAccounts/SettleAccountAppService.cs
  9. 2
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/TaskJobs/JobAppService.cs
  10. 9
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/UnHQSettleAccounts/UnHQSettleAppService.cs
  11. 21
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/UnSettleAccounts/UnSettleAccountAppService.cs
  12. 10
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/VWKanBan/VWKanBanAppService.cs
  13. 2
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/VWScrapClaims/ScrapClaimsAppService.cs
  14. 24
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/VWSparePart/SparePartAppService.cs
  15. 8
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS-KanBan/WMSKanBanAppService.cs
  16. 8
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS-SparePart/WMSSparePartAppService.cs
  17. 2
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WMSHQHSharePartAppService.cs
  18. 2
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WMSJitAppService.cs
  19. 4
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WMSKanbanExtendAppService.cs
  20. 2
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WMSSharePart90AppService.cs
  21. 4
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WMSSharePartAppService.cs
  22. 4
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsHQCarAppService.cs
  23. 4
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsHQKBOutputAppService.cs
  24. 2
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsOneTimeSaleOutputAppService.cs
  25. 3
      src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsOutputSumInterfaceAppService.cs
  26. 4
      src/Modules/SettleAccount/src/SettleAccount.Application/Reports/ReportServices/ReportMakeService.cs
  27. 159
      src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Repository/SettleAccountJob/Report/HQCarSettledDetailDapperRepository.cs
  28. 16
      src/Modules/SettleAccount/src/SettleAccount.Job/Services/Report/HQCarSettledDetailDiffExportService.cs

20
src/Modules/SettleAccount/host/SettleAccount.HttpApi.Host/SettleAccountHttpApiHostModule.cs

@ -73,7 +73,7 @@ namespace Win.Sfs.SettleAccount
typeof(AbpBackgroundJobsHangfireModule)
//typeof(AbpEventBusRabbitMqModule)
//typeof(AbpHangfireModule)
@ -86,7 +86,7 @@ namespace Win.Sfs.SettleAccount
public override void ConfigureServices(ServiceConfigurationContext context)
{
@ -125,7 +125,7 @@ namespace Win.Sfs.SettleAccount
ConfigureBLOBTSecSummaryServices(configuration);
ConfigureHangfire(context, configuration);
//context.Services.Configure<AbpExceptionHttpStatusCodeOptions>(options =>
@ -178,9 +178,9 @@ namespace Win.Sfs.SettleAccount
{
context.Services.Configure<FormOptions>(options =>
{
options.ValueLengthLimit= int.MaxValue;
options.ValueLengthLimit = int.MaxValue;
options.MultipartBodyLengthLimit = int.MaxValue;
options.MultipartHeadersLengthLimit = int.MaxValue;
@ -411,13 +411,13 @@ namespace Win.Sfs.SettleAccount
{
context.Services.AddHangfire(config =>
{
config.UseSqlServerStorage(configuration.GetConnectionString("SettleAccountService"));
});
}
private void ConfigureCors(ServiceConfigurationContext context, IConfiguration configuration)
{
context.Services.AddCors(options =>
@ -444,7 +444,7 @@ namespace Win.Sfs.SettleAccount
public override void OnApplicationInitialization(ApplicationInitializationContext context)
{
var app = context.GetApplicationBuilder();
app.UseCorrelationId();
//app.UseVirtualFiles();
app.UseRouting();
@ -464,7 +464,7 @@ namespace Win.Sfs.SettleAccount
options.DocExpansion(DocExpansion.None); //->修改界面打开时自动折叠
});
new BackgroundJobServerOptions() { WorkerCount = 12, ServerTimeout=TimeSpan.FromSeconds(1200) };
new BackgroundJobServerOptions() { WorkerCount = 12, ServerTimeout = TimeSpan.FromSeconds(1200) };
app.UseHangfireServer();
app.UseHangfireDashboard();
app.UseAuditing();

2
src/Modules/SettleAccount/src/SettleAccount.Application.Contracts/Entities/UnSettleAccounts/UnSettleAccountRequestDto.cs

@ -75,5 +75,7 @@ namespace Win.Sfs.SettleAccount.Entities.SettleAccounts
public virtual int FileType { get; set; }
public virtual string Version { get; set; }
}
}

7
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/BT_Car/BT_Car_PlatformAppService.cs

@ -120,7 +120,6 @@ namespace Win.Sfs.SettleAccount.Entities.BT_Car
/// <returns>实体DTO</returns>
[HttpGet]
[Route("{id}")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<BT_Car_PlatformDto> GetAsync(Guid id)
{
var result = await GetFromCacheAsync(id);
@ -154,7 +153,6 @@ namespace Win.Sfs.SettleAccount.Entities.BT_Car
/// <returns></returns>
[HttpPost]
[Route("Export")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<string> ExportAsync(BT_Car_PlatformRequestDto input)
{
@ -208,7 +206,6 @@ namespace Win.Sfs.SettleAccount.Entities.BT_Car
/// <returns>实体DTO列表</returns>
[HttpPost]
[Route("list")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<PagedResultDto<BT_Car_PlatformDto>> GetListAsync(BT_Car_PlatformRequestDto input)
{
if (!string.IsNullOrEmpty(input.Version))
@ -235,7 +232,6 @@ namespace Win.Sfs.SettleAccount.Entities.BT_Car
/// <returns>实体总数</returns>
[HttpGet]
[Route("count")]
[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<long> GetTotalCountAsync(Guid branchId)
{
return await _repository.GetCountAsync(branchId);
@ -247,7 +243,6 @@ namespace Win.Sfs.SettleAccount.Entities.BT_Car
/// <returns>实体DTO列表</returns>
[HttpGet]
[Route("all")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<ListResultDto<BT_Car_PlatformDto>> GetAllAsync(Guid branchId)
{
var entities = await _repository.GetAllAsync(branchId, true);
@ -268,7 +263,6 @@ namespace Win.Sfs.SettleAccount.Entities.BT_Car
/// <returns>无</returns>
[HttpDelete]
[Route("{id}")]
/// [Authorize(SettleAccountPermissions.SettleAccounts.Delete)]
virtual public async Task DeleteAsync(Guid id)
{
await _repository.DeleteAsync(id);
@ -281,7 +275,6 @@ namespace Win.Sfs.SettleAccount.Entities.BT_Car
/// <returns>是否执行成功</returns>
[HttpPost]
[Route("delete")]
// [Authorize(SettleAccountPermissions.SettleAccounts.Delete)]
virtual public async Task<bool> DeleteListAsync(List<Guid> ids)
{
foreach (var id in ids)

2
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/CodeSettingTables/CodeSettingAppService.cs

@ -259,7 +259,7 @@ namespace Win.Sfs.SettleAccount.Entities.CodeSettingTables
/// <returns>是否导入成功</returns>
//[HttpPost]
//[Route("import")]
[Authorize(SettleAccountPermissions.CodeSettings.Create)]
//[Authorize(SettleAccountPermissions.CodeSettings.Create)]
//virtual public async Task<bool> ImportAsync(List<CodeSettingCreateDto> dtos)
//{
// var entities =ObjectMapper.Map<List<CodeSettingCreateDto>, List<CodeSetting>>(dtos);

8
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/HQ_H/HQ_H_PlatformAppService.cs

@ -30,7 +30,7 @@ namespace Win.Sfs.SettleAccount.Entities.HQ_H
/// <summary>
/// 红旗H平台导入
/// </summary>
//[Authorize(SettleAccountPermissions.HQ_HPlatform.Default)]
[Authorize(SettleAccountPermissions.HQ_HPlatform.Default)]
//[AllowAnonymous]
[Route("api/settleaccount/HQHPlatform")]
public class HQ_H_PlatformAppService : SettleAccountApplicationBase<HQ_H_Platform>, IHQ_H_PlatformAppService
@ -85,7 +85,7 @@ namespace Win.Sfs.SettleAccount.Entities.HQ_H
[HttpPost]
[Route("ExcelImport")]
[DisableRequestSizeLimit]
//[Authorize(SettleAccountPermissions.HQ_HPlatform.Create)]
[Authorize(SettleAccountPermissions.HQ_HPlatform.Create)]
public async Task<string> HQ_H_PlatformUploadExcelImport([FromForm] IFormFileCollection files, Guid branchId, string year, string period, string version, string customerCode)
{
ExportImporter _exportImporter = new ExportImporter();
@ -193,7 +193,6 @@ namespace Win.Sfs.SettleAccount.Entities.HQ_H
/// <returns>实体DTO</returns>
[HttpGet]
[Route("{id}")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<HQ_H_PlatformDto> GetAsync(Guid id)
{
var result = await GetFromCacheAsync(id);
@ -227,7 +226,6 @@ namespace Win.Sfs.SettleAccount.Entities.HQ_H
/// <returns></returns>
[HttpPost]
[Route("Export")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<string> ExportAsync(HQ_H_PlatformRequestDto input)
{
@ -281,7 +279,6 @@ namespace Win.Sfs.SettleAccount.Entities.HQ_H
/// <returns>实体DTO列表</returns>
[HttpPost]
[Route("list")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<PagedResultDto<HQ_H_PlatformDto>> GetListAsync(HQ_H_PlatformRequestDto input)
{
if (!string.IsNullOrEmpty(input.Version))
@ -320,7 +317,6 @@ namespace Win.Sfs.SettleAccount.Entities.HQ_H
/// <returns>实体DTO列表</returns>
[HttpGet]
[Route("all")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<ListResultDto<HQ_H_PlatformDto>> GetAllAsync(Guid branchId)
{
var entities = await _repository.GetAllAsync(branchId, true);

4
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/Invoices/InvoiceAppService.cs

@ -39,7 +39,7 @@ using Win.Utils;
namespace Win.Sfs.SettleAccount.Entities.Invoices
{
/// <summary>
///
/// 发票汇总导入
/// </summary>
[Route("api/settleaccount/Invoices")]
[Authorize(SettleAccountPermissions.Invoices.Default)]
@ -81,7 +81,7 @@ namespace Win.Sfs.SettleAccount.Entities.Invoices
[HttpPost]
[Route("ExcelImport")]
[DisableRequestSizeLimit]
//[Authorize(SettleAccountPermissions.Invoices.Default)]
[Authorize(SettleAccountPermissions.Invoices.Create)]
public async Task<string> InvoiceUploadExcelImport([FromForm] IFormFileCollection files, Guid branchId, string year, string period, string version, string customerCode, string factory)
{
ExportImporter _exportImporter = new ExportImporter();

4
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/Prices/PriceListAppService.cs

@ -23,9 +23,9 @@ namespace Win.Sfs.SettleAccount.Entities.Prices
/// <summary>
/// 标准价格单-相关应用服务
/// </summary>
//[Authorize(SettleAccountPermissions.PriceLists.Default)]
[Authorize(SettleAccountPermissions.PriceLists.Default)]
[Route("api/SettleAccount/PriceList")]
[AllowAnonymous]
//[AllowAnonymous]
public class PriceListAppService : ApplicationService
/*, IPriceListAppService*/
{

4
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/SettleAccounts/SettleAccountAppService.cs

@ -52,8 +52,8 @@ namespace Win.Sfs.SettleAccount.Entities.SettleAccounts
/// <summary>
/// 大众准时化结算明细导入-R3已结
/// </summary>
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
[AllowAnonymous]
[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
//[AllowAnonymous]
[Route("api/settleaccount/SettleAccount")]
public class SettleAccountAppService : SettleAccountApplicationBase<SettleAccount>, ISettleAccountAppService
{

2
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/TaskJobs/JobAppService.cs

@ -39,7 +39,7 @@ using Win.Utils;
namespace Win.Sfs.SettleAccount.Entities.TaskJobs
{
//[Authorize(SettleAccountPermissions.Reports.Default)]
[Authorize(SettleAccountPermissions.Reports.Default)]
//[AllowAnonymous]
[Route("api/settleaccount/Job")]
public class JobAppService: ApplicationService

9
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/UnHQSettleAccounts/UnHQSettleAppService.cs

@ -29,7 +29,7 @@ namespace Win.Sfs.SettleAccount.Entities.UnHQSettleAccounts
/// <summary>
/// 红旗主机场明细导入
/// </summary>
//[Authorize(SettleAccountPermissions.HQ_HPlatform.Default)]
[Authorize(SettleAccountPermissions.HQ_HPlatform.Default)]
//[AllowAnonymous]
[Route("api/settleaccount/UnHQSettle")]
public class UnHQSettleAppService : SettleAccountApplicationBase<UnHQSettleAccount>, IUnHQSettleAppService
@ -135,7 +135,6 @@ namespace Win.Sfs.SettleAccount.Entities.UnHQSettleAccounts
/// <returns>实体DTO</returns>
[HttpGet]
[Route("{id}")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<UnHQSettleDto> GetAsync(Guid id)
{
var result = await GetFromCacheAsync(id);
@ -169,7 +168,6 @@ namespace Win.Sfs.SettleAccount.Entities.UnHQSettleAccounts
/// <returns></returns>
[HttpPost]
[Route("Export")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<string> ExportAsync(UnHQSettleRequestDto input)
{
@ -223,7 +221,6 @@ namespace Win.Sfs.SettleAccount.Entities.UnHQSettleAccounts
/// <returns>实体DTO列表</returns>
[HttpPost]
[Route("list")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<PagedResultDto<UnHQSettleDto>> GetListAsync(UnHQSettleRequestDto input)
{
if (!string.IsNullOrEmpty(input.Version))
@ -250,7 +247,6 @@ namespace Win.Sfs.SettleAccount.Entities.UnHQSettleAccounts
/// <returns>实体总数</returns>
[HttpGet]
[Route("count")]
[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<long> GetTotalCountAsync(Guid branchId)
{
return await _repository.GetCountAsync(branchId);
@ -262,7 +258,6 @@ namespace Win.Sfs.SettleAccount.Entities.UnHQSettleAccounts
/// <returns>实体DTO列表</returns>
[HttpGet]
[Route("all")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<ListResultDto<UnHQSettleDto>> GetAllAsync(Guid branchId)
{
var entities = await _repository.GetAllAsync(branchId, true);
@ -283,7 +278,6 @@ namespace Win.Sfs.SettleAccount.Entities.UnHQSettleAccounts
/// <returns>无</returns>
[HttpDelete]
[Route("{id}")]
/// [Authorize(SettleAccountPermissions.SettleAccounts.Delete)]
virtual public async Task DeleteAsync(Guid id)
{
await _repository.DeleteAsync(id);
@ -296,7 +290,6 @@ namespace Win.Sfs.SettleAccount.Entities.UnHQSettleAccounts
/// <returns>是否执行成功</returns>
[HttpPost]
[Route("delete")]
// [Authorize(SettleAccountPermissions.SettleAccounts.Delete)]
virtual public async Task<bool> DeleteListAsync(List<Guid> ids)
{
foreach (var id in ids)

21
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/UnSettleAccounts/UnSettleAccountAppService.cs

@ -100,7 +100,7 @@ namespace Win.Sfs.SettleAccount.Entities.SettleAccounts
[HttpPost]
[Route("ExcelImport")]
[DisableRequestSizeLimit]
[Authorize(SettleAccountPermissions.SettleAccounts.Create)]
[Authorize(SettleAccountPermissions.UnSettleAccount.Create)]
public async Task<string> UnSettleAccountUploadExcelImport([FromForm] IFormFileCollection files, Guid branchId,
string year, string period, string version, string customerCode, string factory)
{
@ -126,7 +126,6 @@ namespace Win.Sfs.SettleAccount.Entities.SettleAccounts
/// <returns>实体DTO</returns>
[HttpGet]
[Route("{id}")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<UnSettleAccountDto> GetAsync(Guid id)
{
var result = await GetFromCacheAsync(id);
@ -163,7 +162,6 @@ namespace Win.Sfs.SettleAccount.Entities.SettleAccounts
/// <returns></returns>
[HttpPost]
[Route("Export")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<string> ExportAsync(UnSettleAccountRequestDto input)
{
@ -171,9 +169,13 @@ namespace Win.Sfs.SettleAccount.Entities.SettleAccounts
IExporter _excel = new ExcelExporter();
if (input.ParentId != Guid.Empty)
//if (input.ParentId != Guid.Empty)
//{
// input.Filters.Add(new FilterCondition() { Action = EnumFilterAction.Equal, Column = "ParentId", Logic = EnumFilterLogic.And, Value = input.ParentId.ToString() });
//}
if (input.Version != string.Empty)
{
input.Filters.Add(new FilterCondition() { Action = EnumFilterAction.Equal, Column = "ParentId", Logic = EnumFilterLogic.And, Value = input.ParentId.ToString() });
input.Filters.Add(new FilterCondition() { Action = EnumFilterAction.Equal, Column = "Version", Logic = EnumFilterLogic.And, Value = input.Version.ToString() });
}
var entities = await _repository.GetListByFilterAsync(input.BranchId, input.Filters, input.Sorting, int.MaxValue,
0, true);
@ -226,14 +228,13 @@ namespace Win.Sfs.SettleAccount.Entities.SettleAccounts
/// <returns>实体DTO列表</returns>
[HttpPost]
[Route("list")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<PagedResultDto<UnSettleAccountDto>> GetListAsync(Guid id, UnSettleAccountRequestDto input)
{
if (input.ParentId != Guid.Empty)
if (input.Version != string.Empty)
{
// var _entity = await _versionRepository.GetAsync(input.ParentId);
// input.Filters.Add(new FilterCondition() { Action = EnumFilterAction.Equal, Column = "Version", Logic = EnumFilterLogic.And, Value = _entity.Version });
input.Filters.Add(new FilterCondition() { Action = EnumFilterAction.Equal, Column = "ParentId", Logic = EnumFilterLogic.And, Value = input.ParentId.ToString() });
input.Filters.Add(new FilterCondition() { Action = EnumFilterAction.Equal, Column = "Version", Logic = EnumFilterLogic.And, Value = input.Version.ToString() });
//input.Filters.Add(new FilterCondition() { Action = EnumFilterAction.Equal, Column = "ParentId", Logic = EnumFilterLogic.And, Value = input.ParentId.ToString() });
}
else
{
@ -255,7 +256,6 @@ namespace Win.Sfs.SettleAccount.Entities.SettleAccounts
/// <returns>实体总数</returns>
[HttpGet]
[Route("count")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<long> GetTotalCountAsync(Guid branchId)
{
return await _repository.GetCountAsync(branchId);
@ -267,7 +267,6 @@ namespace Win.Sfs.SettleAccount.Entities.SettleAccounts
/// <returns>实体DTO列表</returns>
[HttpGet]
[Route("all")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<ListResultDto<UnSettleAccountDto>> GetAllAsync(Guid branchId)
{
var entities = await _repository.GetAllAsync(branchId, true);

10
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/VWKanBan/VWKanBanAppService.cs

@ -71,7 +71,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWKanBan
[HttpPost]
[Route("ExcelImport")]
[DisableRequestSizeLimit]
[Authorize(SettleAccountPermissions.SettleAccounts.Create)]
[Authorize(SettleAccountPermissions.VWKanBan.Create)]
public async Task<string> VWKanBanUploadExcelImport([FromForm] IFormFileCollection files, Guid branchId, string year, string period, string version, string customerCode)
{
if(string.IsNullOrEmpty(version))
@ -124,7 +124,6 @@ namespace Win.Sfs.SettleAccount.Entities.VWKanBan
/// <returns>实体DTO</returns>
[HttpGet]
[Route("{id}")]
[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<VWKanBanDto> GetAsync(Guid id)
{
var result = await GetFromCacheAsync(id);
@ -158,7 +157,6 @@ namespace Win.Sfs.SettleAccount.Entities.VWKanBan
/// <returns></returns>
[HttpPost]
[Route("Export")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<string> ExportAsync(VWKanBanRequestDto input)
{
@ -213,7 +211,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWKanBan
/// <returns>实体DTO列表</returns>
[HttpPost]
[Route("list")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<PagedResultDto<VWKanBanDto>> GetListAsync(VWKanBanRequestDto input)
{
@ -239,7 +237,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWKanBan
/// <returns>实体总数</returns>
[HttpGet]
[Route("count")]
[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<long> GetTotalCountAsync(Guid branchId)
{
return await _repository.GetCountAsync(branchId);
@ -285,7 +283,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWKanBan
/// <returns>是否执行成功</returns>
[HttpPost]
[Route("delete")]
// [Authorize(SettleAccountPermissions.SettleAccounts.Delete)]
virtual public async Task<bool> DeleteListAsync(List<Guid> ids)
{
foreach (var id in ids)

2
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/VWScrapClaims/ScrapClaimsAppService.cs

@ -207,7 +207,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWScrapClaims
/// <returns>实体DTO列表</returns>
[HttpPost]
[Route("list")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<PagedResultDto<ScrapClaimsDto>> GetListAsync(ScrapClaimsRequestDto input)
{
if (!string.IsNullOrEmpty(input.Version))

24
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/VWSparePart/SparePartAppService.cs

@ -30,7 +30,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWSparePart
/// 大众备件服务
/// </summary>
[Route("api/settleaccount/SparePart")]
//[Authorize(SettleAccountPermissions.SparePart.Default)]
[Authorize(SettleAccountPermissions.SparePart.Default)]
public class SparePartAppService : SettleAccountApplicationBase<SparePart>, ISparePartAppService
{
private readonly IGuidGenerator _guidGenerator;
@ -70,7 +70,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWSparePart
[HttpPost]
[Route("ExcelImport")]
[DisableRequestSizeLimit]
[Authorize(SettleAccountPermissions.SettleAccounts.Create)]
[Authorize(SettleAccountPermissions.SparePart.Create)]
public async Task<string> SparePartUploadExcelImport([FromForm] IFormFileCollection files, Guid branchId, string year, string period, string version, string customerCode)
{
if (string.IsNullOrEmpty(version))
@ -115,7 +115,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWSparePart
[HttpPost]
[Route("ExcelImport90")]
[DisableRequestSizeLimit]
//[Authorize(SettleAccountPermissions.SettleAccounts.Create)]
public async Task<string> SparePartUploadExcelImport90([FromForm] IFormFileCollection files, Guid branchId, string year, string period, string version, string customerCode)
{
if (string.IsNullOrEmpty(version))
@ -167,7 +167,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWSparePart
/// <returns>实体DTO</returns>
[HttpGet]
[Route("{id}")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<SparePartDto> GetAsync(Guid id)
{
var result = await GetFromCacheAsync(id);
@ -201,7 +201,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWSparePart
/// <returns></returns>
[HttpPost]
[Route("Export")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<string> ExportAsync(SparePartRequestDto input)
{
if (string.IsNullOrEmpty(input.Version))
@ -250,7 +250,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWSparePart
[HttpPost]
[Route("Export90")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<string> Export90Async(SparePartRequestDto input)
{
if (string.IsNullOrEmpty(input.Version))
@ -337,7 +337,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWSparePart
[HttpPost]
[Route("list")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<PagedResultDto<SparePartDto>> GetListAsync(SparePartRequestDto input)
{
if (!string.IsNullOrEmpty(input.Version))
@ -360,7 +360,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWSparePart
[HttpPost]
[Route("list90")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<PagedResultDto<SparePartDto>> GetList90Async(SparePartRequestDto input)
{
if (!string.IsNullOrEmpty(input.Version))
@ -395,7 +395,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWSparePart
/// <returns>实体总数</returns>
[HttpGet]
[Route("count")]
[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<long> GetTotalCountAsync(Guid branchId)
{
return await _repository.GetCountAsync(branchId);
@ -407,7 +407,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWSparePart
/// <returns>实体DTO列表</returns>
[HttpGet]
[Route("all")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<ListResultDto<SparePartDto>> GetAllAsync(Guid branchId)
{
var entities = await _repository.GetAllAsync(branchId, true);
@ -428,7 +428,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWSparePart
/// <returns>无</returns>
[HttpDelete]
[Route("{id}")]
/// [Authorize(SettleAccountPermissions.SettleAccounts.Delete)]
virtual public async Task DeleteAsync(Guid id)
{
await _repository.DeleteAsync(id);
@ -441,7 +441,7 @@ namespace Win.Sfs.SettleAccount.Entities.VWSparePart
/// <returns>是否执行成功</returns>
[HttpPost]
[Route("delete")]
// [Authorize(SettleAccountPermissions.SettleAccounts.Delete)]
virtual public async Task<bool> DeleteListAsync(List<Guid> ids)
{
foreach (var id in ids)

8
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS-KanBan/WMSKanBanAppService.cs

@ -30,7 +30,7 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_KanBan
/// <summary>
/// 大众看板发货明细
/// </summary>
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
[Authorize(SettleAccountPermissions.WMSJIT.Default)]
//[AllowAnonymous]
[Route("api/settleaccount/WMSVWKanBan")]
public class WMSKanBanAppService : SettleAccountApplicationBase<WMSKanBanSettle>, IWMSVWKanBanAppService
@ -126,7 +126,6 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_KanBan
/// <returns>实体DTO</returns>
[HttpGet]
[Route("{id}")]
[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<WMSVWKanBanDto> GetAsync(Guid id)
{
var result = await GetFromCacheAsync(id);
@ -160,7 +159,6 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_KanBan
/// <returns></returns>
[HttpPost]
[Route("Export")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<string> ExportAsync(WMSVWKanBanRequestDto input)
{
@ -215,7 +213,6 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_KanBan
/// <returns>实体DTO列表</returns>
[HttpPost]
[Route("list")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<PagedResultDto<WMSVWKanBanDto>> GetListAsync(WMSVWKanBanRequestDto input)
{
@ -241,7 +238,6 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_KanBan
/// <returns>实体总数</returns>
[HttpGet]
[Route("count")]
[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<long> GetTotalCountAsync(Guid branchId)
{
return await _repository.GetCountAsync(branchId);
@ -253,7 +249,6 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_KanBan
/// <returns>实体DTO列表</returns>
[HttpGet]
[Route("all")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<ListResultDto<WMSVWKanBanDto>> GetAllAsync(Guid branchId)
{
var entities = await _repository.GetAllAsync(branchId, true);
@ -287,7 +282,6 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_KanBan
/// <returns>是否执行成功</returns>
[HttpPost]
[Route("delete")]
// [Authorize(SettleAccountPermissions.SettleAccounts.Delete)]
virtual public async Task<bool> DeleteListAsync(List<Guid> ids)
{
foreach (var id in ids)

8
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS-SparePart/WMSSparePartAppService.cs

@ -33,6 +33,7 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_SparePart
/// <summary>
/// 大众备件服务
/// </summary>
[Authorize(SettleAccountPermissions.WMSJIT.Default)]
[Route("api/settleaccount/WMSSparePart")]
public class WMSSparePartAppService : SettleAccountApplicationBase<WMSSparePart>, IWMSSparePartAppService
{
@ -73,7 +74,6 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_SparePart
[HttpPost]
[Route("ExcelImport")]
[DisableRequestSizeLimit]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
public async Task<string> WMSSparePartUploadExcelImport([FromForm] IFormFileCollection files, Guid branchId, string year, string period, string version, string customerCode)
{
if (string.IsNullOrEmpty(version))
@ -125,7 +125,6 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_SparePart
/// <returns>实体DTO</returns>
[HttpGet]
[Route("{id}")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<WMSSparePartDto> GetAsync(Guid id)
{
var result = await GetFromCacheAsync(id);
@ -159,7 +158,6 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_SparePart
/// <returns></returns>
[HttpPost]
[Route("Export")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<string> ExportAsync(WMSSparePartRequestDto input)
{
if (string.IsNullOrEmpty(input.Version))
@ -216,7 +214,6 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_SparePart
/// <returns>实体DTO列表</returns>
[HttpPost]
[Route("list")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<PagedResultDto<WMSSparePartDto>> GetListAsync(WMSSparePartRequestDto input)
{
if (!string.IsNullOrEmpty(input.Version))
@ -244,7 +241,6 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_SparePart
/// <returns>实体总数</returns>
[HttpGet]
[Route("count")]
[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<long> GetTotalCountAsync(Guid branchId)
{
return await _repository.GetCountAsync(branchId);
@ -256,7 +252,6 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_SparePart
/// <returns>实体DTO列表</returns>
[HttpGet]
[Route("all")]
//[Authorize(SettleAccountPermissions.SettleAccounts.Default)]
virtual public async Task<ListResultDto<WMSSparePartDto>> GetAllAsync(Guid branchId)
{
var entities = await _repository.GetAllAsync(branchId, true);
@ -277,7 +272,6 @@ namespace Win.Sfs.SettleAccount.Entities.WMS_SparePart
/// <returns>无</returns>
[HttpDelete]
[Route("{id}")]
/// [Authorize(SettleAccountPermissions.SettleAccounts.Delete)]
virtual public async Task DeleteAsync(Guid id)
{
await _repository.DeleteAsync(id);

2
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WMSHQHSharePartAppService.cs

@ -56,7 +56,7 @@ namespace Win.Sfs.SettleAccount.Entities.SettleAccounts
/// </summary>
//[AllowAnonymous]
//[Authorize(SettleAccountPermissions.WMSHQ.Default)]
[Authorize(SettleAccountPermissions.WMSHQ.Default)]
[Route("api/settleaccount/WmsHQHSharePartoutput")]
public class WmsHQHSharePartAppService :
SettleAccountApplicationBase<WmsHQHSharePartOutPutDetial>

2
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WMSJitAppService.cs

@ -54,7 +54,7 @@ namespace Win.Sfs.SettleAccount.Entities.SettleAccounts
/// wms出库
/// </summary>
[Authorize(SettleAccountPermissions.WMSJIT.Default)]
[Route("api/settleaccount/wmsjitoutput")]
public class WMSJitAppService :

4
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WMSKanbanExtendAppService.cs

@ -53,8 +53,8 @@ namespace Win.Sfs.SettleAccount.Entities.WMS
{
[Route("api/settleaccount/wmskanbanoutputextend")]
[AllowAnonymous]
//[Authorize(SettleAccountPermissions.WMSJIT.Default)]
//[AllowAnonymous]
[Authorize(SettleAccountPermissions.WMSJIT.Default)]
public class WMSKanbanExtendAppService : SettleAccountApplicationBase<WmsWithOutKanbanOutPutDetial>
{
/// <summary>

2
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WMSSharePart90AppService.cs

@ -31,7 +31,7 @@ using WY.NewJit.Extends.PaiGe.WMS;
namespace Win.Sfs.SettleAccount.Entities.WMS
{
[Route("api/settleaccount/wmsSharePart90output")]
//[Authorize(SettleAccountPermissions.WMSJIT.Default)]
[Authorize(SettleAccountPermissions.WMSJIT.Default)]
public class WMSSharePart90AppService :
SettleAccountApplicationBase<WmsSharePart90OutPutDetial>
{

4
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WMSSharePartAppService.cs

@ -55,9 +55,9 @@ namespace Win.Sfs.SettleAccount.Entities.SettleAccounts
/// wms出库
/// </summary>
[AllowAnonymous]
//[AllowAnonymous]
[Route("api/settleaccount/wmsSharePartoutput")]
//[Authorize(SettleAccountPermissions.WMSJIT.Default)]
[Authorize(SettleAccountPermissions.WMSJIT.Default)]
public class WMSSharePartAppService :
SettleAccountApplicationBase<WmsSharePartOutPutDetial>
{

4
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsHQCarAppService.cs

@ -34,8 +34,8 @@ namespace Win.Sfs.SettleAccount.Entities.WMS
/// wms出库-一汽轿车
/// </summary>
[AllowAnonymous]
//[Authorize(SettleAccountPermissions.WMSHQ.Default)]
//[AllowAnonymous]
[Authorize(SettleAccountPermissions.WMSHQ.Default)]
[Route("api/settleaccount/WmsHQCaroutput")]
public class WmsHQCarAppService :
SettleAccountApplicationBase<WmsHQCarOutPutDetial>

4
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsHQKBOutputAppService.cs

@ -53,8 +53,8 @@ namespace Win.Sfs.SettleAccount.Entities.WMS
{
[Route("api/settleaccount/WmsHQKBOutput")]
[AllowAnonymous]
//[Authorize(SettleAccountPermissions.WMSJIT.Default)]
//[AllowAnonymous]
[Authorize(SettleAccountPermissions.WMSHQ.Default)]
public class WmsHQKBOutputAppService : SettleAccountApplicationBase<WmsHQWithOutKanbanOutPutDetial>
{
/// <summary>

2
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsOneTimeSaleOutputAppService.cs

@ -33,7 +33,7 @@ namespace Win.Sfs.SettleAccount.Entities.WMS
{
[Route("api/settleaccount/WmsOneTimeSaleOutput")]
//[AllowAnonymous]
//[Authorize(SettleAccountPermissions.WMSJIT.Default)]
[Authorize(SettleAccountPermissions.WMSJIT.Default)]
public class WmsOneTimeSaleOutputAppService : SettleAccountApplicationBase<WmsOneTimeSaleOutPutDetial>
{

3
src/Modules/SettleAccount/src/SettleAccount.Application/Entities/WMS/WmsOutputSumInterfaceAppService.cs

@ -52,12 +52,13 @@ using Win.Sfs.SettleAccount.Repository.SettleAccountJob.Report;
namespace Win.Sfs.SettleAccount.Entities.WMS
{
[Authorize(SettleAccountPermissions.WMSJIT.Default)]
[Route("api/settleaccount/WmsOutputSumInterface")]
public class WmsOutputSumInterfaceAppService :ApplicationService
{
private readonly TaskJobService _service;

4
src/Modules/SettleAccount/src/SettleAccount.Application/Reports/ReportServices/ReportMakeService.cs

@ -33,8 +33,8 @@ using Win.Sfs.SettleAccount.Repository.SettleAccountJob.Report;
namespace Win.Sfs.SettleAccount.Reports.ReportServices
{
//[Authorize(SettleAccountPermissions.Reports.Default)]
[AllowAnonymous]
[Authorize(SettleAccountPermissions.Reports.Default)]
//[AllowAnonymous]
[Route("api/settleaccount/ReportMakeService")]
public class ReportService : ApplicationService
{

159
src/Modules/SettleAccount/src/SettleAccount.EntityFrameworkCore/Repository/SettleAccountJob/Report/HQCarSettledDetailDapperRepository.cs

@ -123,10 +123,10 @@ namespace Win.Sfs.SettleAccount.Repository.SettleAccountJob.Report
/// <param name="end"></param>
/// <param name="materialGroup"></param>
/// <returns></returns>
public virtual List<HQCarSettledDetailDiff> GetHQCarSettledDetailDiffSumReportList(string version, string materialCode, string begin, string end, string materialGroup)
public virtual List<HQSumCarSettledDetailDiff> GetHQCarSettledDetailDiffSumReportList(string version, string materialCode, string begin, string end, string materialGroup)
{
List<HQCarSettledDetailDiff> _list = new List<HQCarSettledDetailDiff>();
List<HQSumCarSettledDetailDiff> _list = new List<HQSumCarSettledDetailDiff>();
string condition = " ";
@ -153,37 +153,12 @@ namespace Win.Sfs.SettleAccount.Repository.SettleAccountJob.Report
" SELECT\n" +
" ISNULL( A.Qty, 0 ) 结算数量,\n" +
" A.MaterialCode 结算物料号,\n" +
" A.StorageLocation 收货仓库,\n" +
" A.StorageLocationDesc 收货仓库描述,\n" +
" C.EstimateTypeDesc 物料组,\n" +
" C.MaterialCode Sap编码,\n" +
" C.MaterialDesc 物料描述,\n" +
" a.[AcceptanceNo] AS 结算验收单号,\n" +
" CONVERT ( VARCHAR ( 100 ), A.AcceptanceDate, 23 ) 验收单日期,\n" +
" 0 寄销库数量 \n" +
" FROM\n" +
" (\n" +
" SELECT SUM\n" +
" ( Qty ) Qty,\n" +
" MaterialCode,\n" +
" StorageLocation,\n" +
" StorageLocationDesc,\n" +
" Version,\n" +
" AcceptanceNo,\n" +
" AcceptanceDate \n" +
" FROM\n" +
" Set_BT_Car_Platform \n" +
" WHERE\n" +
" version = '{0}' \n" +
" AND StorageLocationDesc NOT LIKE '%备品%' \n" +
" GROUP BY\n" +
" MaterialCode,\n" +
" StorageLocation,\n" +
" StorageLocationDesc,\n" +
" Version,\n" +
" AcceptanceNo,\n" +
" AcceptanceDate \n" +
" ) A\n" +
" ( SELECT SUM ( Qty ) Qty, MaterialCode, Version FROM Set_BT_Car_Platform WHERE version = '{0}' AND StorageLocationDesc NOT LIKE '%备品%' GROUP BY MaterialCode, Version ) A\n" +
" LEFT JOIN Set_material AS c ON a.MaterialCode = c.CustomerPartCode \n" +
" ) temp1\n" +
" LEFT OUTER JOIN ( SELECT Price, MaterialCode FROM Set_PriceList WHERE ( Version = ( SELECT MAX ( Version ) AS Expr1 FROM Set_PriceList ) ) ) AS temp2 ON temp1.Sap编码 = temp2.MaterialCode\n" +
@ -207,7 +182,7 @@ namespace Win.Sfs.SettleAccount.Repository.SettleAccountJob.Report
//var _sql = string.Format(str, version, condition);
var _sql = string.Format(str, version);
var _query = DbConnection.Query<HQCarSettledDetailDiff>(_sql, null, null, true, 1200, null);
var _query = DbConnection.Query<HQSumCarSettledDetailDiff>(_sql, null, null, true, 1200, null);
_list = _query.ToList();
return _list;
@ -289,10 +264,10 @@ namespace Win.Sfs.SettleAccount.Repository.SettleAccountJob.Report
/// <param name="end"></param>
/// <param name="materialGroup"></param>
/// <returns></returns>
public virtual List<HQCarSettledDetailDiff> GetBJHQCarSettledDetailDiffSumReportList(string version, string materialCode, string begin, string end, string materialGroup)
public virtual List<HQSumCarSettledDetailDiff> GetBJHQCarSettledDetailDiffSumReportList(string version, string materialCode, string begin, string end, string materialGroup)
{
List<HQCarSettledDetailDiff> _list = new List<HQCarSettledDetailDiff>();
List<HQSumCarSettledDetailDiff> _list = new List<HQSumCarSettledDetailDiff>();
string condition = " ";
@ -319,37 +294,12 @@ namespace Win.Sfs.SettleAccount.Repository.SettleAccountJob.Report
" SELECT\n" +
" ISNULL( A.Qty, 0 ) 结算数量,\n" +
" A.MaterialCode 结算物料号,\n" +
" A.StorageLocation 收货仓库,\n" +
" A.StorageLocationDesc 收货仓库描述,\n" +
" C.EstimateTypeDesc 物料组,\n" +
" C.MaterialCode Sap编码,\n" +
" C.MaterialDesc 物料描述,\n" +
" a.[AcceptanceNo] AS 结算验收单号,\n" +
" CONVERT ( VARCHAR ( 100 ), A.AcceptanceDate, 23 ) 验收单日期,\n" +
" 0 寄销库数量 \n" +
" FROM\n" +
" (\n" +
" SELECT SUM\n" +
" ( Qty ) Qty,\n" +
" MaterialCode,\n" +
" StorageLocation,\n" +
" StorageLocationDesc,\n" +
" Version,\n" +
" AcceptanceNo,\n" +
" AcceptanceDate \n" +
" FROM\n" +
" Set_BT_Car_Platform \n" +
" WHERE\n" +
" version = '{0}' \n" +
" AND StorageLocationDesc LIKE '%备品%' \n" +
" GROUP BY\n" +
" MaterialCode,\n" +
" StorageLocation,\n" +
" StorageLocationDesc,\n" +
" Version,\n" +
" AcceptanceNo,\n" +
" AcceptanceDate \n" +
" ) A\n" +
" ( SELECT SUM ( Qty ) Qty, MaterialCode, Version FROM Set_BT_Car_Platform WHERE version = '{0}' AND StorageLocationDesc LIKE '%备品%' GROUP BY MaterialCode, Version ) A\n" +
" LEFT JOIN Set_material AS c ON a.MaterialCode = c.CustomerPartCode \n" +
" ) temp1\n" +
" LEFT OUTER JOIN ( SELECT Price, MaterialCode FROM Set_PriceList WHERE ( Version = ( SELECT MAX ( Version ) AS Expr1 FROM Set_PriceList ) ) ) AS temp2 ON temp1.Sap编码 = temp2.MaterialCode\n" +
@ -373,7 +323,7 @@ namespace Win.Sfs.SettleAccount.Repository.SettleAccountJob.Report
//var _sql = string.Format(str, version, condition);
var _sql = string.Format(str, version);
var _query = DbConnection.Query<HQCarSettledDetailDiff>(_sql, null, null, true, 1200, null);
var _query = DbConnection.Query<HQSumCarSettledDetailDiff>(_sql, null, null, true, 1200, null);
_list = _query.ToList();
return _list;
@ -424,24 +374,24 @@ namespace Win.Sfs.SettleAccount.Repository.SettleAccountJob.Report
[ExporterHeader(DisplayName = "收货仓库描述")]
public string { set; get; }
[ExporterHeader(DisplayName = "验收单日期")]
public string { set; get; }
[ExporterHeader(DisplayName = "结算验收单号")]
public string { set; get; }
[ExporterHeader(DisplayName = "物料组")]
public string { set; get; }
[ExporterHeader(DisplayName = "Sap编码")]
public string SAP编码 { set; get; }
[ExporterHeader(DisplayName = "结算物料号")]
public string { set; get; }
[ExporterHeader(DisplayName = "物料组")]
public string { set; get; }
[ExporterHeader(DisplayName = "物料描述")]
public string { set; get; }
[ExporterHeader(DisplayName = "验收单日期")]
public string { set; get; }
[ExporterHeader(DisplayName = "结算验收单号")]
public string { set; get; }
[ExporterHeader(DisplayName = "定价")]
public decimal { set; get; }
@ -463,38 +413,63 @@ namespace Win.Sfs.SettleAccount.Repository.SettleAccountJob.Report
}
//public class HQCarSettledDetailDiff
//{
// [ExporterHeader(DisplayName = "收货仓库")]
// public string 收货仓库 { set; get; }
// [ExporterHeader(DisplayName = "收货仓库描述")]
// public string 收货仓库描述 { set; get; }
// [ExporterHeader(DisplayName = "结算物料号")]
// public string 结算物料号 { set; get; }
public class HQSumCarSettledDetailDiff
{
public HQSumCarSettledDetailDiff()
{
}
// [ExporterHeader(DisplayName = "结算物料描述")]
// public string 物料描述 { set; get; }
// [ExporterHeader(DisplayName = "结算数量")]
// public decimal 结算数量 { set; get; }
// [ExporterHeader(DisplayName = "结算单价")]
// public decimal 结算单价 { set; get; }
// [ExporterHeader(DisplayName = "结算金额")]
// public decimal 结算金额 { set; get; }
// [ExporterHeader(DisplayName = "Sap编码")]
// public string Sap编码 { set; get; }
// [ExporterHeader(DisplayName = "物料组(车型)")]
// public string 物料组 { set; get; }
// [ExporterHeader(DisplayName = "寄销库数量")]
// public decimal 寄销库数量 { set; get; }
public HQSumCarSettledDetailDiff(string sapMaterialCode, string materialCode, string materialDesc, decimal price,
decimal selprice, decimal diffprice, decimal sumprice, decimal settleprice, decimal qty,
decimal sockQty, string metarialGroup)
{
SAP编码 = sapMaterialCode;
= materialDesc;
= materialCode;
= sockQty;
= price;
= selprice;
= diffprice;
= sumprice;
= qty;
= settleprice;
= metarialGroup;
}
[ExporterHeader(DisplayName = "物料组")]
public string { set; get; }
// [ExporterHeader(DisplayName = "是否备件")]
// public string 是否备件 { set; get; }
[ExporterHeader(DisplayName = "Sap编码")]
public string SAP编码 { set; get; }
[ExporterHeader(DisplayName = "结算物料号")]
public string { set; get; }
[ExporterHeader(DisplayName = "物料描述")]
public string { set; get; }
[ExporterHeader(DisplayName = "定价")]
public decimal { set; get; }
//}
[ExporterHeader(DisplayName = "结算单价")]
public decimal { set; get; }
[ExporterHeader(DisplayName = "结算数量")]
public decimal { set; get; }
[ExporterHeader(DisplayName = "结算金额")]
public decimal { set; get; }
[ExporterHeader(DisplayName = "价格差异")]
public decimal { set; get; }
[ExporterHeader(DisplayName = "差异总金额")]
public decimal { set; get; }
[ExporterHeader(DisplayName = "寄销库数量")]
public decimal { set; get; }
}
public class HQCarSettleQtyDiff
{
public string { set; get; }

16
src/Modules/SettleAccount/src/SettleAccount.Job/Services/Report/HQCarSettledDetailDiffExportService.cs

@ -70,22 +70,18 @@ namespace SettleAccount.Job.Services.Report
var queryStockList = from itm in _ls_sum
join itm1 in stockList on itm.SAP编码 equals itm1.SapCode into temp1
from tm1 in temp1.DefaultIfEmpty()
select new HQCarSettledDetailDiff(
select new HQSumCarSettledDetailDiff(
itm.SAP编码,
itm.,
itm.,
itm.,
itm.,
itm.,
itm.,
itm.,
itm.,
itm.,
itm.,
tm1 == null ? 0 : tm1.Qty,
itm.,
itm.,
itm.
itm.
);
@ -97,22 +93,18 @@ namespace SettleAccount.Job.Services.Report
var queryBJStockList = from itm in _ls_bj_sum
join itm1 in stockList on itm.SAP编码 equals itm1.SapCode into temp1
from tm1 in temp1.DefaultIfEmpty()
select new HQCarSettledDetailDiff(
select new HQSumCarSettledDetailDiff(
itm.SAP编码,
itm.,
itm.,
itm.,
itm.,
itm.,
itm.,
itm.,
itm.,
itm.,
itm.,
tm1 == null ? 0 : tm1.Qty,
itm.,
itm.,
itm.
itm.
);
//if (!string.IsNullOrEmpty(kanban))

Loading…
Cancel
Save