On Sun, Aug 05, 2012 at 02:21:26AM -0700, laurent wrote:
>
> So what is the best way to create is one class of participant, derived from
> active record with a ruote storage for the workitem and a non immediat
> reply to the engine.
Hello Laurent,
welcome to the ruote mailing list.
If you want the workitems to be stored in the ruote storage, then you can
forgo ActiveRecord::Base and use Ruote::StorageParticipant directly (ie you
don't need to create a model).
So no model and your controller would look like:
---8<---
class WorkitemsController
def index
@workitems = RuoteKit.engine.storage_participant.all
end
# ...
end
--->8---
The view is easy to deduce.
If you need more inspiration, look at
https://github.com/tosch/ruote-on-rails/
It's not as minimal as the solution above since it reopens Ruote::Workitem
(in app/models/workitem.rb) to add a few methods. No ActiveRecord::Base in
sight.
Best regards,
--
John Mettraux - http://lambda.io/jmettraux
--
you received this message because you are subscribed to the "ruote users" group.
to post : send email to [email protected]
to unsubscribe : send email to [email protected]
more options : http://groups.google.com/group/openwferu-users?hl=en