remove jbuilder from model
This commit is contained in:
parent
1c6c7e02c4
commit
9bdcafd7c0
@ -15,14 +15,6 @@ class Campaign < ActiveRecord::Base
|
|||||||
self.clientid = 720
|
self.clientid = 720
|
||||||
end
|
end
|
||||||
|
|
||||||
def to_builder
|
|
||||||
Jbuilder.new do |json|
|
|
||||||
json.partial! 'campaigns/campaign', campaign: self
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
def has_at_least_one_videolisting
|
def has_at_least_one_videolisting
|
||||||
errors.add(:base, 'Must add at least one Videolisting') if self.videolistings.blank?
|
errors.add(:base, 'Must add at least one Videolisting') if self.videolistings.blank?
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user