Class: Pripara::Brand

Inherits:
Base
  • Object
show all
Defined in:
lib/ruripara/brand.rb

Constant Summary collapse

ATTR_KEYS =
%i(id name kana charm_id).freeze

Instance Attribute Summary

Attributes inherited from Base

#attributes

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Base

all, find_by, #initialize, #match?

Constructor Details

This class inherits a constructor from Pripara::Base

Class Method Details

.config_file_nameObject



16
17
18
# File 'lib/ruripara/brand.rb', line 16

def config_file_name
  "brands.yml"
end

Instance Method Details

#charmObject



11
12
13
# File 'lib/ruripara/brand.rb', line 11

def charm
  @charm ||= Pripara::Charm.find_by(id: charm_id) if charm_id
end