Class: CamaleonCms::Widget::Main

Inherits:
TermTaxonomy
  • Object
show all
Defined in:
app/models/camaleon_cms/widget/main.rb

Overview

Camaleon CMS is a content management system

Copyright (C) 2015 by Owen Peredo Diaz
Email: [email protected]
This program is free software: you can redistribute it and/or modify   it under the terms of the GNU Affero General Public License as  published by the Free Software Foundation, either version 3 of the  License, or (at your option) any later version.
This program is distributed in the hope that it will be useful,  but WITHOUT ANY WARRANTY; without even the implied warranty of  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the  GNU Affero General Public License (GPLv3) for more details.

Instance Method Summary collapse

Methods inherited from TermTaxonomy

#children, #in_nav_menu_items, #skip_slug_validation?

Methods included from CustomFieldsRead

#add_custom_field_group, #add_custom_field_to_default_group, #get_field_groups, #get_field_object, #get_field_value, #get_field_values, #get_field_values_hash, #get_fields_grouped, #get_fields_object, #get_user_field_groups, #save_field_value, #set_field_value, #set_field_values, #update_field_value

Methods included from Metas

#delete_meta, #delete_option, #fix_save_metas_options_no_changed, #get_meta, #get_option, #options, #save_metas_options, #save_metas_options_skip, #set_meta, #set_metas, #set_multiple_options, #set_option

Instance Method Details

#excerptObject



32
33
34
# File 'app/models/camaleon_cms/widget/main.rb', line 32

def excerpt
  self.get_option("excerpt")
end

#excerpt=(value) ⇒ Object



29
30
31
# File 'app/models/camaleon_cms/widget/main.rb', line 29

def excerpt=(value)
  @excerpt = value
end

#is_simple?Boolean

Returns:

  • (Boolean)


25
26
27
# File 'app/models/camaleon_cms/widget/main.rb', line 25

def is_simple?
  self.status == "simple"
end

#rendererObject



39
40
41
# File 'app/models/camaleon_cms/widget/main.rb', line 39

def renderer
  self.get_option("renderer")
end

#renderer=(value) ⇒ Object



36
37
38
# File 'app/models/camaleon_cms/widget/main.rb', line 36

def renderer=(value)
  @renderer = value
end

#short_codeObject



43
44
45
# File 'app/models/camaleon_cms/widget/main.rb', line 43

def short_code
  "[widget #{self.slug}]"
end