blogs.html 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. <<<<<<< HEAD
  2. {% extends "tables/editor_table.html" %}
  3. {% block table_body %}
  4. {% for idx in range(0, length) %}
  5. <tbody>
  6. =======
  7. >>>>>>> adjust blogs table buttons and delete options
  8. <tr>
  9. <td>{{ idx }}</td>
  10. <td>{{ blogs[idx].title }}</td>
  11. <td>1</td>
  12. <td>on</td>
  13. <td>
  14. <div>
  15. <a class="btn btn-secondary btn-sm m-1" href="{{ url_for('editor.editor', url=blogs[idx].url) }}">編輯</a>
  16. <form action="{{ url_for('blogs.remove', url=blogs[idx].url) }}" method="POST">
  17. <input class="btn btn-danger" type="submit" value="Delete">
  18. </form>
  19. </div>
  20. </td>
  21. </tr>
  22. <<<<<<< HEAD
  23. </tbody>
  24. {% endfor %}
  25. {% endblock table_body %}
  26. {% block modal_body %}
  27. <form action="{{ url_for('blogs.create') }}" method="POST" enctype="multipart/form-data">
  28. <div class="form-group">
  29. {{ form.title.label(class="form-control-label") }}
  30. {{ form.title(class="form-control form-control-lg") }}
  31. {{ form.image.label(class="form-control-label") }}
  32. {{ form.image(class="form-control form-control-lg") }}
  33. {{ form.categories.label(class="form-control-label") }}
  34. {{ form.categories(class="form-control form-control-lg") }}
  35. </div>
  36. <div class="modal-footer">
  37. <button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
  38. <input class="btn btn-primary" type="submit" value="Create">
  39. </div>
  40. </form>
  41. {% endblock modal_body %}
  42. =======
  43. able buttons and delete options