ruby on rails - Rails_admin show child models fields in parents show page -
i have item model , have itemimage child model embedded inside of parent.
when open single items page in rails_admin, shows of children this:
itemimage #55b766556c656e12d0ac0000, itemimage #55b766556c656e12d0ad0000, , itemimage #55b766566c656e12d0ae0000
how make rails_admin show of children fields inside parents page? possible show them table?
i'm using mongoid.
i have made simple solution. have added def name method model:
def name "<a href=\"#{self.image_url}\"><img src=\"#{self.image_url(:thumb)}\" /></a>" end it shows me images of embedded models inside parents page. know not solution have found.
Comments
Post a Comment