38 lines
976 B
C#
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);
|
|
}
|
|
}
|