view_playlist_settings.html 9.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206
  1. {% extends 'base.html' %}
  2. {% load humanize %}
  3. {% load static %}
  4. {% block content %}
  5. <div id="view_playlist">
  6. <br>
  7. {% if playlist.is_user_owned %}
  8. <div class="table-responsive" id="videos-div">
  9. <div id="settings-status-div" class="text-dark">
  10. </div>
  11. <div class="card bg-dark text-white mb-3">
  12. <div class="card-body">
  13. <div id="settings-form">
  14. <div class="row">
  15. <div class="col-sm-3">
  16. <h6 class="mb-0">Playlist Name</h6>
  17. </div>
  18. <div class="col-sm-9 text-white-50">
  19. <input type="text" class="form-control" name="username" id="username" value="{{ playlist.name }}">
  20. </div>
  21. </div>
  22. <hr>
  23. <div class="row">
  24. <div class="col-sm-3">
  25. <h6 class="mb-0">Owned By</h6>
  26. </div>
  27. <div class="col-sm-9 text-white-50">
  28. <input type="text" class="form-control" id="fullname" value="{{ playlist.channel_name }}" disabled>
  29. </div>
  30. </div>
  31. <hr>
  32. <div class="row">
  33. <div class="col-sm-3">
  34. <h6 class="mb-0">Playlist Description</h6>
  35. </div>
  36. <div class="col-sm-9 text-white-50">
  37. <textarea class="form-control form-text" id="summary" rows="6" placeholder="Enter a playlist description here!">{{ playlist.description }}</textarea>
  38. </div>
  39. </div>
  40. <hr>
  41. <div class="row">
  42. <div class="col-sm-3">
  43. <h6 class="mb-0">Playlist Privacy</h6>
  44. </div>
  45. <div class="col-sm-9 text-white-50">
  46. <select class="form-select w-25" id="playlistPrivacy">
  47. <option value="Public" {% if not playlist.is_private_on_yt %}selected{% endif %}>Public</option>
  48. <option value="Private" {% if playlist.is_private_on_yt %}selected{% endif %}>Private</option>
  49. </select>
  50. </div>
  51. </div>
  52. <hr>
  53. <div class="row">
  54. <div class="col-sm-3">
  55. <h6 class="mb-0">Preferences</h6>
  56. </div>
  57. <div class="col-sm-9 text-white">
  58. <div class="mb-3 form-check form-switch">
  59. <input class="form-check-input" name="open search in new tab" type="checkbox" id="openSearchCheckDefault" {% if user.profile.open_search_new_tab %} checked {% endif %}>
  60. <label class="form-check-label" for="openSearchCheckDefault">Open Search in new tab</label>
  61. </div>
  62. <div class="mb-3 form-check form-switch">
  63. <input class="form-check-input" name="auto refresh playlists" type="checkbox" id="flexSwitchCheckDefault">
  64. <label class="form-check-label" for="flexSwitchCheckDefault">Automatically refresh playlists on visit</label>
  65. </div>
  66. <div class="mb-3 form-check form-switch">
  67. <input class="form-check-input" name="hide videos" type="checkbox" id="flexSwitchCheckChecked" checked>
  68. <label class="form-check-label" for="flexSwitchCheckChecked">Hide deleted/private videos</label>
  69. </div>
  70. <div class="mb-3 form-check form-switch">
  71. <input class="form-check-input" name="confirm before deleting" type="checkbox" id="flexSwitchCheckChecked" checked>
  72. <label class="form-check-label" for="flexSwitchCheckChecked">Confirm before deleting</label>
  73. </div>
  74. </div>
  75. </div>
  76. <hr>
  77. <div class="row">
  78. <div class="col-sm-3">
  79. <h6 class="mb-0">Danger Zone</h6>
  80. </div>
  81. <div class="col-sm-9 text-white-50">
  82. <button type="button" class="btn btn-outline-danger">Delete Playlist From YouTube</button>
  83. </div>
  84. </div>
  85. </div>
  86. </div>
  87. </div>
  88. <div class="d-flex justify-content-center">
  89. <div class="btn-group">
  90. <a href="{% url 'playlist' playlist.playlist_id %}" class="btn btn-secondary me-2">Back</a>
  91. <button type="button" class="btn btn-success me-2">Save</button>
  92. </div>
  93. </div>
  94. </div>
  95. {% else %}
  96. <div class="table-responsive" id="videos-div">
  97. <div id="settings-status-div" class="text-dark">
  98. </div>
  99. <div class="card bg-dark text-white mb-3">
  100. <div class="card-body">
  101. <div id="settings-form">
  102. <div class="row">
  103. <div class="col-sm-3">
  104. <h6 class="mb-0">Playlist Name on YouTube</h6>
  105. </div>
  106. <div class="col-sm-9 text-white-50">
  107. <input type="text" class="form-control" name="username" id="username" value="{{ playlist.name }}">
  108. </div>
  109. </div>
  110. <hr>
  111. <div class="row">
  112. <div class="col-sm-3">
  113. <h6 class="mb-0">Playlist User Label</h6>
  114. </div>
  115. <div class="col-sm-9 text-white-50">
  116. <input type="text" class="form-control" name="user_label" id="user_label" placeholder="Enter a personal label you want to identify this playlist with" value="{{ playlist.user_label }}">
  117. </div>
  118. </div>
  119. <hr>
  120. <div class="row">
  121. <div class="col-sm-3">
  122. <h6 class="mb-0">Owned By</h6>
  123. </div>
  124. <div class="col-sm-9 text-white-50">
  125. <input type="text" class="form-control" id="fullname" value="{{ playlist.channel_name }}" disabled>
  126. </div>
  127. </div>
  128. <hr>
  129. <div class="row">
  130. <div class="col-sm-3">
  131. <h6 class="mb-0">Preferences</h6>
  132. </div>
  133. <div class="col-sm-9 text-white">
  134. <div class="mb-3 form-check form-switch">
  135. <input class="form-check-input" name="open search in new tab" type="checkbox" id="openSearchCheckDefault" {% if user.profile.open_search_new_tab %} checked {% endif %}>
  136. <label class="form-check-label" for="openSearchCheckDefault">Open Search in new tab</label>
  137. </div>
  138. <div class="mb-3 form-check form-switch">
  139. <input class="form-check-input" name="auto refresh playlists" type="checkbox" id="flexSwitchCheckDefault">
  140. <label class="form-check-label" for="flexSwitchCheckDefault">Automatically refresh playlists on visit</label>
  141. </div>
  142. <div class="mb-3 form-check form-switch">
  143. <input class="form-check-input" name="hide videos" type="checkbox" id="flexSwitchCheckChecked" checked>
  144. <label class="form-check-label" for="flexSwitchCheckChecked">Hide deleted/private videos</label>
  145. </div>
  146. <div class="mb-3 form-check form-switch">
  147. <input class="form-check-input" name="confirm before deleting" type="checkbox" id="flexSwitchCheckChecked" checked>
  148. <label class="form-check-label" for="flexSwitchCheckChecked">Confirm before deleting</label>
  149. </div>
  150. </div>
  151. </div>
  152. <hr>
  153. <div class="row">
  154. <div class="col-sm-3">
  155. <h6 class="mb-0">Danger Zone</h6>
  156. </div>
  157. <div class="col-sm-9 text-white-50">
  158. <button type="button" class="btn btn-outline-danger">Remove Playlist From UnTube</button>
  159. </div>
  160. </div>
  161. </div>
  162. </div>
  163. </div>
  164. <div class="d-flex justify-content-center">
  165. <div class="btn-group">
  166. <a href="{% url 'playlist' playlist.playlist_id %}" class="btn btn-secondary me-2">Back</a>
  167. <button type="button" class="btn btn-success me-2">Save</button>
  168. </div>
  169. </div>
  170. </div>
  171. {% endif %}
  172. </div>
  173. {% endblock %}