Custom Inflector pluralizations. #33133
Unanswered
cristian-home
asked this question in
General
Replies: 1 comment 1 reply
-
Moving to discussions. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Description:
In my project (in spanish) in Laravel 6 I created a service provider to add custom pluralizations to my application, for them I created a rule set for Inflector in the
Register()
method.This helped me in creating a model with its respective controller, migration and factory, for example:
php artisan make:model Organizacion -a
creates table names correctly as "organizaciones" and also helpme with route model binding.In laravel 7 it seems that inflector uses a new api, initially it alerted me with that the class
Doctrine\Common\Inflector
didn't exist, I installed the version 1.4 of inflector, but Laravel doesn't take my pluralizations anymore and I don't know how to accomplish this in Laravel 7.Please help me.
Beta Was this translation helpful? Give feedback.
All reactions