Module: SFKB::Settings

Included in:
Knowledge
Defined in:
lib/sfkb/settings.rb

Overview

Methods for getting Salesforce Knowledge settings. Mix it into something with an index.

Instance Method Summary collapse

Instance Method Details

#active_languagesObject


15
16
17
# File 'lib/sfkb/settings.rb', line 15

def active_languages
  settings.languages.select(&:active).map(&:name)
end

#defaultLanguageObject

Tells the default language


6
7
8
# File 'lib/sfkb/settings.rb', line 6

def defaultLanguage
  settings.defaultLanguage
end

#languagesObject

The list of languages


11
12
13
# File 'lib/sfkb/settings.rb', line 11

def languages
  settings.languages
end

#settingsObject


19
20
21
# File 'lib/sfkb/settings.rb', line 19

def settings
  index.knowledgeManagement.settings
end