Sha256: b461e90c5230788a04f486ead951858bd54339238680d89c42f08c109e99c847
Contents?: true
Size: 959 Bytes
Versions: 13
Compression:
Stored size: 959 Bytes
Contents
module Sipity # Throughout the workflow process, a processed entity may have numerous # states. class WorkflowState < ActiveRecord::Base self.table_name = 'sipity_workflow_states' belongs_to :workflow, class_name: 'Sipity::Workflow' has_many :originating_workflow_state_actions, dependent: :destroy, class_name: 'Sipity::WorkflowStateAction', foreign_key: :originating_workflow_state_id has_many :resulting_workflow_actions, dependent: :destroy, class_name: 'Sipity::WorkflowAction', foreign_key: :resulting_workflow_state_id # TODO: What should be done with entities in the given state if the WorkflowState is destroyed? has_many :entities, class_name: 'Sipity::Workflow' has_many :notifiable_contexts, dependent: :destroy, as: :scope_for_notification, class_name: 'Sipity::NotifiableContext' end end
Version data entries
13 entries across 13 versions & 1 rubygems