Hi Cees,
Here is the example to use the setting query_args
when creating a relationship
MB_Relationships_API::register( [
'id' => 'route-to-highlight',
'from' => [
'object_type' => 'post',
'post_type' => 'route',
],
'to' => [
'object_type' => 'post',
'post_type' => 'highlight',
'field' => [
'query_args' => [
'tax_query' => [
[
'taxonomy' => 'soort', //taxonomy slug
'field' => 'slug',
'terms' => 'kunst', //term slug
],
],
]
]
],
] );
Read more on the documentation https://docs.metabox.io/extensions/mb-relationships/#using-code