Using radiant (mental), I have created my extension and have the
model/view/controller working from within the admin page layout with
no problems. I can create/list/edit/destroy my model instances.
Now, I want to list each instance of my model from within a page on
the website using a radius tag <r:mytag /> and the website layout. I
believe using a tag would be the most appropriate.
As I have tried so far, I have recreated the view from within my tag
using the content << "<table>...</table>" method. It seems that there
should be a better way so that I don't repeat myself by creating two
views, one for the admin page and the second for the radius tag.
Is there a way to reuse the view/controller inside the radius tag?
Maybe something like
module MyTag
include Radiant::Taggable
desc %{ <r:mytag />
Displays the list of mytag available. }
tag "mytag" do |tag|
render(:controller => MyController, :action => MyAction)
end
end
or something to that effect.
I would also like to render the form so that users can input models on
my site as well. I just thought that I would try the list first.
Very new to all of this, so any pointers or directions would be much
appreciated.
Jason
_______________________________________________
Radiant mailing list
Post: [email protected]
Search: http://radiantcms.org/mailing-list/search/
Site: http://lists.radiantcms.org/mailman/listinfo/radiant