class Cb::Models::JobBranding
Attributes
account_id[RW]
company_description[RW]
errors[RW]
id[RW]
media[RW]
name[RW]
sections[RW]
show_widgets[RW]
styles[RW]
type[RW]
widgets[RW]
Public Class Methods
new(args = {})
click to toggle source
# File lib/cb/models/implementations/job_branding.rb, line 16 def initialize(args = {}) @name = args['Name'] || '' @id = args['Id'] || '' @account_id = args['AccountId'] || '' @type = args['Type'] || '' @media = Branding::Media.new args['Media'] @styles = Branding::Style.new args['Styles'] @errors = args['Errors'] || '' @company_description = args['CompanyDescription'] || '' @sections = [] @widgets = [] args['Sections'].each do |type, sections| @sections << Branding::Section.new(type, sections) unless sections.nil? end args['Widgets'].each do |type, url| if type == 'ShowWidgets' @show_widgets = url == 'true' else @widgets << Branding::Widget.new(type, url) unless url.nil? end end end