Description: Sample Groovy script to make any or all document attributes non-editable on the 'Upload' and 'Edit Attributes' screens.
The following sample Groovy script will make the 'Rev' standard attribute and 'PROJECT COST' custom attribute fields non-editable in the 'Upload Document' and 'Edit Attributes' screens. For custom attributes, the user needs to pass the attribute name itself instead of IDocumentAttribute.REV.
Setting values to attributes is not supported for the On-Load Edit Attribute event; it is only supported in the On-Load Upload event.
Supported standard attributes of the document:
IDocumentAttribute.DOC_REF
IDocumentAttribute.REV
IDocumentAttribute.DOC_TITLE
IDocumentAttribute.POI
IDocumentAttribute.STATUS
IDocumentAttribute.DOC_PRIVACY
IDocumentAttribute.REV_NOTES
IDocumentAttribute.ATTACH_FILE
Context: Document
Remark: Accessible in 'On-Load' task mode only.
Script:
|
Next Article: Groovy Script - Get details of already uploaded documents based on the current revision