If you want to use rails text helpers in your model then include the
text helper module in the model like so
include ActionView::Helpers::TextHelper
On Oct 29, 10:34 am, David Nguyen
<rails-mailing-l...-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org>
wrote:> Hi,
>
> I have refactored my code and the previous function in my controller
> help.truncate() doesn''t seems to work anymore in my model.
>
> My model class is generating files and I''d like to use this text
helper.
> How can I fix that?
>
> Thanks
> --
> Posted viahttp://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---