Rothamsted-Ecoinformatics / farm_rothamsted

Custom farmOS features for Rothamsted Research.
GNU General Public License v2.0
6 stars 1 forks source link

Conventions: Create a convention for handling a Sampling Campaigns -> Reports -> Documents -> Quantites workflow #646

Open aislinnpearson opened 5 months ago

aislinnpearson commented 5 months ago

This issue following issue #645 and this comment here: https://github.com/Rothamsted-Ecoinformatics/farm_rothamsted/issues/645#issuecomment-2045705984

We realised we need a broader convention for handling sampling events (could also be called observations with a log category 'sampling event') and how this links to reports, documents and quantities. Specifically we realised a Report may have multiple Documents which may also have multiple Quantities

Ideally you would be able to link these things together in FarmOS, but also assign them to fields. For example, you might have sampled multiple fields in one day (for which you may or may not have co-ordinate referenced data) and all these come under one observation (although the co-ordinates are over many fields).

You then get back a farm level report which has multiple documents (e.g. a written report plus co-ordinates files and a species list in excel). Those documents may only reference certain fields and you want to create a link between the report/ document and the fields (for example, an organic certification report for the whole farm, where only certain fields are certified as organic). Similarly, the report may have specific quantities which need to be appended to certain fields (e.g. organic matter content or a plant species list). Ideally you could do a .csv upload to append these quantities to that field which also standardises the naming convention (or tags the quantity, or both) so you can also search for those specific quantities. We'd also need to review how this links with lab test logs in the existing infrastructure.

Relevant to this, @mstenta mentioned that Files are entitles in Drupal - so you can reference the same file in two logs. All that is missign is the user interface component for managing this. As such you could create a document asset for managing these and @mstenta has an early stage version here: https://github.com/mstenta/farm_document Could be turned on in the test instance. In terms of revisions, you could use the same convention described in #645 and this comment here: https://github.com/Rothamsted-Ecoinformatics/farm_rothamsted/issues/645#issuecomment-2045705984

Finally, we said we could test these new concepts in a test instance, once #611 is complete