This commit is contained in:
2014-11-23 23:19:10 +01:00
parent abac4fb84c
commit b3db01b966
3 changed files with 5 additions and 5 deletions

View File

@@ -28,11 +28,11 @@ def _list_items(view, context, model, name):
'<div class="select2-container-multi">'
'<ul class="select2-choices" style="border:0;cursor:default;background:none;">%s</ul></div>' % (
''.join(['<li class="select2-search-choice" style="padding:3px 5px;">'
'<div>' + item.name + '</div></li>' for item in getattr(model, name)] )))
'<div>' + item.name + '</div></li>' for item in getattr(model, name)])))
def _list_thumbnail(view, context, model, name):
if not getattr(model,name): # model.name only does not work because name is a string
if not getattr(model, name): # model.name only does not work because name is a string
return ''
return ''
# return Markup('<img src="%s">' % url_for('static',