The vet as a user?

merry Christmas all.

I’m working on a Node-Red flow to let the vet fill out the medical data, and store it in medical logs.
I want to email the vet a reciept of the log. (So he can register in his system later)

Insted of managing vets and email addresses in Node-Red, I figured a possible way could be adding them as users in FarmOS.

Anything to be avare of/best practice with this approach?
Would be nice if the vet could log in to FarmOS and see nothing except his own medical logs
If that’s not possible, I only need the vet users for getting their email via the API.

2 Likes

Perhaps a general address book module would make sense, lots of use for it from vets, contractors, suppliers, buyers etc.

Probably some Drupal module out there already worth looking at.

2 Likes

Perhaps a new Contacts entity type could be added.

But if you are using Node-Red anyway perhaps the Goolge API could be leveraged to access Contacts also.

2 Likes

Addressbook could be useful.

2 Likes

User access control would be a nice feature too, could be useful for the Plans module too, it would be nice to have some private plans and associated logs on the farm too. I once made the mistake of sharing some planed improvements with a health and safety inspector who thought they were should a good idea that they gave me a deadline to implement!

2 Likes

Just want to throw this in too: on a recent dev call we were brainstorming the idea of “sharing” records with certain users (or groups of users), similar to the way in which you can “share” files with other users/groups in NextCloud/Google Drive/etc. This would be a very useful and flexible way to selectively share records. Not sure if there are any existing Drupal modules that support this, but it probably wouldn’t be too hard to sketch up requirements for a farmOS-specific implementation of the idea too.

Would be nice if the vet could log in to FarmOS and see nothing except his own medical logs

farmOS entity types (assets, logs, and plans) do already have granular permissions for “view/edit/delete own asset/log/plan”, but in order to do what you want you would need to create a custom role. The “default” roles that farmOS ships with (Manager/Worker/Viewer) allows access to everything. Roles can only be customized if you’re self-hosting.

3 Likes

Sharing records could be useful.
Share by email is also great.
Maybe a share button on table views and on the log detail view.

Ah. Good to know. But not a deal-breaker for Farmier hosting.

2 Likes

As an interim solution, you could build a UI with Node-Red to select records to retrieve via API and format a CSV or even Excel file to your liking and forward to contacts from an external address book.

2 Likes

Thats true. Also, a screenshot pr mail is enough sometimes.

1 Like