Authorizations
This commit is contained in:
parent
205845fac7
commit
997c39703a
13 changed files with 34 additions and 28 deletions
|
|
@ -18,7 +18,7 @@ namespace Yavsc.Controllers
|
|||
using Yavsc.Server.Helpers;
|
||||
|
||||
[Produces("application/json")]
|
||||
[Route("api/bookquery"), Authorize(Roles = "Performer,Administrator")]
|
||||
[Route("api/bookquery"), Authorize("Performer")]
|
||||
public class BookQueryApiController : Controller
|
||||
{
|
||||
private ApplicationDbContext _context;
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ namespace Yavsc.Controllers
|
|||
/// </summary>
|
||||
/// <param name="id"></param>
|
||||
/// <returns></returns>
|
||||
[Authorize(Roles="Performer"),HttpGet("{id}")]
|
||||
[Authorize("Performer"),HttpGet("{id}")]
|
||||
public IActionResult Get(string id)
|
||||
{
|
||||
var pfr = dbContext.Performers.Include(
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ using Yavsc.Server.Helpers;
|
|||
|
||||
namespace Yavsc.Controllers
|
||||
{
|
||||
[Produces("application/json"),Authorize(Roles="Administrator")]
|
||||
[Produces("application/json"),Authorize("AdministratorOnly")]
|
||||
[Route("api/users")]
|
||||
public class ApplicationUserApiController : Controller
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue