When we Upload files with the normal file uploader, it puts each file in a unique random folder name. Import via CSV upload with our code adds a “-v[n]” on the end of the filename so we can’t find the file we previously uploaded. What is going on????
@Rosanne McKinstry SilverStripe's filesystem stores files in hashed folders, it also natively finds files stored in those hashed folders. When a developer is creating & retrieving a file, they can usually ignore the hashing, because all the considerations are done for them, as long as you use the File API.
SilverStripe's filesystem also has versioning, so that's where the
-v[n] is coming from.
Sadly, mapping a plain filename uri/url is kind of flimsy, and I suspect you could be experiencing that 🙁 , which must be frustrating. Ideally you would relate your Accouncement to a FileID, so that the Announcement object can reference the file's URL through SilverStripe's file system. (edited)