Setting Field Atomic Security with MDL
AnsweredAs part of a configuration change to add a new field, I need to set field-level atomic security to an object lifecycle. The challenge here is that the object lifecycle (Quality Event) has 50 states!
So, as an alternative to a repetitive and error-prone update in the UI, I'd like to see if I can create a script to
- ALTER each atomic security component (for each state)
- MODIFY or ADD the Fieldsecurity subcomponent
and set
- the default field permission and
- role overrides
I'm trying to create a template for each command, but I'm having a really hard time figuring this out, even using VPK package outputs.
Any hint would be most welcome!
-
Official comment
Hi,
We have a documented example that walks through a very similar use case.
https://developer.veevavault.com/mdl/#access-controlWhen authoring these scripts, you can test the syntax of the initial script using this endpoint:
https://developer.veevavault.com/api/22.3/#execute-mdl-scriptThe API call will check the MDL, and if there are any syntax errors the response will specify what is wrong.
But when you have a template and are ready to deploy them in bulk, you should use a VPK to deploy all of the remaining scripts.
Here is a reference to the MDL component types as well.
https://developer.veevavault.com/mdl/components/#component-types
Please sign in to leave a comment.
Comments
1 comment