Files
jinko.yikatong/Src/Dlhis.External/Appointment/Controllers/AppointmentsController.cs
2024-09-05 15:46:27 +08:00

38 lines
976 B
C#

using Dlhis.External.Appointment.Request;
using Dlhis.External.Appointment.Services;
using Kurisu.AspNetCore.DataAccess.SqlSugar.Aop;
using Microsoft.AspNetCore.Authorization;
using Microsoft.AspNetCore.Mvc;
namespace Dlhis.External.Appointment.Controllers;
/// <summary>
/// 预约
/// </summary>
[Authorize]
[ApiController]
[Route("api/[controller]")]
public class AppointmentsController : ControllerBase
{
private readonly IAppointmentService _appointmentService;
public AppointmentsController(IAppointmentService appointmentService)
{
_appointmentService = appointmentService;
}
/// <summary>
/// 接收预约申请
/// </summary>
/// <param name="request"></param>
/// <returns></returns>
[AllowAnonymous]
[Transactional]
[IgnoreTenant]
[HttpPost("receive")]
public async Task ReceiveAsync(VisitorAppointmentReceiveRequest request)
{
await _appointmentService.ReceiveAsync(request);
}
}