mirror of
https://github.com/Oreolek/ifhub.club.git
synced 2024-07-03 06:55:03 +03:00
25 lines
902 B
Smarty
25 lines
902 B
Smarty
{**
|
|
* Топик опрос
|
|
*
|
|
* @styles css/topic.css
|
|
* @scripts <framework>/js/livestreet/poll.js
|
|
*}
|
|
|
|
{extends file='topics/topic_base.tpl'}
|
|
|
|
{block name='topic_header_after'}
|
|
<div class="poll js-poll" data-poll-id="{$oTopic->getId()}">
|
|
{if ! $oTopic->getUserQuestionIsVote()}
|
|
<ul class="poll-list js-poll-list">
|
|
{foreach $oTopic->getQuestionAnswers() as $iItemId => $aAnswer}
|
|
<li class="poll-item js-poll-item"><label><input type="radio" name="poll-{$oTopic->getId()}" value="{$iItemId}" class="js-poll-item-option" /> {$aAnswer.text|escape:'html'}</label></li>
|
|
{/foreach}
|
|
</ul>
|
|
|
|
<button type="submit" class="button button-primary js-poll-button-vote">{$aLang.topic_question_vote}</button>
|
|
<button type="submit" class="button js-poll-button-abstain">{$aLang.topic_question_abstain}</button>
|
|
{else}
|
|
{include file='topics/poll_result.tpl'}
|
|
{/if}
|
|
</div>
|
|
{/block} |