Let’s say the controller name is TemplateUserController whose model class is TemplateUser.
Now, I could do self.name.tableize.singularize.string_manipulation…
but that seems a little excessive… I was wondering if there was a faster way to get the model name from the controller. Thanks! =D
A more direct way to do this:
controller_name.classify.