Engines And Controller Modules

I’ve been using engines over the weekend and have been very pleased
with my smaller test apps. But I’m now trying a more complex app and
running into some issues. This app uses the controller modules, I.E.

class Admin::UsersController < ApplicationController

So the views are in app/views/admin/users.

With engines the site functions properly until it needs to go into an
Admin controller. Then it says it can’t find the view. So it seems
to me it no longer looks in the engine for the view, but tries to find
it locally. Anybody know of a fix for this?

Eric

I’ve never seen modules in controllers before and couldn’t find much on
the web about it. I was hoping to try to replicate this… Can you tell
me what file you’d call this? and what directory it would go in?

-Andrew

Eric Jensen wrote:

I’ve been using engines over the weekend and have been very pleased
with my smaller test apps. But I’m now trying a more complex app and
running into some issues. This app uses the controller modules, I.E.

class Admin::UsersController < ApplicationController

So the views are in app/views/admin/users.

With engines the site functions properly until it needs to go into an
Admin controller. Then it says it can’t find the view. So it seems
to me it no longer looks in the engine for the view, but tries to find
it locally. Anybody know of a fix for this?

Eric

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs