collection by default renders each item in the list as a card. It
sounds like you may want to redefine the card for User, and then
collection will pick that up.
<def tag="card" for="User">
<body:>
<%= image_tag this.photo.url(:normal) %>
</body:>
</def>
Or you can provide a body to the collection, which it will use instead
of the card:
<collection with="@users">
<%= image_tag this.photo.url(:normal) %>
</collection>
Bryan
hobo_hippy wrote:
> I see now - no problem getting the pictures to list but my desired use
> is a little different. The index page lists all the users (definition
> below) but I want the index page to list the user's uploaded picture
> and name, preferable with both picture and name as links to that
> user's show page. Would I do something like <collection
> with="something"/> to get that effect?
>
> <def tag="index-page" for="User">
> <page merge title="Users">
> <body: class="index-page user" param/>
> <content: param>
> <header param="content-header">
> <h2 param="heading">Users</h2>
> <p param="count" if>There <count prefix="are"/></p>
> </header>
> <section param="content-body">
> <a action="new" to="&model" param="new-link"/>
> <page-nav param="top-page-nav"/>
> <collection param/>
> <page-nav param="bottom-page-nav"/>
> </section>
> </content:>
> </page>
> </def>
>
> >
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Hobo
Users" 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/hobousers?hl=en
-~----------~----~----~----~------~----~------~--~---