Class: ProductCatalogue::Manual
- Inherits:
-
Object
- Object
- ProductCatalogue::Manual
- Defined in:
- app/models/product_catalogue/manual.rb
Instance Attribute Summary collapse
-
#product ⇒ Object
readonly
Returns the value of attribute product.
Instance Method Summary collapse
-
#initialize(catalogue, submission_attributes) ⇒ Manual
constructor
A new instance of Manual.
Constructor Details
#initialize(catalogue, submission_attributes) ⇒ Manual
Returns a new instance of Manual.
5 6 7 8 |
# File 'app/models/product_catalogue/manual.rb', line 5 def initialize(catalogue, submission_attributes) @product = catalogue.product_with_criteria(submission_attributes[:order_role]) || catalogue.product_with_criteria(nil) end |
Instance Attribute Details
#product ⇒ Object (readonly)
Returns the value of attribute product.
3 4 5 |
# File 'app/models/product_catalogue/manual.rb', line 3 def product @product end |