fixed hard-coded static/storage, now use in_path.path_prefix

This commit is contained in:
2021-04-12 00:06:26 +10:00
parent 095b7c8333
commit ca7391e21b

View File

@@ -97,8 +97,12 @@
{% endif %}
{% for obj in entry_data %}
{% if loop.index==1 and folders %}
FIXME: hardcoded 'static/storage'
{% if cwd != 'static/storage' %}
{% if obj.type.name != "Directory" %}
{% set root=obj.in_dir.in_path.path_prefix %}
{% else %}
{% set root=obj.dir_details.in_path.path_prefix %}
{% endif %}
{% if cwd != root %}
<figure class="px-1 dir" dir={{cwd|ParentPath}}>
<span style="font-size:{{(size|int-22)/2}}" class="fa-stack">
<i style="color:grey" class="fas fa-folder fa-stack-2x"></i>