branch feature/multi-ui updated (219dfb99 -> a05c2a27)
This is an automated email from the git hooks/post-receive script. New change to branch feature/multi-ui in repository pollen. See https://gitlab.nuiton.org/chorem/pollen.git from 219dfb99 GTU validation and name keeping in multi poll new a05c2a27 [ISO] lint 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 a05c2a273f452c0f7e87082057c9e72184efcb88 Author: jcouteau <couteau@codelutin.com> Date: Tue Oct 29 14:18:31 2019 +0100 [ISO] lint Summary of changes: pollen-ui-riot-js/src/main/web/js/Poll.js | 31 +++++++++++----------- .../src/main/web/tag/poll/EditVote.tag.html | 2 +- .../src/main/web/tag/poll/VotesTable.tag.html | 4 +-- 3 files changed, 19 insertions(+), 18 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/multi-ui in repository pollen. See https://gitlab.nuiton.org/chorem/pollen.git commit a05c2a273f452c0f7e87082057c9e72184efcb88 Author: jcouteau <couteau@codelutin.com> Date: Tue Oct 29 14:18:31 2019 +0100 [ISO] lint --- pollen-ui-riot-js/src/main/web/js/Poll.js | 31 +++++++++++----------- .../src/main/web/tag/poll/EditVote.tag.html | 2 +- .../src/main/web/tag/poll/VotesTable.tag.html | 4 +-- 3 files changed, 19 insertions(+), 18 deletions(-) diff --git a/pollen-ui-riot-js/src/main/web/js/Poll.js b/pollen-ui-riot-js/src/main/web/js/Poll.js index 1c6b6abf..483602d6 100644 --- a/pollen-ui-riot-js/src/main/web/js/Poll.js +++ b/pollen-ui-riot-js/src/main/web/js/Poll.js @@ -171,27 +171,28 @@ class Poll { this.questions.forEach(function(question) { if (questionId === question.id) { let indexResult = 0; - question.choices = resultsArray[indexResult++]; - question.choiceCount = this.choices.length; + question.choices = resultsArray[indexResult++]; + question.choiceCount = this.choices.length; - question.voteCountingTypeValue = resultsArray[indexResult++]; + question.voteCountingTypeValue = resultsArray[indexResult++]; - if (this.resultIsVisible) { - question.results = resultsArray[indexResult++]; - question.choices.forEach(choice => { - choice.score = question.results.scores.find(score => score.choiceId === choice.id); - }); - } + if (this.resultIsVisible) { + question.results = resultsArray[indexResult++]; + question.choices.forEach(choice => { + choice.score = question.results.scores.find(score => score.choiceId === choice.id); + }); + } - if (this.canVote) { - this.voterName = resultsArray[indexResult++].voterName; - } + if (this.canVote) { + this.voterName = resultsArray[indexResult++].voterName; + } - pageTracker.trackPoll(); + pageTracker.trackPoll(); - bus.trigger("question", question); - return Promise.resolve(this); + bus.trigger("question", question); + return Promise.resolve(this); } + return true; }); return Promise.reject(); 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 ca4f8d67..90e852aa 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 @@ -229,7 +229,7 @@ this.multi = multi2; }; - this.onPollChange = poll2 => { + this.onPollChange = poll2 => { this.poll = poll2; this.question = this.poll.questions[0]; if (this.question) { diff --git a/pollen-ui-riot-js/src/main/web/tag/poll/VotesTable.tag.html b/pollen-ui-riot-js/src/main/web/tag/poll/VotesTable.tag.html index 8367e683..122ae651 100644 --- a/pollen-ui-riot-js/src/main/web/tag/poll/VotesTable.tag.html +++ b/pollen-ui-riot-js/src/main/web/tag/poll/VotesTable.tag.html @@ -241,12 +241,12 @@ } }; - this.on('mount', function() { + this.on("mount", function() { //first load //FIXME JC191023 Ça semble pas être la bonne façon de faire :( mais ça marche ! this.loadVoteCountingTypeValue(); this.refresh(); - }) + }); </script> <style> -- To stop receiving notification emails like this one, please contact chorem.org SCM administrator <admin+scm@chorem.org>.
participants (1)
-
chorem.org scm