Huh, normally it doesn't show the row at all.  Either way, you'll want
to adjust the controller to load only the appropriate items (otherwise
pagination and item count are off).

def index
  if current_user.administrator?
    hobo_index # standard index for administrators
  else
    hobo_index current_user.clients # limit to current_user's clients
assuming user has a has_many association for clients
  end
end

On Aug 12, 7:37 am, munkean <[email protected]> wrote:
> hi,
>
> I'm experienced a cosmetic problem with <table-plus>, when I turn the
> normal index page into table format with:
> -------------------------------------------
> <index-page>
>   <collection: replace>
>     <div>
>       <table-plus fields="this">
>         <controls:/>
>       </table-plus>
>     </div>
>   </collection:>
> </index-page>
> ---------------------------------------
> in file: app/views/clients/index.dryml
>
> see screen shot at 
> :http://picasaweb.google.com/lh/photo/pbS74un5U27ebYYunf0xhw?feat=dire...
>
> some of the rows become blank, this make the table look handicapped,
> it is a bug or something I did wrong?
>
> FYI, I did limiting visibility such that only the owner of can view
> their own data & the total
> collection of data are more than the current display entries.
> --------------------------
>   def view_permitted?(field)
>     acting_user.administrator? || owner_is?(acting_user)
>   end
> -----------------------------
> in app/model/client.rb
>
> --
>   munkean

-- 
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.

Reply via email to