Triggering on forms
To configure
Helix Server
to run trigger scripts when users edit forms, use form triggers:
these are triggers of type form-save
, form-in
,
form-out
, form-delete
, and
form-commit
.
Use form triggers to generate customized field values for users, to validate data provided on forms, to notify other users of attempted changes to form data, and to otherwise interact with process control and management tools.
The %specdef%
variable is defined for form triggers: it is
expanded to the spec string of the form in question. This allows derived
APIs to parse forms as part of triggers by loading the spec string as an
argument.
If you write a trigger that fires on trigger forms, and the trigger
fails in such a way that the p4 triggers
command no
longer works, the only recourse is to remove the db.triggers
file in the server root directory.
The following table describes the fields of a form trigger definition:
Field | Meaning |
---|---|
|
The name of the trigger. |
|
|
|
The name of the type of form, ( |
|
The trigger for Helix Server
to run when the type of form specified in the
Specify the command in a way that allows Helix Server
account to locate and run the command. The
When your trigger script is stored in the depot, its path must
be specified in depot syntax, delimited by percent characters.
For example, if your script is stored in the depot as
For |