Class: Shoppr::SearchHistory
- Inherits:
-
Object
- Object
- Shoppr::SearchHistory
- Defined in:
- lib/shoppr/search_history.rb
Instance Attribute Summary collapse
-
#category_selections ⇒ Object
Returns the value of attribute category_selections.
Instance Method Summary collapse
-
#initialize(cat_mash) ⇒ SearchHistory
constructor
A new instance of SearchHistory.
Constructor Details
#initialize(cat_mash) ⇒ SearchHistory
Returns a new instance of SearchHistory.
6 7 8 9 10 11 12 13 14 |
# File 'lib/shoppr/search_history.rb', line 6 def initialize(cat_mash) Shoppr.map_mash_attrs(self, cat_mash) if self.category_selections @category_selections = self.category_selection.map {|category_selections| CategorySelection.new(category_selections) } else @category_selections = [] end end |
Instance Attribute Details
#category_selections ⇒ Object
Returns the value of attribute category_selections.
4 5 6 |
# File 'lib/shoppr/search_history.rb', line 4 def category_selections @category_selections end |