class DynamicAttributeDefinition < ActiveRecord::Base belongs_to :attribute_defineable, :polymorphic => true # definition should contain a json hash like this: # {"body" => {"object_type" => "text"}} # # If you want more info, you can add other descriptions # {"body" => {"object_type" => "text", "name" => "Body", "description" => "What the body will include"}} serialize :definition end