Open nateiler opened 5 years ago
What would the benefit be?
The different sites built using multi-site might not be administered by the same person. If Site B uses an asset from Site A, then Site A changes that asset, then the asset would also change on Site B. For neatness sake, it'd be much better for Site B to only see their own assets.
I've got part way there, but then discovered it's not adequate... Whilst it's possible to create separate Assets volumes in Assets for Site A & Site B and drag existing assets into their appropriate volumes. And providing appropriate permissions are set up in for each Site administrator, Site B won't see Site A's assets, Site B won't see Site A's assets.
BUT... and it's a big but...
Entries are not intelligent. They only see where Assets are as they have been defined in fields.
I'm working on a site that has one primary site and lots of other versions of the same site. I don't want any of the sites to see images from any other sites. What started off thinking it would be easy to create very similar sites is turning into a nightmare! I don't see how to progress without duplicating every Section that requires an Asset - making them unique for each site. And then that means the templates all have to be unique too, because the handles are different. I was hoping to run all sites off the same templates.
Any suggestions shall be gratefully received!
This would be a nice to have feature as there are plenty of times when I have a site within a multi-site setup which has a section not shared with any of the other sites and I have the need for a volume that will contain uploaded files specific to this site, e.g. uploaded .mp3 files for a music site which I might want to be totally separated from another site e.g. a cooking site, or a personal blog all of which could be totally unrelated to each other and have totally unrelated content in a multi-site setup.
We plan to have a bigger multi-site setup and sperated asset volumes per site would be really great. It would make right management easier. It would allow to use the site domain for the assets base domain, not a shared one. Currently also the content table is polluted with a record for every site per asset.
It's been a year since the last comment so I'd like to add my voice here that this feature would be immensely useful for a multisite build I'm working on. We're talking 3 different sites that have the same structure, but that are managed by completely different people (who only have back-end access to one of the site), and with their own content and images. I would really like each site's assets to be stored in the site's own volume.
Craft 3.4 added a new “Show unpermitted volumes” setting on Assets fields, which is disabled by default for new fields. So it’s now possible to create site-specific volumes in name/location, and assign view permissions to them according to site permissions. Then even if a single Assets field has access to all volumes, users will only be able to see the ones they are permitted to see.
Not exactly what this issue is requesting, but should get pretty close.
Thanks Brandon, that's a very nice alternative.
Similar to entries, it would be nice to define assets volumes on a per-site bases. Currently, volumes are shared across all sites and elements are propagated to all sites.
Another option would be to provide an event at
Element::getSupportedSites
method. One coupe prevent auto-propogation across all sites if they choose.Additional info