hi all
I have the following code in the ApplicationHelper module
def foobar
#@obj = User.find(1)
@obj = Crumb.find(1)
end
here''s the view which calls foobar() :
<%= foobar %>
<p>Test view - User/Control_Panel</p>
User.find works without errors, Crumb.find throws :
NameError in User#control_panel
Showing /user/control_panel.rhtml where line #1 raised uninitialized
constant ApplicationHelper::Crumb
I have several models, only User.find(1) and Site.find(1) work without
errors. No matter which other model I use I get the above exception when
I try to use them from foobar().
The models all work great in any controller and there''s no fundemental
difference between the models - they''re all sub-classes of
ActiveRecord::base
I''m really baffled by this and would appreciate some help
thanks
dylan