Class: SpreeCmCommissioner::Integrations::StadiumXV1::Resources::League

Inherits:
Base
  • Object
show all
Defined in:
app/services/spree_cm_commissioner/integrations/stadium_x_v1/resources/league.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Base

from_collection

Constructor Details

#initialize(attributes = {}) ⇒ League

Returns a new instance of League.



6
7
8
# File 'app/services/spree_cm_commissioner/integrations/stadium_x_v1/resources/league.rb', line 6

def initialize(attributes = {})
  super(attributes)
end

Instance Attribute Details

#_idObject

Returns the value of attribute _id.



4
5
6
# File 'app/services/spree_cm_commissioner/integrations/stadium_x_v1/resources/league.rb', line 4

def _id
  @_id
end

#logoObject

Returns the value of attribute logo.



4
5
6
# File 'app/services/spree_cm_commissioner/integrations/stadium_x_v1/resources/league.rb', line 4

def 
  @logo
end

#nameObject

Returns the value of attribute name.



4
5
6
# File 'app/services/spree_cm_commissioner/integrations/stadium_x_v1/resources/league.rb', line 4

def name
  @name
end

Instance Method Details

#to_hObject



10
11
12
13
14
15
16
# File 'app/services/spree_cm_commissioner/integrations/stadium_x_v1/resources/league.rb', line 10

def to_h
  {
    _id: _id,
    name: name,
    logo: 
  }.compact
end