5 FeatherPanel plugin events on BackupPolicyEvent (5 emitted by the core): the event names, the arguments each listener gets, where they fire and a PHP listener for each.
Part of the plugin events reference. Listeners get the payload values as positional arguments in the order shown, cannot cancel the action, and must catch their own exceptions.
Setup
Import BackupPolicyEvent in your entry class and register listeners in processEvents():
<?phpnamespace App\Addons\myplugin;use App\App;use App\Plugins\AppPlugin;use App\Plugins\PluginEvents;use App\Plugins\Events\Events\BackupPolicyEvent;class MyPlugin implements AppPlugin{ public static function processEvents(PluginEvents $event): void { $event->on(BackupPolicyEvent::onBackupPolicyCreated(), function ($policy, $createdBy): void { App::getInstance(true)->getLogger()->info('[myplugin] featherpanel:admin:backup_policy:created'); }); } public static function pluginInstall(): void { } public static function pluginUninstall(): void { }}
BackupPolicyEvent::onBackupPolicyCreated()
Name: featherpanel:admin:backup_policy:createdemitted at 1 siteCancel or modify: nodefinition