aboutsummaryrefslogtreecommitdiffstats
path: root/mediagoblin/templates
diff options
context:
space:
mode:
authorChristopher Allan Webber <cwebber@dustycloud.org>2011-06-03 18:43:20 -0500
committerChristopher Allan Webber <cwebber@dustycloud.org>2011-06-03 18:43:20 -0500
commit3f0679cd78363801f7b2b99a3278f416d45f5624 (patch)
tree0ef2296cf6fc1295d8cb8466a1c359199e74440a /mediagoblin/templates
parent55c74e1e4b36d56c1f3c8e69a4cbea43843093c8 (diff)
parentd5e90fe4b487e86261331fab0f7c08f12462625d (diff)
downloadmediagoblin-3f0679cd78363801f7b2b99a3278f416d45f5624.tar.lz
mediagoblin-3f0679cd78363801f7b2b99a3278f416d45f5624.tar.xz
mediagoblin-3f0679cd78363801f7b2b99a3278f416d45f5624.zip
Merge branch 'media_edit'
Diffstat (limited to 'mediagoblin/templates')
-rw-r--r--mediagoblin/templates/mediagoblin/edit/edit.html38
-rw-r--r--mediagoblin/templates/mediagoblin/user_pages/media.html3
2 files changed, 41 insertions, 0 deletions
diff --git a/mediagoblin/templates/mediagoblin/edit/edit.html b/mediagoblin/templates/mediagoblin/edit/edit.html
new file mode 100644
index 00000000..295d57eb
--- /dev/null
+++ b/mediagoblin/templates/mediagoblin/edit/edit.html
@@ -0,0 +1,38 @@
+{#
+# GNU MediaGoblin -- federated, autonomous media hosting
+# Copyright (C) 2011 Free Software Foundation, Inc
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Affero General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Affero General Public License for more details.
+#
+# You should have received a copy of the GNU Affero General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+#}
+{% extends "mediagoblin/base.html" %}
+
+{% import "/mediagoblin/utils/wtforms.html" as wtforms_util %}
+
+{% block mediagoblin_content %}
+ <h1>Edit details for {{ media.title }}</h1>
+
+ <form action="{{ request.urlgen('mediagoblin.edit.edit_media',
+ user= media.uploader().username,
+ media= media._id) }}"
+ method="POST" enctype="multipart/form-data">
+ <div class="submit_box form_box">
+ {{ wtforms_util.render_divs(form) }}
+ <div class="form_submit_buttons">
+ <input type="submit" value="submit" class="button" />
+ </div>
+ </div>
+ </form>
+ <img src="{{ request.app.public_store.file_url(
+ media['media_files']['thumb']) }}" />
+{% endblock %}
diff --git a/mediagoblin/templates/mediagoblin/user_pages/media.html b/mediagoblin/templates/mediagoblin/user_pages/media.html
index 886962d1..406fd3f6 100644
--- a/mediagoblin/templates/mediagoblin/user_pages/media.html
+++ b/mediagoblin/templates/mediagoblin/user_pages/media.html
@@ -33,6 +33,9 @@
<a href="{{ request.urlgen('mediagoblin.user_pages.user_home',
user= media.uploader().username) }}">
{{- media.uploader().username }}</a></p>
+ <p><a href="{{ request.urlgen('mediagoblin.edit.edit_media',
+ user= media.uploader().username,
+ media= media._id) }}">Edit</a></p>
{% else %}
<p>Sorry, no such media found.<p/>
{% endif %}