Open astray-heavy-arms opened 4 days ago
This is more a question than anything else.
If I generate a field partial that contains: -
text image relationship
Then say I use that partial in two diffrent blocks that need the relationship in one to reference post_type foo and the second block post type bar.
foo
bar
When using a partial how do I change the post types of the relationship field between my blocks?
You should be able to use modifyField – I think this will work:
modifyField
$field ->addPartial(Partials\Review::class) ->modifyField('advertiser_url', [ 'post_type' => ['bar'], ]);
This is more a question than anything else.
If I generate a field partial that contains: -
text image relationship
Then say I use that partial in two diffrent blocks that need the relationship in one to reference post_type
foo
and the second block post typebar
.When using a partial how do I change the post types of the relationship field between my blocks?