Nested link and links on :parent and :subprograms are follows to self

2010/10/5 Sergio Cambra .:: entreCables S.L. ::. <[email protected]>:
> On Martes, 5 de Octubre de 2010 06:57:34 Andrey Voronkov escribió:
>> I have this model (STI from Program)
>> class Fcp < Program
>>   belongs_to :parent,
>>
>>              :class_name => 'Fcp',
>>              :foreign_key => 'parent_id'
>>
>>   has_many :subprograms,
>>
>>            :class_name => 'Fcp',
>>            :foreign_key => 'parent_id',
>>            :dependent => :destroy
>>
>> ...
>> end
>>
>> and this link in FcpController:
>> active_scaffold do |config|
>>   config.nested.add_link('Подпрограммы', [:subprograms])
>> end
>>
>> It shows parents and subprograms well in list when I add [:parent,
>>
>> :subprograms] to config.list.columns, but by following nested link it
>>
>> shows me the same record (not subprograms set) (containing that link)
>> So it looks like self-referrental nesting.
>>
>> What am I doing wrong.
>
> I can't see why is not working. Do you get same url for both links? Do you get
> some warnings or errors in log file?
>
> --
> Sergio Cambra .:: entreCables S.L. ::.
> Mariana Pineda 23, 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.
>
>

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