//
namespace SafeCampus.Web.Core;
///
/// 单页管理控制器
///
[ApiDescriptionSettings(Tag = "单页管理")]
[Route("sys/limit/[controller]")]
[SuperAdmin]
public class SpaController : BaseController
{
private readonly ISpaService _spaService;
public SpaController(ISpaService spaService)
{
_spaService = spaService;
}
///
/// 单页分页查询
///
///
///
[HttpGet("page")]
public async Task Page([FromQuery] SpaPageInput input)
{
return await _spaService.Page(input);
}
///
/// 添加单页
///
///
///
[HttpPost("add")]
[DisplayName("添加单页")]
public async Task Add([FromBody] SpaAddInput input)
{
await _spaService.Add(input);
}
///
/// 修改单页
///
///
///
[HttpPost("edit")]
[DisplayName("修改单页")]
public async Task Edit([FromBody] SpaEditInput input)
{
await _spaService.Edit(input);
}
///
/// 删除单页
///
///
///
[HttpPost("delete")]
[DisplayName("删除单页")]
public async Task Delete([FromBody] BaseIdListInput input)
{
await _spaService.Delete(input);
}
///
/// 获取单页详情
///
///
///
[HttpGet("detail")]
public async Task Detail([FromQuery] BaseIdInput input)
{
return await _spaService.Detail(input);
}
}