如何从axapta中的警报规则运行类

时间:2022-11-29 22:39:21

Hi everybody I want to create alert rule in axapta. But some class will run when rules run. I want that class to work with the new rule. How can I do this?

大家好,我想在axapta中创建警报规则。但是一些类会在规则运行时运行。我希望该类能够使用新规则。我怎样才能做到这一点?

1 个解决方案

#1


1  

You can create custom event action and call your logic there.

您可以创建自定义事件操作并在那里调用您的逻辑。

Class representing an action must inherit from the EventAction Class, and it must implement the execute method. For each event rule, the Alerts module creates a list of action class IDs that must be instantiated. The individual execute method that is associated with each respective class ID is called whenever a rule matches an event. The list of actions is customizable. For more information, see How to: Add Custom Actions for Alerts

表示操作的类必须从EventAction类继承,并且必须实现execute方法。对于每个事件规则,警报模块会创建必须实例化的操作类ID列表。每当规则匹配事件时,就会调用与每个相应类ID相关联的单独执行方法。操作列表是可自定义的。有关更多信息,请参见如何:为警报添加自定义操作

#1


1  

You can create custom event action and call your logic there.

您可以创建自定义事件操作并在那里调用您的逻辑。

Class representing an action must inherit from the EventAction Class, and it must implement the execute method. For each event rule, the Alerts module creates a list of action class IDs that must be instantiated. The individual execute method that is associated with each respective class ID is called whenever a rule matches an event. The list of actions is customizable. For more information, see How to: Add Custom Actions for Alerts

表示操作的类必须从EventAction类继承,并且必须实现execute方法。对于每个事件规则,警报模块会创建必须实例化的操作类ID列表。每当规则匹配事件时,就会调用与每个相应类ID相关联的单独执行方法。操作列表是可自定义的。有关更多信息,请参见如何:为警报添加自定义操作