Module: Io::AssetAudit::ApiIoSupport
- Included in:
- AssetAudit
- Defined in:
- app/api/io/asset_audit.rb
Overview
This module adds the behaviour we require from the AssetAudit module.
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.included(base) ⇒ Object
7 8 9 10 11 12 |
# File 'app/api/io/asset_audit.rb', line 7 def self.included(base) base.class_eval do # TODO: add any named scopes # TODO: add any associations end end |
Instance Method Details
#asset_uuid ⇒ Object
14 15 16 |
# File 'app/api/io/asset_audit.rb', line 14 def asset_uuid asset.try(:uuid) end |
#asset_uuid=(uuid) ⇒ Object
18 19 20 |
# File 'app/api/io/asset_audit.rb', line 18 def asset_uuid=(uuid) self.asset = Uuid.with_external_id(uuid).include_resource.map(&:resource).first end |