using System.Threading.Tasks; using GxPress.Repository.Interface; using GxPress.Request.HumanAffairs; using GxPress.Result.HumanAffairs; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; using Microsoft.Extensions.Logging; namespace GxPress.Api.AppControllers { /// /// App人事数据 /// [Route("api/app/human-affairs")] [ApiController] [Authorize] public class HumanAffairsController : ControllerBase { private readonly ILogger _logger; private readonly IHumanAffairsRepository _repository; public HumanAffairsController(ILogger logger, IHumanAffairsRepository repository) { _logger = logger; _repository = repository; } /// /// App人事图表 /// /// /// [HttpPost("chart")] [AllowAnonymous] public async Task GetHumanAffairsChart(HumanAffairsRequest request) { return await _repository.GetHumanAffairsChartAsync(request); } } }