Class: Order
- Inherits:
-
Object
- Object
- Order
- Includes:
- RubyExt::OpenConstructor
- Defined in:
- app/models/order.rb
Instance Attribute Summary collapse
-
#details ⇒ Object
Returns the value of attribute details.
-
#name ⇒ Object
Returns the value of attribute name.
-
#phone ⇒ Object
Returns the value of attribute phone.
Instance Method Summary collapse
-
#initialize(options = {}) ⇒ Order
constructor
A new instance of Order.
- #valid?(options = {}) ⇒ Boolean
Constructor Details
#initialize(options = {}) ⇒ Order
Returns a new instance of Order.
9 10 11 12 |
# File 'app/models/order.rb', line 9 def initialize = {} super set! end |
Instance Attribute Details
#details ⇒ Object
Returns the value of attribute details.
16 17 18 |
# File 'app/models/order.rb', line 16 def details @details end |
#name ⇒ Object
Returns the value of attribute name.
14 15 16 |
# File 'app/models/order.rb', line 14 def name @name end |
#phone ⇒ Object
Returns the value of attribute phone.
15 16 17 |
# File 'app/models/order.rb', line 15 def phone @phone end |
Instance Method Details
#valid?(options = {}) ⇒ Boolean
5 6 7 |
# File 'app/models/order.rb', line 5 def valid? = {} run_model_validations && errors.empty? end |