% extends [% extends "../../base/templates/base.html" %] % import 'lib.html' as lib with context % import 'actions.html' as actionlib with context % import 'row_actions.html' as row_actions with context % block body

Storage

% if actions
% if actions [[ actionlib.dropdown(actions) ]] % else
% endif
% if admin_view.can_create
% if admin_view.create_modal [[ lib.add_modal_button(url=get_url('.create_view', url=return_url, modal=True), title=_gettext('Create New Record'), content=_gettext('Create'), btn_class='button is-link') ]] % else [[ _gettext('Create') ]] % endif
% endif
% endif % block file_list_table
% block list_header scoped % if actions % endif % for column in admin_view.column_list % endfor % block list_row_actions_header % if admin_view.column_display_actions % endif % endblock % if sort_by_position % endif % endblock list_header % for name, path in items % set user = decode_filename(name)['user'] % if not name in active_media % else % endif % block list_row scoped % if actions % endif % if name in image_items % elif name in video_items % endif % if admin_view.is_column_visible('size') % endif % if admin_view.is_column_visible('date') % endif % if sort_by_position % endif % endblock list_row % endfor
% if admin_view.is_column_sortable(column) % if sort_column == column [[ admin_view.column_label(column) ]] % if sort_desc % else % endif % else [[ admin_view.column_label(column) ]] % endif % else [[ _gettext(admin_view.column_label(column)) ]] % endif Action Move
[% if not name in active_media and admin_view.can_delete and path and (not current_user.has_role('contributor') or user.id == current_user.id) %] % endif [[ size|filesizeformat ]] [[ timestamp|format_date(date) ]] % block list_row_actions scoped
% if admin_view.can_view % if name in image_items
[# [[ action.render_ctx(get_pk_value(row), row) ]]#]
% elif name in video_items % endif % endif % if admin_view.can_download % endif
[% if admin_view.can_delete and path and not name in active_media and (not current_user.has_role('contributor') or user.id == current_user.id) %] [% if (not name|replace('_thumb', '') in active_media) %]
[[ delete_form.path(value=path) ]] [[ delete_form.csrf_token ]]
% endif % endif
% endblock list_row_actions
% endblock file_list_table % block actions [[ actionlib.form(actions, get_url('.action_view')) ]] % endblock actions % endblock body % block tail_js [[ super() ]] [[ actionlib.script(_gettext('Please select at least one file.'), actions, actions_confirmation) ]] % endblock tail_js