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