@@ -129,6 +129,7 @@ public function addOperations(?string $tenantId, string $category, array $operat
129129 $ operation ->costs ,
130130 tenantId: $ tenantId ,
131131 description: $ operation ->description ,
132+ taxonomy: $ operation ->taxonomy
132133 );
133134
134135 if (in_array ($ category , ['backend ' , 'consumer ' ])) {
@@ -201,11 +202,12 @@ public function toArray(): array
201202 return $ result ;
202203 }
203204
204- public function addAction (string $ category , string $ name , string $ class , ?string $ config = null , ?array $ metadata = null , ?string $ date = null , ?string $ tenantId = null ): void
205+ public function addAction (string $ category , string $ name , string $ class , ?string $ config = null , ?array $ metadata = null , ?string $ date = null , ?string $ tenantId = null , ? string $ taxonomy = null ): void
205206 {
206207 $ this ->data ['fusio_action ' ][$ name ] = [
207208 'tenant_id ' => $ tenantId ,
208209 'category_id ' => $ this ->getReference ('fusio_category ' , $ category , $ tenantId ),
210+ 'taxonomy_id ' => $ taxonomy !== null ? $ this ->getReference ('fusio_taxonomy ' , $ taxonomy , $ tenantId ) : null ,
209211 'status ' => Table \Action::STATUS_ACTIVE ,
210212 'name ' => $ name ,
211213 'class ' => ClassName::serialize ($ class ),
@@ -326,11 +328,12 @@ public function addConnection(string $name, string $class, ?string $config = nul
326328 ];
327329 }
328330
329- public function addCronjob (string $ category , string $ name , string $ cron , string $ action , ?array $ metadata = null , ?string $ tenantId = null ): void
331+ public function addCronjob (string $ category , string $ name , string $ cron , string $ action , ?array $ metadata = null , ?string $ tenantId = null , ? string $ taxonomy = null ): void
330332 {
331333 $ this ->data ['fusio_cronjob ' ][$ name ] = [
332334 'tenant_id ' => $ tenantId ,
333335 'category_id ' => $ this ->getReference ('fusio_category ' , $ category , $ tenantId ),
336+ 'taxonomy_id ' => $ taxonomy !== null ? $ this ->getReference ('fusio_taxonomy ' , $ taxonomy , $ tenantId ) : null ,
334337 'status ' => Table \Cronjob::STATUS_ACTIVE ,
335338 'name ' => $ name ,
336339 'cron ' => $ cron ,
@@ -353,11 +356,12 @@ public function addCronjobError(string $cronjob, string $message, ?string $tenan
353356 ];
354357 }
355358
356- public function addEvent (string $ category , string $ name , string $ description = '' , ?array $ metadata = null , ?string $ tenantId = null ): void
359+ public function addEvent (string $ category , string $ name , string $ description = '' , ?array $ metadata = null , ?string $ tenantId = null , ? string $ taxonomy = null ): void
357360 {
358361 $ this ->data ['fusio_event ' ][$ name ] = [
359362 'tenant_id ' => $ tenantId ,
360363 'category_id ' => $ this ->getReference ('fusio_category ' , $ category , $ tenantId ),
364+ 'taxonomy_id ' => $ taxonomy !== null ? $ this ->getReference ('fusio_taxonomy ' , $ taxonomy , $ tenantId ) : null ,
361365 'status ' => Table \Event::STATUS_ACTIVE ,
362366 'name ' => $ name ,
363367 'description ' => $ description ,
@@ -602,11 +606,12 @@ public function addRoleScope(string $role, string $scope, ?string $tenantId = nu
602606 ];
603607 }
604608
605- public function addOperation (string $ category , bool $ public , int $ stability , string $ name , string $ httpMethod , string $ httpPath , int $ httpCode , object $ parameters , ?string $ incoming , ?string $ outgoing , object $ throws , string $ action , ?int $ costs = null , ?array $ metadata = null , ?string $ tenantId = null , ?string $ description = null ): void
609+ public function addOperation (string $ category , bool $ public , int $ stability , string $ name , string $ httpMethod , string $ httpPath , int $ httpCode , object $ parameters , ?string $ incoming , ?string $ outgoing , object $ throws , string $ action , ?int $ costs = null , ?array $ metadata = null , ?string $ tenantId = null , ?string $ description = null , ? string $ taxonomy = null ): void
606610 {
607611 $ this ->data ['fusio_operation ' ][$ name ] = [
608612 'tenant_id ' => $ tenantId ,
609613 'category_id ' => $ this ->getReference ('fusio_category ' , $ category , $ tenantId ),
614+ 'taxonomy_id ' => $ taxonomy !== null ? $ this ->getReference ('fusio_taxonomy ' , $ taxonomy , $ tenantId ) : null ,
610615 'status ' => Table \Operation::STATUS_ACTIVE ,
611616 'active ' => 1 ,
612617 'public ' => $ public ? 1 : 0 ,
@@ -698,11 +703,12 @@ public function addTest(string $category, string $operation, ?string $tenantId =
698703 ];
699704 }
700705
701- public function addTrigger (string $ category , string $ name , string $ event , string $ action , ?array $ metadata = null , ?string $ tenantId = null ): void
706+ public function addTrigger (string $ category , string $ name , string $ event , string $ action , ?array $ metadata = null , ?string $ tenantId = null , ? string $ taxonomy = null ): void
702707 {
703708 $ this ->data ['fusio_trigger ' ][$ name ] = [
704709 'tenant_id ' => $ tenantId ,
705710 'category_id ' => $ this ->getReference ('fusio_category ' , $ category , $ tenantId ),
711+ 'taxonomy_id ' => $ taxonomy !== null ? $ this ->getReference ('fusio_taxonomy ' , $ taxonomy , $ tenantId ) : null ,
706712 'status ' => Table \Trigger::STATUS_ACTIVE ,
707713 'name ' => $ name ,
708714 'event ' => $ event ,
0 commit comments