diff --git a/src/main/java/org/ntlab/acanthus_server/resources/gallery/StrokesRest.java b/src/main/java/org/ntlab/acanthus_server/resources/gallery/StrokesRest.java index 3d5c21c..e3d70d1 100644 --- a/src/main/java/org/ntlab/acanthus_server/resources/gallery/StrokesRest.java +++ b/src/main/java/org/ntlab/acanthus_server/resources/gallery/StrokesRest.java @@ -69,10 +69,28 @@ return stroke.getStrokeNo(); } + + // レイヤーごとのstrokeをすべて消去 + @Path("/{aid}/pageMap/0/layers/0/strokes") + @DELETE + @Produces(MediaType.APPLICATION_JSON) + public void deleteStrokes(@PathParam("aid") Integer aid, @FormParam("uid") Integer uid) { + var animation = gallery.getAnimationInformation(aid); + + strokes.clear(); +// if(animation != null) { +// this.Test.setStrokes(pen, color, thick); +// }else{ +// throw new WebApplicationException(401); +// } + } + + + // strokeNoを指定してstrokeを消去 @Path("/{aid}/pageMap/0/layers/0/strokes/{strokeNo}") @DELETE @Produces(MediaType.APPLICATION_JSON) - public void deleteStrokes(@PathParam("aid") Integer aid, @PathParam("strokeNo") Integer strokeNo, @FormParam("uid") Integer uid) { + public void deleteStrokeNo(@PathParam("aid") Integer aid, @PathParam("strokeNo") Integer strokeNo, @FormParam("uid") Integer uid) { var animation = gallery.getAnimationInformation(aid); int no = strokeNo;