Unable to automatically link controller and model?

This is the first time I’ve seen this. I’m running Rails 1.0 on lighttpd
(Mac OS/X) and all my other Rails apps are working just fine.

I did:

script/generate controller Menu
script/generate model Menu

added a little code (like scaffold :menu)

and got:

undefined method `find’ for Menu:Dependencies::LoadingModule

Adding

model :menu

solves the problem. Anyone know why my Menu model isn’t being loaded?

TIA

To many menus???

Whats the name of the generated classes???

:model has been deprecated since…0.7 or so…

On Friday, February 24, 2006, at 9:04 PM, Steve R. wrote:

and got:


Posted via http://www.ruby-forum.com/.


Rails mailing list
[email protected]
http://lists.rubyonrails.org/mailman/listinfo/rails

Mikkel B.

www.strongside.dk - Football Portal(DK)
nflfeed.helenius.org - Football News(DK)
ting.minline.dk - Buy Old Stuff!(DK)

There is exactly one menu. I’ve tried it with zero.

Using :model was a hack of expediency so I could move ahead and fix when
I figured it out :slight_smile:

It appears the problem has less to do with the amount of data than with
the fact that the model class is not being loaded unless I explicitly
tell Rails I want it.

Thx

Mikkel B. wrote:

To many menus???

Whats the name of the generated classes???

:model has been deprecated since…0.7 or so…

On Friday, February 24, 2006, at 9:04 PM, Steve R. wrote:

and got:


Posted via http://www.ruby-forum.com/.


Rails mailing list
[email protected]
http://lists.rubyonrails.org/mailman/listinfo/rails

Mikkel B.

www.strongside.dk - Football Portal(DK)
nflfeed.helenius.org - Football News(DK)
ting.minline.dk - Buy Old Stuff!(DK)