silverstripe-populate
silverstripe-populate copied to clipboard
Locations of populated images are not recognized by the CMS
I've started using the "Default assets". I love the concept, though it seems images that are placed in a directory are not properly picked up by the CMS.
It takes for me to sync assets via the cms for this to happen. See screenshots of the issue:
Image appears in the root of assets - with no title:
Even though it should have appeared in this directory (that's also where it's placed):
Initially I thought I could fix this by adding the following to PopulateFactory.php
before returning the object, as to my knowledge that's what needs to be triggered, it's not working though, so I'm a little lost:
//making sure to update file system after adding/editing files and images
if(isset($data['PopulateFileFrom'])) {
$obj->updateFilesystem();
}
This is my yml:
Image:
demo3a:
Filename: assets/immodb/demos/demo3a.jpg
PopulateFileFrom: immodb/images/demos/demo3/3761870901_953b1c54c9_b.jpg
PopulateMergeMatch:
- Filename