summaryrefslogtreecommitdiff
path: root/design/templates/admin/insert_images.html
diff options
context:
space:
mode:
authorluxagraf <sng@luxagraf.net>2016-12-13 14:16:50 -0500
committerluxagraf <sng@luxagraf.net>2016-12-13 14:16:50 -0500
commitc2b4eee457e3b527795b674716d3d09688192fcf (patch)
treee70511a5c0150ddd19a138fab8f8ddec417c8af1 /design/templates/admin/insert_images.html
parent59efbaf5415adedde575fcc026b247800491b039 (diff)
Added video upload tools and inserting
Diffstat (limited to 'design/templates/admin/insert_images.html')
-rw-r--r--design/templates/admin/insert_images.html24
1 files changed, 12 insertions, 12 deletions
diff --git a/design/templates/admin/insert_images.html b/design/templates/admin/insert_images.html
index f9a2fa6..4841f50 100644
--- a/design/templates/admin/insert_images.html
+++ b/design/templates/admin/insert_images.html
@@ -102,20 +102,20 @@ $(function(){
<button id="add_id_image" onClick="window.parent.open('/admin/photos/luximage/add/?_to_field=id&amp;_popup=1')">Upload Image
<img src="/static/admin/img/icon-addlink.svg" alt="Add">
</button>
- <div class="up-wrapper">{% for image in images %}
+ <div class="up-wrapper">{% for object in object_list %}
<div class="item-wrapper">
- <figure class="item" >
- <img src="{% get_image_by_size image 'tn' %}" />
- <figcaption>{{image.id}} - {{image.title}} {% if image.caption %}&ndash; {{image.caption}}{%endif%}</figcaption>
+ <figure class="item" >
+ <img src="{% if object.get_type == "LuxImage" %}{% get_image_by_size object 'tn' %}{%else%}{{object.video_poster.url}}{%endif%}" />
+ <figcaption>{{object.id}} - {{object.title}} {% if object.caption %}&ndash; {{object.caption}}{%endif%}</figcaption>
</figure>
- <ul class="actions">{%if image.is_video %}
- <li><a data-is-video="true" data-src="{{image.get_video_base_url}}" data-id="{{image.id}}" data-class="vid" class="insert" href="">Insert video</a>{%else%}
- <li><a data-src="{% get_image_by_size image 'admin_insert' %}" data-id="{{image.id}}" data-class="picwide" class="insert" href="">full width</a></li>
- <li><a data-src="{% get_image_by_size image 'admin_insert' %}" data-id="{{image.id}}" data-class="picfull" class="insert" href="">column width</a></li>
- <li><a data-src="{% get_image_by_size image 'admin_insert' %}" data-id="{{image.id}}" data-class="picwide" data-caption="true" class="insert" href="">full width cap</a></li>
- <li><a data-src="{% get_image_by_size image 'admin_insert' %}" data-id="{{image.id}}" data-class="picfull" data-caption="true" class="insert" href="">column width cap</a></li>
- <li><a data-src="{% get_image_by_size image 'admin_insert' %}" data-id="{{image.id}}" data-class="cluster pic" class="insert" href="">cluster</a></li>
- <li><a href="/admin/photos/luximage/{{image.pk}}/change/">Edit Image</a></li>{%endif%}
+ <ul class="actions">{%if object.get_type == "LuxVideo" %}
+ <li><a data-is-video="true" data-src="{{object.image.url}}" data-id="{{object.id}}" data-class="vid" class="insert" href="">Insert video</a>{%else%}
+ <li><a data-src="{% get_image_by_size object 'admin_insert' %}" data-id="{{object.id}}" data-class="picwide" class="insert" href="">full width</a></li>
+ <li><a data-src="{% get_image_by_size object 'admin_insert' %}" data-id="{{object.id}}" data-class="picfull" class="insert" href="">column width</a></li>
+ <li><a data-src="{% get_image_by_size object 'admin_insert' %}" data-id="{{object.id}}" data-class="picwide" data-caption="true" class="insert" href="">full width cap</a></li>
+ <li><a data-src="{% get_image_by_size object 'admin_insert' %}" data-id="{{object.id}}" data-class="picfull" data-caption="true" class="insert" href="">column width cap</a></li>
+ <li><a data-src="{% get_image_by_size object 'admin_insert' %}" data-id="{{object.id}}" data-class="cluster pic" class="insert" href="">cluster</a></li>
+ <li><a href="/admin/photos/luximage/{{object.pk}}/change/">Edit Image</a></li>{%endif%}
</ul>
</div>
{% endfor %}