{% extends "layout.html" %}

{% block title %}
    邵武一中新闻部摄影大赛-投票系统
{% endblock %}

{% block content %}
<div class="panel panel-primary">
  <div class="panel-heading">
    <h3 class="panel-title">投票 - {{pwobj.title}}</h3>
  </div>
  <form action="" method="POST">
    {% csrf_token %}
    <table class="table table-striped">
      <tbody>
        <tr>
          <th>标题</th>
          <td>{{pwobj.title}}</td>
        </tr>
        <tr>
          <th>目前票数</th>
          <td>{{pwobj.score}}</td>
        </tr>
        <tr>
          <th>作品描述</th>
          <td>{{pwobj.desc}}</td>
        </tr>
        <tr>
          <th>投票理由</th>
          <td>
            <textarea class="form-control" name="comment" placeholder="请输入投票理由"></textarea>
          </td>
        </tr>
        <tr>
          <th>操作</th>
          <td>
            <input type="submit" class="btn btn=xs btn-primary" value="提交投票" />
          </td>
        </tr>
      </tbody>
    </table>
  </form>
</div>
<div class="panel panel-primary">
  <div class="panel-heading">
    <h3 class="panel-title">查看作品</h3>
  </div>
  <div class="panel-body">
    <img class="img-responsive" src="{{pwurl}}{{pwobj.filename}}.{{pwobj.fileext}}" />
  </div>
</div>
{% endblock %}