Fix custom image class

This commit is contained in:
Christophe Vilayphiou 2012-01-24 15:11:42 +08:00
parent b8243df5b5
commit 83827f82ec
2 changed files with 2 additions and 2 deletions

View File

@ -16,7 +16,7 @@ class Design
embeds_many :themes embeds_many :themes
embeds_many :javascripts embeds_many :javascripts
embeds_many :images embeds_many :images
embeds_many :custom_images, as: :design_image embeds_many :custom_images, :class_name => 'Image', as: :design_image
validates_presence_of :title validates_presence_of :title
validates_presence_of :author validates_presence_of :author

View File

@ -8,7 +8,7 @@ class Page < Item
has_many :page_parts has_many :page_parts
belongs_to :module_app belongs_to :module_app
embeds_many :custom_images, as: :design_image embeds_many :custom_images, :class_name => 'Image', as: :design_image
def create_parts def create_parts
page_design = self.design page_design = self.design