add PATCH and fix variable

This commit is contained in:
Valentin CZERYBA 2022-08-07 00:15:13 +02:00
parent be11abbd9f
commit 3a70c5e767
3 changed files with 3 additions and 3 deletions

View File

@ -364,7 +364,7 @@ public class UsersRessources {
@Consumes(MediaType.APPLICATION_JSON)
@Transactional
@Path("enable/{id}")
public Response enableUserAdmin(@Context SecurityContext ctx, @CookieParam("user") String userCookie, @QueryParam("id") String id) {
public Response enableUserAdmin(@Context SecurityContext ctx, @CookieParam("user") String userCookie, @PathParam("id") String id) {
UUID kid = UUID.fromString(jwt.getClaim(Claims.kid));
UsersEntity user = UsersEntity.findById(kid);
Response.Status status = getResponseCheck(ctx, userCookie, user);

View File

@ -29,6 +29,6 @@ quarkus.redis.hosts=redis://redis:6379
quarkus.http.cors=true
quarkus.http.origins=http://localhost:8084
quarkus.http.cors.methods=GET,PUT,POST,DELETE
quarkus.http.cors.methods=GET,PUT,POST,DELETE,PATCH
quarkus.http.cors.headers=accept,authorization,content-type,x-requested-with,x-foobar
quarkus.http.cors.access-control-allow-credentials=true