CommonTrigger
trait CommonTrigger (View source)
Parent class of all other business classes (invoices, contracts, proposals, orders, ...)
Properties
| DoliDB | $db | ||
| $error | |||
| string[] | $errors | ||
| string | $TRIGGER_PREFIX |
Methods
int
call_trigger(string $triggerName, User $user)
Call trigger based on this instance.
Details
int
call_trigger(string $triggerName, User $user)
Call trigger based on this instance.
Some context information may also be provided into array property this->context. NB: Error from trigger are stacked in interface->errors NB2: If return code of triggers are < 0, action calling trigger should cancel all transaction.