[IMPLEMENTED] Bulk remove assets from App

We have multiple apps running on an instance. In many cases there is a primary one which has all the assets required for replicating the main app. The problem is that the replicated app will only require a small set of the assets. Currently we remove the assets by clicking the small bin next to each asset in the assets folder.

Question/Request: Is there there the option or can there be the option to either empty the whole assets folder on an app or bulk select most of them that was replicated across apps?

Thanks

Why can you not delete the folder and then recreate it?

Will that not remove the assets being references by the original app on the installation?

Yes, if you have turned on the recursive deleted in the settings (which is the default). But so far not the content itself.

Apologies, but not understanding correctly. We have APP-1 which we loaded 1000 assets on. This app is the CMS for WEBSITE 1. We then backup and restore APP-1 so we can have another app APP-2.

This means APP-2 has all the assets that were in APP-1 but we only want 10 of them or in some cases none. Currently we have to go in to the UI on APP-2 and manually tick the delete per asset. This removes the reference in APP-2 and the ASSETS folder has less assets, but in APP-1 they are still there.

Our setting in appsettings.json is:

  /*
     * True to delete assets recursively.
     */
    "deleteRecursive": true

Our File system looks like this which is the global asset folder. Even if we set the above to false, how will the other apps (APP-1, APP-3 etc) still have access to that asset?

Screenshot 2021-01-26 at 17.17.29

if you restore a backup you basically create copies of the assets. So whatever you do in APP-2 has no impact to APP-1

That is fine and we noticed that. But back to my original request, how can we bulk remove the assets in App-2? They all gets saved in one assets folder. Ideally when you create an app all the assets will be saved in a folder with that app’s reference. Same way the content api creates /app-2 and /app-1.

Can you not just delete the folder? I still don’t get it.

Which folder? The one that is in /publish/assets?

APP-1,APP-2 etc are all apps on a single squidex installtion. APP-1 was the original one (and still live) and then we back it up and restore it as APP-2, APP-3 etc.

On the restored apps we remove certain schemas and want to remove a large amount of assets.

If we remove the folder above it will remove the assets for for APP-1. APP-2 and any other

Hi,
the way I understand it
APP-1 -> assets: 1-1000 (saved in /assets folder)
APP-2 -> assets: 1-1000_Copy_of_app_1 (also saved in the same /assets folder).

APP-2 only requires 10 assets, where APP-1 requires all 1000 assets.
If T_K deletes the /assets folder both APP-1 & APP-2 would loose their assets which is clearly not ideal.
Requested feature: bulk select (like gmail’s) with 1 click delete.

I am working on improvements to the CLI and this adds a bulk endpoint for assets, which can be used to implement this feature.

This topic was automatically closed after 2 days. New replies are no longer allowed.