{% if title == "Início" %}
  {% set title = "Início" %}
{% elseif title == "Tag" %}
  {% set title = "Tag: " + tag %}
{% endif %}

{% extends 'layout.html' %}

{% block body %}
<div class="container-fluid">
  {% if messages.success %}
  <div role="alert" class="alert alert-success">
    {% for success in messages.success %}
    <div>{{ success.msg }}</div>
    {% endfor %}
  </div>
  {% endif %}
  {% if messages.error %}
  <div role="alert" class="alert alert-danger">
    {% for error in messages.error %}
    <div>{{ error.msg }}</div>
    {% endfor %}
  </div>
  {% endif %}
  {% if messages.info %}
  <div role="alert" class="alert alert-info">
    {% for info in messages.info %}
    <div>{{ info.msg }}</div>
    {% endfor %}
  </div>
  {% endif %}

</div>
<h2>Obras Pendentes</h2>
<section class="work">
    {% if user.mod %}
    <ul class="entries" style="font-size: 12pt;">
      {% for w in watch %}
      {% if w.featured == 'false' %}

      <hr>
      <b>Título: {{w.title}} </b> |
      <b>permalink</b>: {{w.permalink}} |
      <b>layout</b>: {{w.layout}} |
      <b>featured</b>: {{w.featured}} |
      <b>subtitle</b>: {{w.subtitle}} <br>
      <b>sinopse</b>: <small>{{w.sinopse}}</small> <br>
      <b>year</b>: {{w.year}} |
      <b>classind</b>: {{w.classind}} |
      <b>duration</b>: {{w.duration}} |
      <b>license</b>: {{w.license}} |
      <b>video</b>: <a href="{{w.video}}" target="_blank">{{w.video}}</a> <br>
      <b>eps</b>: {{w.eps}} |
      <b>tags</b>: {{w.tags}} |
      <b>thumb480</b>: <a href="https://libreflix.org/{{w.thumb480}}" target="_blank"><img src="{{w.thumb480}}" alt="" width="270"></a>
      <b>imgbg</b>:  <a href="https://libreflix.org/{{w.imgbg}}" target="_blank"><img src="{{w.imgbg}}" alt="" width="270"></a> <br>
      <br>
      {% if user.mod %}<a href="/edit/{{ w._id }}"><button type="button" class="btn btn-danger">Editar <i class="fa fa-edit"></i></button></a>{% endif %}
      <button formaction="/list" formmethod="post" class="btn btn-danger" value="">Rejeitar Produção</button>

      {% endif %}
      {% endfor %}
    </ul>
    {% endif %}

  <div class="centerBlock">
    <!--<a class="btn" href="#">Ver todo o conteúdo</a>-->
  </div>

</section>


{% endblock %}
