I currently have an action that creates a new link between an object of type A
, named OA
, and an object of type B
, named OB
.
Our workflow has a constraint such that any object of type B
can at most, be linked to 4 objects of type A
. As such, I would like to define a submission criterion in the action such that submission is blocked if OB is already linked to 4 objects of type A
.
I couldn't find a straightforward way to do this using the Action configuration UI. How could I accomplish this?
The easiest way to accomplish this would be to turn your action into a function backed action. This would allow you to take the following steps to accomplish the desired functionality:
type A
that are linked toOB
by writing something like:UserFacingError
if there are more than 4 linked objectsFor reference, here are some relevant pages in Foundry’s documentation: