Implement base controller for shared functionality; update existing controllers to inherit from BaseController and adjust user ID handling. Add JWT authentication support and modify item retrieval methods in GameDataController.

This commit is contained in:
2025-02-15 21:57:59 -03:00
parent 6d81ff1564
commit b84599b370
10 changed files with 72 additions and 31 deletions
+1 -4
View File
@@ -4,14 +4,11 @@ using PetCompanion.Services;
namespace PetCompanion.Controllers
{
[ApiController]
[Route("api/v1/[controller]")]
public class PetController : ControllerBase
public class PetController : BaseController
{
private readonly PetService petService;
private readonly PetClassService petClassService;
private readonly ILogger<PetController> logger;
private Guid userId = Guid.Parse("f5f4b3b3-3b7b-4b7b-8b7b-7b7b7b7b7b7b");
public PetController(
ILogger<PetController> logger,