DolibarrTriggers
abstract class DolibarrTriggers (View source)
Class that all triggers must inherit
Constants
| deprecated VERSION_DEVELOPMENT |
|
| deprecated VERSION_EXPERIMENTAL |
|
| deprecated VERSION_DOLIBARR |
|
| VERSIONS |
|
Properties
| protected DoliDB | $db | Database handler |
|
| mixed|string | $name | Name of the trigger |
|
| string | $description | Description of the trigger |
|
| ""|"development"|"dolibarr"|"experimental" | $version | Version of the trigger |
|
| string | $picto | Image of the trigger |
|
| string | $family | Category of the trigger |
|
| $error | Error reported by the trigger |
||
| string[] | $errors | Errors reported by the trigger |
|
| string[] | $warnings | Warnings reported by the trigger |
Methods
string
getName()
Returns the name of the trigger file
string
getDesc()
Returns the description of trigger file
string
getVersion()
Returns the version of the trigger file
void
runTrigger(string $action, $object, User $user, Translate $langs, Conf $conf)
Function called when a Dolibarr business event is done.
Details
__construct(DoliDB $db)
Constructor
string
getName()
Returns the name of the trigger file
string
getDesc()
Returns the description of trigger file
string
getVersion()
Returns the version of the trigger file
void
setErrorsFromObject(CommonObject|BlockedLog $object)
setErrorsFromObject