How to replace a file within the Asset Manager?

Running Cockpit 0.8.11, and wondering if there’s a way to replace a file with an updated copy from within the Asset Manager. If a file needs replacing, and you attempt to upload a replacement with the same filename, it uploads a new file, with a different hyperlink (/storage/uploads/5ca502fda7c2ftest.pdf for example).

This unfortunately requires you to find/replace all other places you may have used the original, outdated file. Does anyone know if there’s a way to update or replace a file within the Asset Manager?

1 Like

Interesting feature. I would like to have it, too and it shouldn’t be complicated to implement it. Without a GUI, just open a new tab and call

/assetsmanager/updateAsset?asset[_id]=original_asset_id&asset[path]=/2018/10/18/5bc8727590613replacement.png

to change the path of the asset.

Hi @EAllison,

Have you been able to find a solution?
This commit shows an updateAssets function which could work @artur ?

Thanks

Hang

1 Like