Hi all,

I try to call methods from severals slice in my main app, but i still
have an architecture issue.

I have a main controller who call methods from slice:

---- myApp/app/controllers/main.rb ----

class Main < Application

def index
content = Slice1::Main::send_to_front (params,session)
content += Slice2::Main::send_to_front (params,session)

render content
end

end

And my slices (freeze whith thor) :

---- myApp/gems/gems/slice1/app/controllers/main.rb ----

class Slice1::Main < Slice1::Application

def self.send_to_front (params,session)
render "slice1"
end

end

---- myApp/gems/gems/slice2/app/controllers/main.rb ----

class Slice2::Main < Slice2::Application

def self.send_to_front (params,session)
render "slice2"
end

end


I get this error when i go to localhost:4000/main/index

" NoMethodError: undefined method `render' for Slice1::Main:Class "

How can i keep the MVC stack whith this approach ?

I'm not a ruby killer ... and i think i miss some knowledges to solve
this problem.

Thanks a lot for your help




--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"merb" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [email protected]
For more options, visit this group at http://groups.google.com/group/merb?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to