This is an automated email from the git hooks/post-receive script. New commit to branch feature/230_do_not_ask_for_gtu_validation_twice in repository pollen. See https://gitlab.nuiton.org/chorem/pollen.git commit e1b1e9055b5c5bed7f4911c75dbcb443db0f3d56 Author: Brendan Le Ny <bleny@codelutin.com> Date: Wed Oct 16 18:21:46 2019 +0200 Do not ask to validate GTU if already accepted by anonymous user refs #230 --- pollen-ui-riot-js/src/main/web/tag/poll/EditVote.tag.html | 6 +++++- pollen-ui-riot-js/src/main/web/tag/poll/EditVoteOrder.tag.html | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/pollen-ui-riot-js/src/main/web/tag/poll/EditVote.tag.html b/pollen-ui-riot-js/src/main/web/tag/poll/EditVote.tag.html index 3a97563f..83d352fc 100644 --- a/pollen-ui-riot-js/src/main/web/tag/poll/EditVote.tag.html +++ b/pollen-ui-riot-js/src/main/web/tag/poll/EditVote.tag.html @@ -327,7 +327,11 @@ }; this.mustValidateGtuToVote = () => { - return !this.session.isConnected(); + let anonymousAlreadyVoted = this.voteInEdition; + let voterIsRegistered = this.session.isConnected(); + let gtuAlreadyValidated = anonymousAlreadyVoted || voterIsRegistered; + let mustValidateGtuToVote = !gtuAlreadyValidated; + return mustValidateGtuToVote; }; this.getVote = () => { diff --git a/pollen-ui-riot-js/src/main/web/tag/poll/EditVoteOrder.tag.html b/pollen-ui-riot-js/src/main/web/tag/poll/EditVoteOrder.tag.html index 0246515f..44840efe 100644 --- a/pollen-ui-riot-js/src/main/web/tag/poll/EditVoteOrder.tag.html +++ b/pollen-ui-riot-js/src/main/web/tag/poll/EditVoteOrder.tag.html @@ -376,7 +376,11 @@ }; this.mustValidateGtuToVote = () => { - return !this.session.isConnected(); + let anonymousAlreadyVoted = this.voteInEdition; + let voterIsRegistered = this.session.isConnected(); + let gtuAlreadyValidated = anonymousAlreadyVoted || voterIsRegistered; + let mustValidateGtuToVote = !gtuAlreadyValidated; + return mustValidateGtuToVote; }; this.getVote = () => { -- To stop receiving notification emails like this one, please contact chorem.org SCM administrator <admin+scm@chorem.org>.