#:enddoc: module RailsConnector class ContentCache < CmsBaseModel self.key_prefix = "cc" property :workspace_id property :transferring_to # returns the workspace that is represented by this content cache. # returns nil if the workspace cannot be found. def workspace @workspace ||= Workspace.find_by_id(workspace_id) end # returns the workspace that this content cache is currently transferring to. # returns nil if no transfer is taking place or if the workspace cannot be found. def transfer_target @transfer_target ||= transferring_to ? Workspace.find_by_id(transferring_to) : nil end end end # module RailsConnector