AutoCommit Sam Aug 1 14:03:01 CEST 2015
This commit is contained in:
@@ -23,6 +23,7 @@ class Neuigkeit < ActiveRecord::Base
|
||||
has_many :attachments, :as=>:parent
|
||||
has_one :title_pic, :class_name=>"Attachment", :as=>:parent, :conditions=>["attachments.flag_titlepic =?", true]
|
||||
|
||||
has_many :questions, :class_name=>"Survey::Question", as: :parent
|
||||
|
||||
validates :rubrik, :presence=>true
|
||||
validates :author, :presence=>true
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
class Survey::Choice < ActiveRecord::Base
|
||||
belongs_to :question, class_name: 'Survey::Question'
|
||||
attr_accessible :picture, :sort, :text, :icon, :picture_cache
|
||||
attr_accessible :picture, :sort, :text, :icon, :picture_cache, :remove_picture
|
||||
has_many :answers, class_name: 'Survey::Answer'
|
||||
include ActionView::Helpers::TagHelper
|
||||
mount_uploader :picture, PictureUploader
|
||||
|
||||
Reference in New Issue
Block a user