20 lines
517 B
C#
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());
|
||
|
}
|
||
|
}
|