Organization Module

An anybody tell me about the “Organization Module”, let’s say that I owns two farms, but I need to keep all the data separated. I read about a “Organization module”, is that an standard option in FarmOS? or it is something that must be configured on the hosting service?.

1 Like

farmOS v4 adds a new entity type called Organization (organization), alongside the existing Asset (asset), Log (log), etc entity types. It also provides a Farm Organization (farm) bundle (just like there are plant, animal, etc bundles of asset entities, activity, observation, etc bundles of log entities… and so forth.)

Assets can be associated with Farm organizations via a new farm reference field. Logs are not directly associated with farms, but their association can be inferred by the asset(s) they reference.

For more background, here is the original forum discussion: Organization-level data

And here is the pull request that was merged, for specific implementation details: Add an Organization entity type with a Farm bundle by mstenta · Pull Request #849 · farmOS/farmOS · GitHub

let’s say that I owns two farms, but I need to keep all the data separated

The new modules that will be included with farmOS v4 (which does not have a stable release yet) only provide the data model elements (organization entity type + farm bundle + farm reference field on assets), which enable you to start organizing assets into farms. But they do not provide any access control logic, and there is no association between users and farms, so there is no way to limit what individual users have access to.

This layer of access control is potentially very complicated, so we decided not to include it in core for this first phase. However, it is being explored in this community add-on module: https://www.drupal.org/project/farm_multitenant

1 Like