Plentymarkets interface documentation
EventProcedures
Services
EventProceduresService
The EventProcedureService class offers the possibility to register a procedure class and method that can be called by plentymarkets event procedures.
Namespace
Plenty\Modules\EventProcedures\Services
Methods
public registerProcedure($moduleName, $eventType, $procedureNames, $procedureClass, $procedureGroup = \Plenty\Modules\EventProcedures\Services\Entries\ProcedureEntry::PROCEDURE_GROUP_ORDER):bool
Register a procedure class
Name |
Type |
Description |
|
The name of the module. The name of the module can be choosen freely. |
|
|
The name of the event type. The event types are determined and can be one of the following: <ul> <li> {@see \ProcedureEntry::EVENT_TYPE_ORDER}, </li> <li> {@see \ProcedureEntry::EVENT_TYPE_REORDER} or </li> <li> {@see \ProcedureEntry::EVENT_TYPE_TICKET} </li> </ul> |
|
|
The name for the procedure that will be shown in the event procedure UI. The name is unique and will be used for German and English. |
|
|
The fully qualified name of the procedure class to be called by event procedures. Each procedure class must either contain the execute method defined by plentymarkets or can contain an individual method. The individual method has to be provided along with procedure class. The method is separated from the class by an "@" sign. The part following the "@" will be interpreted as method name. The part in front of the "@" is the name of the procedure class. |
|
|
The name of the procedure group. The procedure groups are determined and can be one of the following: <ul> <li> {@see \ProcedureEntry::PROCEDURE_GROUP_ORDER}, </li> <li> {@see \ProcedureEntry::PROCEDURE_GROUP_ITEM}, </li> <li> {@see \ProcedureEntry::PROCEDURE_GROUP_DOCUMENT}, </li> <li> {@see \ProcedureEntry::PROCEDURE_GROUP_CONTACT}, </li> <li> {@see \ProcedureEntry::PROCEDURE_GROUP_SHIPPING}, </li> <li> {@see \ProcedureEntry::PROCEDURE_GROUP_PAYMENT}, </li> <li> {@see \ProcedureEntry::PROCEDURE_GROUP_RETURN} or </li> <li> {@see \ProcedureEntry::PROCEDURE_GROUP_LISTING} </li> <li> [optional, default={@see \ProcedureEntry::PROCEDURE_GROUP_ORDER}] </li> </ul> |
public registerFilter($moduleName, $eventType, $filterNames, $filterClass):bool
Register a filter class
Name |
Type |
Description |
|
The name of the module. The name of the module can be choosen freely. |
|
|
The name of the event type. The event types are determined and can be one of the following: <ul> <li>order</li> <li>ticket</li> </ul> |
|
|
The name for the filter that will be shown in the event procedure UI. The name is unique and will be used for German and English. |
|
|
The fully qualified name of the filter class to be called by event procedures. Each procedure class must either contain the accept method defined by plentymarkets or can contain an individual method. The individual method has to be provided along with procedure class. The method is separated from the class by an "@" sign. The part following the "@" will be interpreted as method name. The part in front of the "@" is the name of the procedure class. The method must return a boolean. |
public registerTrigger($moduleName, $eventType, $triggerIdentifier, $triggerNames):bool
Register a trigger
Name |
Type |
Description |
|
The name of the module. The name of the module can be choosen freely. |
|
|
The name of the event type. The event types are determined and can be one of the following: <ul> <li> order </li> </ul> |
|
|
The identifier for the trigger that will be used to identify the trigger on fire. The identifier of the trigger can be choosen freely. |
|
|
The name for the trigger that will be shown in the event procedure UI. The name is unique and will be used for German and English. |
public fireTrigger($orderId, $moduleName, $triggerIdentifier):void
Fire a trigger
Name |
Type |
Description |
|
The id of the order for which the trigger is fired. |
|
|
The name of the module. The name of the module given on register the trigger. |
|
|
The identifier for the trigger given on register the trigger. |
Services
Entries
FilterEntry
The filter entry contains all information needed to use module filters in plentymarkets event procedures.
Namespace
Plenty\Modules\EventProcedures\Services\Entries
Methods
public getModuleName():string
Gets the module name.
public setModuleName($moduleName):Plenty\Modules\EventProcedures\Services\Entries\FilterEntry
Return type: FilterEntry
Sets the module name
Name |
Type |
Description |
|
public getEventType():string
Gets the type of event for the current filter entry.
public setEventType($eventType):Plenty\Modules\EventProcedures\Services\Entries\FilterEntry
Return type: FilterEntry
Sets the event type
Name |
Type |
Description |
|
public getFilterNames():array
Gets the filter names
public setFilterNames($filterNames):Plenty\Modules\EventProcedures\Services\Entries\FilterEntry
Return type: FilterEntry
Sets the filter names
Name |
Type |
Description |
|
public getFilterClass():string
Gets the filter class
public setFilterClass($filterClass):Plenty\Modules\EventProcedures\Services\Entries\FilterEntry
ProcedureEntry
The procedure entry contains all information needed to use module procedures in plentymarkets event procedures.
Namespace
Plenty\Modules\EventProcedures\Services\Entries
Methods
public getModuleName():string
Gets the module name
public setModuleName($moduleName):Plenty\Modules\EventProcedures\Services\Entries\ProcedureEntry
Return type: ProcedureEntry
Sets the module name
Name |
Type |
Description |
|
public getEventType():string
Gets the event type
public setEventType($eventType):Plenty\Modules\EventProcedures\Services\Entries\ProcedureEntry
Return type: ProcedureEntry
Sets the event type
Name |
Type |
Description |
|
public getProcedureNames():array
Gets the procedure names
public setProcedureNames($procedureNames):Plenty\Modules\EventProcedures\Services\Entries\ProcedureEntry
Return type: ProcedureEntry
Sets the procedure names
Name |
Type |
Description |
|
public getProcedureGroup():string
Gets the procedure group
public setProcedureGroup($procedureGroup):Plenty\Modules\EventProcedures\Services\Entries\ProcedureEntry
Return type: ProcedureEntry
Sets the procedure group
Name |
Type |
Description |
|
public getProcedureClass():string
Gets the procedure class
public setProcedureClass($procedureClass):Plenty\Modules\EventProcedures\Services\Entries\ProcedureEntry
Return type: ProcedureEntry
Sets the procedure class
Name |
Type |
Description |
|
TriggerEntry
The trigger entry contains all information needed to use module triggers in plentymarkets event procedures.
Namespace
Plenty\Modules\EventProcedures\Services\Entries
Methods
public getModuleName():string
Gets the module name
public setModuleName($moduleName):Plenty\Modules\EventProcedures\Services\Entries\TriggerEntry
Return type: TriggerEntry
Sets the module name
Name |
Type |
Description |
|
public getEventType():string
Gets the event type
public setEventType($eventType):Plenty\Modules\EventProcedures\Services\Entries\TriggerEntry
Return type: TriggerEntry
Sets the event type
Name |
Type |
Description |
|
public getTriggerIdentifier():string
Gets the trigger identifier
public setTriggerIdentifier($triggerIdentifier):Plenty\Modules\EventProcedures\Services\Entries\TriggerEntry
Return type: TriggerEntry
Sets the trigger identifier
Name |
Type |
Description |
|
public getTriggerNames():array
Gets the trigger names
public setTriggerNames($triggerNames):Plenty\Modules\EventProcedures\Services\Entries\TriggerEntry
Return type: TriggerEntry
Sets the trigger names
Name |
Type |
Description |
|
public getTrigger():int
Gets the trigger