masonite
masonite copied to clipboard
Add CRUD Scaffolding for model, view, controller
Is your feature request related to a problem?
There’s quite a bit of boilerplate code that repeats for each CRUD operation needed for a new model.
What do we currently have to do now?
Adding a new model and it’s CRUD operations means implementing the model, it’s attributes, controller actions, views (forms, list, detail) and routes.
Describe the solution you'd like
A way to automate the creation of CRUD blueprint code (model, views, controller methods), that can then be further improved on by the developer. Very similar to Scaffolding in Rails.
Describe alternatives you've considered
python craft scaffold Post title:string content:text
would create the model with the necessary attributes (title, content), 7 controller methods and their implementation, views, and adjust routes accordingly.
the developer can then modify the blueprint code to further change it to their need.
Would this be a breaking change ?
- [ ] Yes
Anything else ?
No response
I think it would also be good to decide whether or not to generate a blueprint code when creating a model. Personally, I think it would be too much if blueprint code is generated every time a model is created.
I’ll work on this!
👍