Module: ChartCandy

Defined in:
lib/chart-candy.rb,
lib/chart-candy/engine.rb,
lib/chart-candy/implants.rb,
lib/chart-candy/base_chart.rb,
lib/chart-candy/authentication.rb

Defined Under Namespace

Modules: Builder, Helpers, Implants Classes: Authentication, BaseChart, Engine

Class Method Summary collapse

Class Method Details

.localize(path, options = {}) ⇒ Object



2
3
4
5
6
7
8
# File 'lib/chart-candy.rb', line 2

def self.localize(path, options={})
  options.reverse_merge! format: :date_long

  options[:format] = "chart_candy_#{options[:format]}".to_sym

  return I18n.localize(path, options)
end

.t(path, options = {}) ⇒ Object



14
15
16
# File 'lib/chart-candy.rb', line 14

def self.t(path, options={})
  self.translate path, options
end

.translate(path, options = {}) ⇒ Object



10
11
12
# File 'lib/chart-candy.rb', line 10

def self.translate(path, options={})
  I18n.translate("chart_candy.#{path}", options)
end