On Miércoles, 13 de Mayo de 2009 17:33:48 fattymelt escribió: > On May 12, 4:09 am, "Sergio Cambra .:: entreCables S.L. ::." > > <[email protected]> wrote: > > El Friday 08 May 2009 23:58:23 fattymelt escribió:> I see no one ever > > responded to this -> > > > > >http://groups.google.com/group/activescaffold/msg/6745982271cda82a > > > > > > But I have the exact same issue. As the OP says, it must be a common > > > problem, so I think I am missing some obvious solution. Thanks. > > > > Use a field override and call to_label. > > So, I did this, but all I get is the String. I, and the OP, were > hoping to get a link, just like you get with "single layer" > associations. > > Just to be clear, if I have: > > class ApplicationInstance < ActiveRecord::Base > belongs_to :deployment > end > > class Deployment < ActiveRecord::Base > belongs_to :client > end > > class Client < ActiveRecord::Base > end > > When I am using "active_scaffold :application_instance" I can easily > include the :deployment column to display and link to > ApplicationInstance.Deployment, but I want to be able to add a :client > column that displays and links to > ApplicationInstance.Deployment.Client. Your solution did allow me to > display ApplicationInstance.Deployment.Client, but I would like to > have it be a link.
You can return a link in the field override instead of a string. There is no automatic linking feature in ActiveScaffold for associations of associations -- Sergio Cambra .:: entreCables S.L. ::. Nicolás Guillén 6, locales 2 y 3. 50.018 Zaragoza T) 902 021 404 F) 976 52 98 07 E) [email protected] --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
