Acts_as_list and single table inheritence

Hello Rails experts,

Need your help in following issue with the acts_as_list and single
table inheritence

Code details :
http://pastie.org/1214846

But here I need create those entries with the scope on Relater only and
not on RelaterFeed or RelatedLink
I mean do not want to repeat these Position number 1,2,3 then 1,2,3 for
same clip(i.e Relater). Currently it generating those positioning
individually for RelatedFeed and for RelatedLink of same Relater(i.e
clip)

Here I need something like when I’ll assign Relater to RelatedLink or
RelatedFeed it auto create positioning on the basis of Relater only
like

RelatedLink :
rec 1 -> position =1, relater_id=10, relater_type=“Clip”,
type=“RelatedFeed”
rec 2 -> position =2, relater_id=10, relater_type=“Clip”,
type=“RelatedFeed”
rec 3 -> position =3, relater_id=10, relater_type=“Clip”,
type=“RelatedFeed”

Then for RelatedFeed
rec 1 -> position =4, relater_id=10, relater_type=“Clip”,
type=“RelatedFeed”
rec 2 -> position =5, relater_id=10, relater_type=“Clip”,
type=“RelatedFeed”
rec 3 -> position =6, relater_id=10, relater_type=“Clip”,
type=“RelatedFeed”

position will be like 1,2,3,5,6… etc

Any Idea…?? How is to be done…?

Thank you :slight_smile:

-Ganesh K

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs