This commit is contained in:
iou1name 2018-07-16 12:11:19 -04:00
parent e64bd60f3f
commit bad25812ed
2 changed files with 6 additions and 6 deletions

View File

@ -253,15 +253,17 @@
<col{% if quest_post[0] != open_post_id %} style="visibility: collapse;"{% endif %}/> <col{% if quest_post[0] != open_post_id %} style="visibility: collapse;"{% endif %}/>
<col/> <col/>
<col/> <col/>
{% for option in quest_post[0]|get_options %} {% for option in options %}
{% if option[1] == quest_post[0] %}
<tr> <tr>
<td class="pollCheckBox"> <td class="pollCheckBox">
<input type="checkbox" id="pollInput-{{ option[0] }}" onchange="pollVote({{ option[0] }})"/> <input type="checkbox" id="pollInput-{{ option[0] }}" onchange="pollVote({{ option[0] }})"/>
<label for="pollInput-{{ option[0] }}"></label> <label for="pollInput-{{ option[0] }}"></label>
</td> </td>
<td class="option_text">{{ option[2] }}</td> <td class="option_text">{{ option[2] }}</td>
<td class="optionVotes">{{ option[0]|num_votes }}</td> <td class="optionVotes">0</td>
</tr> </tr>
{% endif %}
{% endfor %} {% endfor %}
</table> </table>
{% endif %} {% endif %}

View File

@ -59,10 +59,8 @@ def quest(quest_title):
open_post_id = data[4] open_post_id = data[4]
quest_posts = db.get_quest_data(quest_id) quest_posts = db.get_quest_data(quest_id)
#dice_rolls = db.get_dice_rolls(quest_id) dice_rolls = db.get_dice_rolls(quest_id)
#polls = db.get_polls(quest_id) options = db.get_poll_options(quest_id=quest_id)
#polls = {poll[0]: poll[1:] for poll in polls}
messages = db.get_chat_messages(quest_id) messages = db.get_chat_messages(quest_id)
temp = render_template('quest.html', **locals()) temp = render_template('quest.html', **locals())