Module: FlexiModel
- Extended by:
- ActiveSupport::Concern
- Includes:
- ArModels, ArPersistence, ArQueryable, Association, AttachmentField, Callbacks, Fields, Filter, Validations
- Defined in:
- lib/flexi_model.rb,
lib/flexi_model/fields.rb,
lib/flexi_model/filter.rb,
lib/flexi_model/ar_models.rb,
lib/flexi_model/callbacks.rb,
lib/flexi_model/association.rb,
lib/flexi_model/validations.rb,
lib/flexi_model/ar_queryable.rb,
lib/flexi_model/ar_persistence.rb,
lib/flexi_model/ar_models/field.rb,
lib/flexi_model/ar_models/value.rb,
lib/flexi_model/ar_models/record.rb,
lib/flexi_model/attachment_field.rb,
lib/flexi_model/stub_persistence.rb,
lib/flexi_model/ar_models/collection.rb,
lib/generators/flexi_model/install/install_generator.rb
Defined Under Namespace
Modules: ArModels, ArPersistence, ArQueryable, Association, AttachmentField, Callbacks, Fields, Filter, Generators, Persistence, Validations
Constant Summary
Constants included
from ArQueryable
ArQueryable::RECORD
ArPersistence::COLLECTION, ArPersistence::FIELD, ArPersistence::RECORD, ArPersistence::VALUE
Constants included
from Fields
Fields::MULTI_PARAMS_FIELDS, Fields::TYPES
Instance Method Summary
collapse
#count, #length
#==, #get_flexi_collection, #get_flexi_fields_map, #load_attributes!, #new_record?, #reload
Methods included from Fields
#_cast, #_default_value, #_get_value, #_load_value_from_record, #_name, #assign_attributes, #to_s
Instance Method Details
#create(options = { }) ⇒ Object
22
23
24
|
# File 'lib/flexi_model/callbacks.rb', line 22
def create
run_callbacks(:create) { super }
end
|
#destroy ⇒ Object
38
39
40
|
# File 'lib/flexi_model/callbacks.rb', line 38
def destroy
run_callbacks(:destroy) { super }
end
|
#initialize ⇒ Object
14
15
16
|
# File 'lib/flexi_model/callbacks.rb', line 14
def initialize(*)
run_callbacks(:initialize) { super }
end
|
29
30
31
32
33
34
35
|
# File 'lib/flexi_model/validations.rb', line 29
def perform_validation(options = { })
if options[:validate].nil? || options[:validate]
valid?
else
true
end
end
|
#save ⇒ Object
18
19
20
|
# File 'lib/flexi_model/callbacks.rb', line 18
def save
run_callbacks(:save) { super }
end
|
#update(options = { }) ⇒ Object
26
27
28
|
# File 'lib/flexi_model/callbacks.rb', line 26
def update(*)
run_callbacks(:update) { super }
end
|
#update_attribute ⇒ Object
34
35
36
|
# File 'lib/flexi_model/callbacks.rb', line 34
def update_attribute(*)
run_callbacks(:update) { super }
end
|
#update_attributes ⇒ Object
30
31
32
|
# File 'lib/flexi_model/callbacks.rb', line 30
def update_attributes(*)
run_callbacks(:update) { super }
end
|