0
qquestel created
1 Answer(s)
-
0
Hi
The class that the controller inherits from should be
YourProjectNameControllerBase
.[Route("api/[controller]/[action]")] public class EmployeeDashboardController : YourProjectNameControllerBase { [HttpGet("GetDashboardData")] public IActionResult GetDashboardData() { return Ok("Data"); } }
When the route is defined this way, the URL becomes: https://localhost:44301/api/EmployeeDashboard/GetDashboardData/GetDashboardData. You can update the route according to your scenario.