Skip to content
Discussion options

You must be logged in to vote

Hmm I don't think we can support your use case. This is a simple example with a single nested data object, but for example $data = ChildData::from($validator->getData()); will already not work since the data received will be the parent data and not the child data. We're currently working on better support for relative rules using the rules method.

Adding this functionality to collections is whole new can of worms I don't think we want to open.

You're always welcome to PR such a thing but it would create a lot of edge cases I think. Other solution is to implement custom rules and use these with attributes or the rules method.

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
1 reply
@derheyne
Comment options

Comment options

You must be logged in to vote
1 reply
@derheyne
Comment options

Answer selected by derheyne
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants