Class: TransForms::FormBase
- Inherits:
-
Object
- Object
- TransForms::FormBase
show all
- Extended by:
- ActiveModel::Naming
- Includes:
- ActiveModel::Conversion, ActiveModel::Validations, ActiveModel::Validations::Callbacks, Callbacks
- Defined in:
- lib/trans_forms/form_base.rb
Instance Method Summary
collapse
Methods included from Callbacks
#after_save_on_error_callback
Instance Method Details
#persisted? ⇒ Boolean
26
|
# File 'lib/trans_forms/form_base.rb', line 26
def persisted?; false end
|
#save ⇒ Object
17
18
19
|
# File 'lib/trans_forms/form_base.rb', line 17
def save
valid? && run_transaction
end
|
#save! ⇒ Object
21
22
23
|
# File 'lib/trans_forms/form_base.rb', line 21
def save!
save || (raise ActiveRecord::RecordInvalid)
end
|
#to_key ⇒ Object
27
|
# File 'lib/trans_forms/form_base.rb', line 27
def to_key; nil end
|