`rails g copy ModelName/ControllerName -> NewModelName/NewControllerName new_field_for_copied_model_controller_combination:string new_relation:references`

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

`rails g copy ModelName/ControllerName -> NewModelName/NewControllerName new_field_for_copied_model_controller_combination:string new_relation:references`

Manuel Korfmann
How about a new generator?

It copies a Controller including views and it’s related model including relations and callbacks to NewModelName and NewControllerName, newly added fields can be specified like for a scaffold generator.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/86391155-4EE6-4128-8BED-2D9D6CDE6637%40korfmann.info.
Reply | Threaded
Open this post in threaded view
|

Re: `rails g copy ModelName/ControllerName -> NewModelName/NewControllerName new_field_for_copied_model_controller_combination:string new_relation:references`

Josh Brody
I like this.

Would dropping columns also be possible?

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/404bbc23-d0b6-4103-9c4c-92501df76289%40googlegroups.com.