Commit 313055fe by Alexander Kryklia

transfer images list to html

parent ccb8e96a
......@@ -816,9 +816,11 @@ class DragAndDropInput(InputTypeBase):
try:
images_list = self.system.filestore.listdir(os.path.join('static',
'images', imagepath))
images_list = ['/static/images/' + img for img in images_list]
except:
images_list = []
self.loaded_attributes['images_list'] = images_list
self.to_render.add('images_list')
registry.register(DragAndDropInput)
......
......@@ -4,7 +4,7 @@
% if images_list:
<ul>
% for item in images_list:
<li>${item}</li>
<li><image width="100" height="100" src="${item}"></image></li>
% endfor
</ul>
% endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment