This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository pollen. See https://gitlab.nuiton.org/chorem/pollen.git commit a763c63df427fffbdf506d1bc2ae4ef26ff4d450 Author: Sylvain Bavencoff <bavencoff@codelutin.com> Date: Fri Jun 15 12:08:34 2018 +0200 si la premision du sondage change, mettre cette nouvelle permission dans l'url --- pollen-ui-riot-js/src/main/web/tag/poll/Votes.tag.html | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/pollen-ui-riot-js/src/main/web/tag/poll/Votes.tag.html b/pollen-ui-riot-js/src/main/web/tag/poll/Votes.tag.html index 425c8ddb..0a9d55ef 100644 --- a/pollen-ui-riot-js/src/main/web/tag/poll/Votes.tag.html +++ b/pollen-ui-riot-js/src/main/web/tag/poll/Votes.tag.html @@ -86,6 +86,7 @@ import session from "../../js/Session"; import moment from "moment"; import poll from "../../js/Poll.js"; + import route from "riot-route/lib/tag"; this.loaded = false; this.moment = moment; @@ -114,9 +115,16 @@ }; this.saveVote = (vote) => { + let oldPermission = this.poll.getPermission(); let promise = vote.id ? this.poll.updateVote(vote) : this.poll.addVote(vote); return promise.then(result => { + if (this.poll.getPermission() && oldPermission !== this.poll.getPermission()) { + setTimeout( + () => route("poll/" + this.poll.id + "/vote/" + this.poll.getPermission()), + 10 + ); + } if (this.poll.resultIsVisible) { return this.poll.loadResults().then(() => result); } -- To stop receiving notification emails like this one, please contact chorem.org SCM administrator <admin+scm@chorem.org>.