Class: GlobalWineData
- Inherits:
-
Object
- Object
- GlobalWineData
- Includes:
- ActiveModel::ForbiddenAttributesProtection, Mongoid::Document, Mongoid::Timestamps
- Defined in:
- app/models/global_wine_data.rb
Instance Method Summary collapse
Instance Method Details
#get_values_for(attr) ⇒ Object
22 23 24 |
# File 'app/models/global_wine_data.rb', line 22 def get_values_for(attr) self.read_attribute(attr).join(',') end |
#set_values_for(attr, values) ⇒ Object
26 27 28 |
# File 'app/models/global_wine_data.rb', line 26 def set_values_for(attr, values) self.write_attribute(attr, values.split(',')) end |