Answer the question
In order to leave comments, you need to log in
How to take model from validator?
Laravel has a very handy validator
. It has one of the functions 'modelId' => 'exists:models,id'
. So here's how I can then use this data
.
Now it turns out that first there is a request to check for the existence of this data, and then again the same request to take this very model.
Is there any way to make this model return from the validator
Yes, I know that there is a search not for a model, but for records in a certain table and a certain column
. Can there be some way to return this tuple from the database table?
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question