mahao
1 year ago
1 changed files with 49 additions and 105 deletions
@ -1,135 +1,79 @@ |
|||
|
|||
|
|||
using System; |
|||
using System.Collections.Generic; |
|||
using System.IO; |
|||
using System.Linq; |
|||
using System.Threading.Tasks; |
|||
using EFCore.BulkExtensions; |
|||
using Magicodes.ExporterAndImporter.Core; |
|||
using Magicodes.ExporterAndImporter.Excel; |
|||
using Microsoft.AspNetCore.Authorization; |
|||
using Microsoft.AspNetCore.Http; |
|||
using Microsoft.AspNetCore.Mvc; |
|||
using Microsoft.Extensions.Caching.Distributed; |
|||
using SettleAccount.Job.Services; |
|||
using Shouldly; |
|||
using Volo.Abp; |
|||
using Volo.Abp.Application.Dtos; |
|||
using Volo.Abp.Application.Services; |
|||
using Volo.Abp.BackgroundJobs; |
|||
using Volo.Abp.Caching; |
|||
using Volo.Abp.Domain.Repositories; |
|||
using Volo.Abp.Guids; |
|||
using Volo.Abp.ObjectMapping; |
|||
using Volo.Abp.Uow; |
|||
using Win.Abp.Snowflakes; |
|||
using Win.Sfs.BaseData.ImportExcelCommon; |
|||
using Win.Sfs.SettleAccount.CommonManagers; |
|||
using Win.Sfs.SettleAccount.Constant; |
|||
using Win.Sfs.SettleAccount.Entities.TaskJobs; |
|||
using Win.Sfs.SettleAccount.ExcelImporter; |
|||
using Win.Sfs.SettleAccount.ExportReports; |
|||
|
|||
using Win.Sfs.SettleAccount.MaterialRelationships; |
|||
using Win.Sfs.Shared.CacheBase; |
|||
using Win.Utils; |
|||
|
|||
namespace Win.Sfs.SettleAccount.Entities.TaskJobs |
|||
{ |
|||
//调整权限-派格张影导入数据时此模块她要看
|
|||
[Authorize(SettleAccountPermissions.HQ_FPlatform.Default)] |
|||
//[AllowAnonymous]
|
|||
[Route("api/settleaccount/Job")] |
|||
public class JobAppService: ApplicationService |
|||
{ |
|||
|
|||
private readonly TaskJobService _service; |
|||
public JobAppService(TaskJobService service) |
|||
{ |
|||
|
|||
_service = service; |
|||
} |
|||
|
|||
|
|||
/// <summary>
|
|||
/// 根据筛选条件获取实体列表
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
/// 请求条件包括:筛选条件列表,排序条件,数据数量,页码
|
|||
/// </remarks>
|
|||
/// <param name="input">请求条件</param>
|
|||
/// <returns>实体DTO列表</returns>
|
|||
[HttpPost] |
|||
[Route("list")] |
|||
//[Authorize(SettleAccountPermissions.Materials.Default)]
|
|||
[UnitOfWork(false)] |
|||
virtual public async Task<List<JobDto>> GetListAsync(JobRequestDto input) |
|||
{ |
|||
|
|||
|
|||
//SettleAccount.Job.Services.Report.SettleKBWithCodeExportService
|
|||
//switch (input.ServiceName)
|
|||
//{
|
|||
// case typeof(InvoiceSettledDetailDiffExportService).FullName:
|
|||
// break;
|
|||
// case "":
|
|||
// break;
|
|||
// case "":
|
|||
// break;
|
|||
// case "":
|
|||
// break;
|
|||
//}
|
|||
namespace Win.Sfs.SettleAccount.Entities.TaskJobs; |
|||
|
|||
[AllowAnonymous] |
|||
[Route("api/settleaccount/Job")] |
|||
public class JobAppService: ApplicationService |
|||
{ |
|||
private readonly TaskJobService _service; |
|||
|
|||
return await _service.GetListAsync(input); |
|||
} |
|||
public JobAppService(TaskJobService service) |
|||
{ |
|||
_service = service; |
|||
} |
|||
|
|||
/// <summary>
|
|||
/// 根据筛选条件获取实体列表
|
|||
/// </summary>
|
|||
/// <remarks>
|
|||
[HttpPost] |
|||
[Route("list")] |
|||
[UnitOfWork(false)] |
|||
public virtual async Task<List<JobDto>> GetListAsync(JobRequestDto input) |
|||
{ |
|||
return await _service.GetListAsync(input); |
|||
} |
|||
|
|||
|
|||
[HttpGet] |
|||
[Route("{id}")] |
|||
[HttpGet] |
|||
[Route("{id}")] |
|||
|
|||
//[Authorize(SettleAccountPermissions.Materials.Default)]
|
|||
[UnitOfWork(false)] |
|||
virtual public async Task<List<string>> GetUploadListAsync(string id) |
|||
{ |
|||
return await _service.GetUpFileListAsync(id); |
|||
} |
|||
//[Authorize(SettleAccountPermissions.Materials.Default)]
|
|||
[UnitOfWork(false)] |
|||
virtual public async Task<List<string>> GetUploadListAsync(string id) |
|||
{ |
|||
return await _service.GetUpFileListAsync(id); |
|||
} |
|||
|
|||
|
|||
[HttpPost] |
|||
[Route("versionlist")] |
|||
[HttpPost] |
|||
[Route("versionlist")] |
|||
|
|||
[UnitOfWork(false)] |
|||
virtual public async Task<List<string>> GetVersionListAsync() |
|||
{ |
|||
return await _service.GetVersionListAsync(); |
|||
} |
|||
[UnitOfWork(false)] |
|||
virtual public async Task<List<string>> GetVersionListAsync() |
|||
{ |
|||
return await _service.GetVersionListAsync(); |
|||
} |
|||
|
|||
|
|||
[HttpPost] |
|||
[Route("delete")] |
|||
[HttpPost] |
|||
[Route("delete")] |
|||
|
|||
|
|||
virtual public async Task<bool> DeleteListAsync(List<Guid> ids) |
|||
{ |
|||
return await _service.DeleteListAsync(ids); |
|||
} |
|||
virtual public async Task<bool> DeleteListAsync(List<Guid> ids) |
|||
{ |
|||
return await _service.DeleteListAsync(ids); |
|||
} |
|||
|
|||
|
|||
|
|||
[HttpGet] |
|||
[Route("updateRemark")] |
|||
[HttpGet] |
|||
[Route("updateRemark")] |
|||
|
|||
|
|||
virtual public async Task<bool> UpdateRemarkAsync(Guid p_id,string remark) |
|||
{ |
|||
return await _service.UpdateAsync(p_id,remark); |
|||
} |
|||
virtual public async Task<bool> UpdateRemarkAsync(Guid p_id,string remark) |
|||
{ |
|||
return await _service.UpdateAsync(p_id,remark); |
|||
} |
|||
|
|||
|
|||
} |
|||
} |
|||
|
|||
|
|||
|
Loading…
Reference in new issue