presence/presence_api/Controllers/GroupController/GroupController.cs
Class_Student e771fe1659 new
2024-12-06 11:51:13 +03:00

20 lines
517 B
C#

using Microsoft.AspNetCore.Mvc;
using presence.Domain.UseCase;
using System.Text.RegularExpressions;
namespace presence_api.Controllers;
[ApiController]
[Route("api/[controller]")]
public class GroupController : ControllerBase {
private readonly GroupUseCase _groupUserCase;
public GroupController(GroupUseCase groupUseCase) {
_groupUserCase = groupUseCase;
}
[HttpGet]
public ActionResult<IEnumerable<Group>> getGroups()
{
return Ok(_groupUserCase.GetAllGroups());
}
}