badaso icon indicating copy to clipboard operation
badaso copied to clipboard

More explicite error message

Open Dri372 opened this issue 2 years ago • 1 comments

Is your feature request related to a problem? Please describe. Lets create a crud with a field "Not Read" Example : model : Car field : color

  • Browse Yes
  • Read No
  • Edit Yes
  • Add Yes
  • Delete Yes

This example is not really useful but it explains the pb that can arrived in more complex situation.

When you edit this crud, the field color is Null, that's normal

When you update an other field, you get an error " The given data was invalid" . In this simple example the pb is obvious, but, in more complex example it can take time to find the cause of the pb. The logs are no more useful, but you can find the cause in the code in vendor/laravel/framework/src/Illuminate/Validation/Validator.php addFailure that gives the attribute and rule concerned (in this example : color is required)

Describe the solution you'd like

Should be good to improve the error msg with the previous information (attribute & rule)

Describe alternatives you've considered

at least improve the logs only.

Dri372 avatar Apr 03 '22 18:04 Dri372

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Jun 02 '22 20:06 stale[bot]

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Aug 12 '22 10:08 stale[bot]