Entity relation diagram?

Has anyone yet made a diagram of the major entities and their main relations for stock farmOS?

1 Like

No there isn’t an updated ERD available for farmOS v2 yet, but it would be great to make something simple and add it to the data model docs!

I say “simple” because I feel like there’s a spectrum of detail we could go into with a farmOS ERD. For most new users it would be useful to just see the basic relationship between assets, logs, quantities, and taxonomy terms - or just some examples. But it would probably be overwhelming to include ALL potential relationships (eg: including log equipment relationships, group relationships, etc etc).

A series of focused but simplified ERDs might actually be more useful than one “full” ERD, although maybe that would be useful too.

The other complexity is the modularity. The actual ERD of any single instance depends on which modules are enabled. For example, if the Equipment module is not enabled, Logs will not have an Equipment reference field.

I’ve played around with this module a bit: Entity Relationship Diagrams | Drupal.org - It allows you to draw your own diagrams based on the actual database structure of your instance (including any modules that are currently enabled). So that might be worth experimenting with.

The docs are open for contributions if you are interested in helping with this @rmattb!

1 Like

Heh, yes - simple.
Every one of these I’ve made was only including major entities and their main relations, with the goal of someone grasping the rationale of the information architecture. For me this meant <10 content types, friendly names, no machine names, cardinality info also written in plain English.

And yes, the docs in general should have us contributing examples which can be widely understood.

Once I get a local dev env runnning and can turn on field_ui, then I may have to try a draft of a simple erd, just to get my own mental model built.