Oh...   and I also want to have different Sub grid abilities for each
one...

On the /stores page, I only want to have one column, but on the /
services page, I want to include other relationships/columns....



On Sep 3, 2:57 pm, mikelb <[email protected]> wrote:
> I have three tables:
>
> Store
>   Id
>   Name
> ServiceStore
>   Id
>   ServiceId
>   StoreId
> Service
>   Id
>   Name
>
> How do I...  set it up so that I can have two pages with grids on
> them:  /stores   and  /services, and they can each have nested columns
> for each other?
>
> I have done this:
>
> Store
>   has_many :service_stores
> ServiceStore
>   belongs_to :store
> Service
>   has_many :service_stores
>
> The main issue that I have is:  what do I put in the   def to_label
> for the ServiceStore?   Right now I have:
> service.to_label  ...   but I'm seeing that it needs to be
> conditional.  When I'm on the /stores  page, the column's to_label
> needs to list the services  and when I'm on the /services page, the
> column's to_label needs to reference the stores.
>
> Thanks for your help!
> M

-- 
You received this message because you are subscribed to the Google Groups 
"ActiveScaffold : Ruby on Rails plugin" 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/activescaffold?hl=en.

Reply via email to