Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/polls.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/js/mixins/watchPolls.js')
-rw-r--r--src/js/mixins/watchPolls.js8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/js/mixins/watchPolls.js b/src/js/mixins/watchPolls.js
index aea224ca..b34d683c 100644
--- a/src/js/mixins/watchPolls.js
+++ b/src/js/mixins/watchPolls.js
@@ -47,10 +47,16 @@ export const watchPolls = {
// load poll list only, when not in public poll
dispatches.push('polls/load')
}
- if (item.pollId === parseInt(this.$route.params.id)) {
+ if (item.pollId === parseInt(this.$route.params.id ?? this.$store.state.share.pollId)) {
// if current poll is affected, load current poll configuration
dispatches.push('poll/get')
+ // load also options and votes
+ dispatches.push('votes/list')
+ dispatches.push('options/list')
}
+ } else if (['votes', 'options'].includes(item.table)) {
+ dispatches.push('votes/list')
+ dispatches.push('options/list')
} else {
// a table of the current poll was reported, load
// corresponding stores