Class: Workarea::Metadata::HomePage

Inherits:
Workarea::Metadata show all
Defined in:
app/queries/workarea/metadata/home_page.rb

Instance Attribute Summary

Attributes inherited from Workarea::Metadata

#content, #model

Instance Method Summary collapse

Methods inherited from Workarea::Metadata

automation_klass, #initialize, model_name, update, #update

Constructor Details

This class inherits a constructor from Workarea::Metadata

Instance Method Details

#descriptionString

Provides a default value for use as the html content meta tag for the home page using the top selling menus

Examples:

Shop online for a great selection including Men's, Women's,
Shoes, and Accesories

Returns:



27
28
29
30
31
32
33
34
35
# File 'app/queries/workarea/metadata/home_page.rb', line 27

def description
  [
    I18n.t(
      'workarea.metadata.shop_selection',
      name: Workarea.config.site_name
    ),
    top_menus.map(&:name).to_sentence
  ].join(' ')
end

#titleString

Provides a default value for use as the html page title of the home page using the top selling menus.

Examples:

Shop Men's, Women's, Shoes, and Accessories

Returns:



11
12
13
14
15
16
# File 'app/queries/workarea/metadata/home_page.rb', line 11

def title
  [
    I18n.t('workarea.metadata.shop'),
    top_menus.map(&:name).to_sentence
  ].join(' ')
end