24 lines
899 B
Django/Jinja
24 lines
899 B
Django/Jinja
{% extends 'base.html.j2' %}
|
|
|
|
{% block title %}Edit Media{% endblock %}
|
|
|
|
{% block content %}
|
|
<h1>Edit Media</h1>
|
|
<form method="POST" enctype="multipart/form-data">
|
|
<input type="hidden" name="csrf_token" value="{{ request.session.get_csrf_token() }}">
|
|
<label for="title">Title:</label>
|
|
<input type="text" name="title" value="{{ media.title }}"><br><br>
|
|
|
|
<label for="media_file">Replace Media File (optional):</label>
|
|
<input type="file" name="media_file" accept="image/*,audio/*,video/*"><br><br>
|
|
|
|
<label>
|
|
<input type="checkbox" name="is_public" {% if media.is_public %}checked{% endif %}>
|
|
Make Media Public
|
|
</label><br><br>
|
|
|
|
<button type="submit">Update Media</button>
|
|
</form>
|
|
|
|
<p><a href="{{ request.route_url('view_media_details', namespace_short_id=namespace.short_id, media_short_id=media.short_id) }}">Back to Media Details</a></p>
|
|
{% endblock %}
|