A few weeks ago, I’ve started working on an Omeka plugin that gathers data from users, stores it in its database tables (so, not using Items) and then builds some visualizations. All of this was build by another dev that is no longer with us, and now the project needs deal with user-submitted files.
As I’d like to use Omeka’s built-in file handling rather than re-implement it in the plugin, my guess is that I should create a File record (and possibly a dummy Item record to attach it to) through code rather than using the usual graphical interface. However, I’ve tried browsing the docs and some existing code to get started, but can’t find anything that seems to be relevant.
Any idea on how I should proceed, or maybe some code that I should look at ?
TL;DR : How can I create Omeka Items and Files with code, without using the graphical interface ?