Sha256: 3a4a229b0b0224c8c819cd0947cf6d56558b603534e59506e4c6476081861fb3
Contents?: true
Size: 372 Bytes
Versions: 2
Compression:
Stored size: 372 Bytes
Contents
module Yao module Resources module TenantAssociationable def self.included(base) base.friendly_attributes :project_id base.friendly_attributes :tenant_id end # @return [Yao::Resources::Tenant] def tenant @tenant ||= Yao::Tenant.find(project_id || tenant_id) end alias :project :tenant end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
yao-0.15.0 | lib/yao/resources/tenant_associationable.rb |
yao-0.14.0 | lib/yao/resources/tenant_associationable.rb |