fix 优化手动获取人员

This commit is contained in:
2024-04-02 13:18:59 +08:00
parent ae8fdf8fdc
commit 96421ed164
32 changed files with 129 additions and 72 deletions

View File

@@ -0,0 +1,30 @@
using Dlhis.ScheduledTask.Common.Dto;
using Dlhis.ScheduledTask.Common.Services;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
namespace Dlhis.ScheduledTask.TaskAssignment.Controllers;
[Authorize(Roles = "admin")]
[Route("api/[controller]")]
[ApiController]
public class HangfireController : ControllerBase
{
private readonly IHangfireService _hangfireService;
public HangfireController(IHangfireService hangfireService)
{
_hangfireService = hangfireService;
}
/// <summary>
/// 手动获取人员
/// </summary>
/// <param name="request"></param>
/// <returns></returns>
[HttpPost("sap/person/no")]
public async Task ManuallySync(SapPersonNoRequest request)
{
await _hangfireService.CreateSapPersonSyncBackgroundJobAsync(request);
}
}