[4.1] Feature Request : Document Creator (user + group) in Workflows
Document creator is stored in the table public.actstream_action in the column actor_object_id with verb=='documents.document_create' and with the document id in target_object_id.
There does not seem to be a way or helper to access this information from workflows.
In our use case, we would like to automate granting group ACL to a document based on the creator's group at upload from the GUI.
We already have this feature working in our back end. A middle-ware ingesting files adds an EXIF field before moving files to a watch folder. Mayan EDMS reads the EXIF attribute and grants access to a specific group role. We cannot rely on this method for GUI uploads by client users.
Ideally we would have such a Helper in mind:
-
{{ workflow_instance.document.creator }}
: user name -
{{ workflow_instance.document.creator.id }}
: user id
Even better with those endpoints:
-
{{ workflow_instance.document.creator.groups }}
: user group name list -
{{ workflow_instance.document.creator.group_ids }}
: user group id list