From: Alexander Ebert Date: Tue, 6 Jun 2017 12:17:14 +0000 (+0200) Subject: Poll were missing the button to show participants after vote X-Git-Tag: 2.1.16~11 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=888a7d57ceab0020bca407143914fb87b90f3d28;p=GitHub%2FWoltLab%2FWCF.git Poll were missing the button to show participants after vote --- diff --git a/com.woltlab.wcf/templates/poll.tpl b/com.woltlab.wcf/templates/poll.tpl index 2bb2301247..21f68055e0 100644 --- a/com.woltlab.wcf/templates/poll.tpl +++ b/com.woltlab.wcf/templates/poll.tpl @@ -9,7 +9,7 @@ {/if} -
+
{$poll->question} {#$poll->votes} @@ -40,7 +40,7 @@ {/if} - {if $poll->canViewParticipants()} + {if $poll->canViewParticipants() || ($poll->canVote() && $poll->isPublic)} {/if} diff --git a/wcfsetup/install/files/js/WCF.Poll.js b/wcfsetup/install/files/js/WCF.Poll.js index 0a4b6847e5..0fa60e317b 100644 --- a/wcfsetup/install/files/js/WCF.Poll.js +++ b/wcfsetup/install/files/js/WCF.Poll.js @@ -483,6 +483,11 @@ WCF.Poll.Manager = Class.extend({ // display results this._canViewResult[$pollID] = true; this._canVote[$pollID] = (data.canVote) ? true : false; + + if (this._polls[$pollID].data('isPublic')) { + this._canViewParticipants[$pollID] = true; + } + this._showResult(null, $pollID); break; }