demp_with_asp/presence_api/Contollers/GroupController.cs/GroupController.cs
2024-11-07 13:35:45 +03:00

19 lines
456 B
C#

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