branch feature/bug-on-save updated (ead48928 -> efed5010)
This is an automated email from the git hooks/post-receive script. New change to branch feature/bug-on-save in repository pollen. See https://gitlab.nuiton.org/chorem/pollen.git from ead48928 refs #248 fix choices Adding/Removing process new efed5010 refs #248 remove unvolontary commit file The 1 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "adds" were already present in the repository and have only been added to this reference. Detailed log of new commits: commit efed50106b627b0095d6ec7b61d392462315f267 Author: dcosse <cosse@codelutin.com> Date: Mon Oct 7 11:57:15 2019 +0200 refs #248 remove unvolontary commit file Summary of changes: .../java/org/chorem/pollen/rest/api/v1/ChoiceApi.java | 19 +++++-------------- 1 file changed, 5 insertions(+), 14 deletions(-) -- To stop receiving notification emails like this one, please contact chorem.org SCM administrator <admin+scm@chorem.org>.
This is an automated email from the git hooks/post-receive script. New commit to branch feature/bug-on-save in repository pollen. See https://gitlab.nuiton.org/chorem/pollen.git commit efed50106b627b0095d6ec7b61d392462315f267 Author: dcosse <cosse@codelutin.com> Date: Mon Oct 7 11:57:15 2019 +0200 refs #248 remove unvolontary commit file --- .../java/org/chorem/pollen/rest/api/v1/ChoiceApi.java | 19 +++++-------------- 1 file changed, 5 insertions(+), 14 deletions(-) diff --git a/pollen-rest-api/src/main/java/org/chorem/pollen/rest/api/v1/ChoiceApi.java b/pollen-rest-api/src/main/java/org/chorem/pollen/rest/api/v1/ChoiceApi.java index f434bdc8..328f1027 100644 --- a/pollen-rest-api/src/main/java/org/chorem/pollen/rest/api/v1/ChoiceApi.java +++ b/pollen-rest-api/src/main/java/org/chorem/pollen/rest/api/v1/ChoiceApi.java @@ -21,8 +21,6 @@ package org.chorem.pollen.rest.api.v1; * #L% */ -import org.apache.commons.logging.Log; -import org.apache.commons.logging.LogFactory; import org.chorem.pollen.persistence.entity.Choice; import org.chorem.pollen.persistence.entity.Poll; import org.chorem.pollen.persistence.entity.Question; @@ -53,15 +51,13 @@ import java.util.List; @Consumes(MediaType.APPLICATION_JSON) @Produces(MediaType.APPLICATION_JSON) public class ChoiceApi { - + @Path("polls/{pollId}/questions/{questionId}/choices") @GET public List<ChoiceBean> getChoices(@Context ChoiceService choiceService, @PathParam("pollId") PollenEntityId<Poll> pollId, @PathParam("questionId") PollenEntityId<Question> questionId) { - - Log log = LogFactory.getLog(ChoiceApi.class); - log.debug("getChoices" + " pollId:" + " questionId:" + questionId); + List<ChoiceBean> choices = choiceService.getChoices(questionId.getEntityId()); return choices; @@ -73,9 +69,7 @@ public class ChoiceApi { @PathParam("pollId") PollenEntityId<Poll> pollId, @PathParam("questionId") PollenEntityId<Question> questionId, @PathParam("choiceId") PollenEntityId<Choice> choiceId) { - - Log log = LogFactory.getLog(ChoiceApi.class); - log.debug("getChoice" + " pollId:" + " questionId:" + questionId); + return choiceService.getChoice(questionId.getEntityId(), choiceId.getEntityId()); } @@ -88,8 +82,7 @@ public class ChoiceApi { @PathParam("pollId") PollenEntityId<Poll> pollId, @PathParam("questionId") PollenEntityId<Question> questionId, ChoiceBean choice) throws InvalidFormException { - Log log = LogFactory.getLog(ChoiceApi.class); - log.debug("editChoice" + " pollId:" + " questionId:" + questionId); + return choiceService.editChoice(questionId.getEntityId(), choice); } @@ -100,9 +93,7 @@ public class ChoiceApi { @PathParam("pollId") PollenEntityId<Poll> pollId, @PathParam("questionId") PollenEntityId<Question> questionId, @PathParam("choiceId")PollenEntityId<Choice> choiceId) throws InvalidFormException { - - Log log = LogFactory.getLog(ChoiceApi.class); - log.debug("deleteChoice" + " pollId:" + " questionId:" + questionId); + choiceService.deleteChoice(questionId.getEntityId(), choiceId.getEntityId()); } -- To stop receiving notification emails like this one, please contact chorem.org SCM administrator <admin+scm@chorem.org>.
participants (1)
-
chorem.org scm