edit_category.html 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. {{ define "title"}}{{ t "page.edit_category.title" .category.Title }}{{ end }}
  2. {{ define "content"}}
  3. <section class="page-header">
  4. <h1>{{ t "page.edit_category.title" .category.Title }}</h1>
  5. <ul>
  6. <li>
  7. <a href="{{ route "categories" }}">{{ icon "categories" }}{{ t "menu.categories" }}</a>
  8. </li>
  9. <li>
  10. <a href="{{ route "categoryFeeds" "categoryID" .category.ID }}">{{ icon "feeds" }}{{ t "menu.feeds" }}</a>
  11. </li>
  12. <li>
  13. <a href="{{ route "createCategory" }}">{{ icon "add-category" }}{{ t "menu.create_category" }}</a>
  14. </li>
  15. </ul>
  16. </section>
  17. <form action="{{ route "updateCategory" "categoryID" .category.ID }}" method="post" autocomplete="off">
  18. <input type="hidden" name="csrf" value="{{ .csrf }}">
  19. {{ if .errorMessage }}
  20. <div class="alert alert-error">{{ t .errorMessage }}</div>
  21. {{ end }}
  22. <label for="form-title">{{ t "form.category.label.title" }}</label>
  23. <input type="text" name="title" id="form-title" value="{{ .form.Title }}" required autofocus>
  24. <label>
  25. <input type="checkbox" name="hide_globally" {{ if .form.HideGlobally }}checked{{ end }}>
  26. {{ t "form.category.hide_globally" }}
  27. </label>
  28. <div class="buttons">
  29. <button type="submit" class="button button-primary" data-label-loading="{{ t "form.submit.saving" }}">{{ t "action.update" }}</button>
  30. </div>
  31. </form>
  32. {{ end }}