Skip to content

Latest commit

 

History

History
91 lines (64 loc) · 1.81 KB

hooks.md

File metadata and controls

91 lines (64 loc) · 1.81 KB

Hooks

There are various hooks, which allows for changing the output.

Actions

Action for changing main Plugin object

'owc/openpub-base/plugin'

See OWC\OpenPub\Base\Config->set method for a way to change this plugins config.

Via the plugin object the following config settings can be adjusted

  • metaboxes
  • p2p_connections
  • posttypes
  • settings
  • settings_pages
  • taxonomies

Filters

Filters the Posts to Posts connection defaults

owc/openpub-base/p2p-connection-defaults

Filters the per Posts to Posts connection, connection type args

owc/openpub-base/before-register-p2p-connection/{$posttypes_from}/{$posttypes_to]}

Filters the data retrieved for the corresponding Rest API field

owc/openpub-base/rest-api/openpubitem/field/get-links
owc/openpub-base/rest-api/openpubitem/field/get-forms
owc/openpub-base/rest-api/openpubitem/field/get-downloads
owc/openpub-base/rest-api/openpubitem/field/get-title-alternative
owc/openpub-base/rest-api/openpubitem/field/get-appointment
owc/openpub-base/rest-api/openpubitem/field/get-featured_image
owc/openpub-base/rest-api/openpubitem/field/get-taxonomies
owc/openpub-base/core/posttype/posttypes/openpub_item/get-taxonomies/taxonomy-ids
owc/openpub-base/rest-api/openpubitem/field/get-connections
owc/openpub-base/rest-api/openpubsubcategory/field/has-report
owc/openpub-base/rest-api/openpubsubcategory/field/has-appointment

Filters the metaboxes to be registered just before registration

owc/openpub-base/before-register-metaboxes

Filters the settings to be registered just before registration

owc/openpub-base/before-register-settings