ShinyCMS icon indicating copy to clipboard operation
ShinyCMS copied to clipboard

File Manager, Clicking Files Has No Effect

Open wbraswell opened this issue 9 years ago • 3 comments

When I invoke root/admin/filemanager/view.tt I should be able to click on each file (either image or non-image) and have something happen. According to the code, CKEditor should be launched with some unknown action, which doesn't work.

[% file.filename %]

BECOMES

nmakers_home.tt

Which gives a Javascript syntax error because callFunction has a missing first argument and goes straight to a comma.

If we can't have CKEditor launched for whatever reason, we at least need to make it so that there are valid links to download the files. As it is now, we can only look at a list of files, clicking on the files does nothing!

wbraswell avatar Jan 07 '15 07:01 wbraswell

Here's my work-around code from view.tt:

    [%- IF file.image %]
<a href="/static/[% path.join( '/' ) %]/[% file.filename %]"><img src="/static/[% path.join( '/' ) IF path %]/[% file.filename %]" class="filemanager-img" alt="[% file.filename %]" title="Click to select this image"></a>
<br><a href="/static/[% path.join( '/' ) %]/[% file.filename %]">[% file.filename %]</a>
    [%- ELSE %]
<a href="/static/[% path.join( '/' ) %]/[% file.filename %]"><img src="/static/images/icons/file.png" class="filemanager-img" alt="[% file.filename %]" title="Click to select file"></a>
<br><a href="/static/[% path.join( '/' ) %]/[% file.filename %]">[% file.filename %]</a>
    [%- END %]

wbraswell avatar Jan 07 '15 07:01 wbraswell

The filepicker window is primarily designed to be launched from CKEditor, rather than vice versa. I thought it might be useful to also make it directly visible in the admin area, but in practice it's mostly just caused confusion. I may remove the link from the admin menus until a better UI can be written...

denny avatar Mar 01 '16 01:03 denny

Why can't we just have file download links?

wbraswell avatar Mar 03 '16 02:03 wbraswell