module Ecom module Core class WorkComponent < ApplicationRecord belongs_to :performer, class_name: 'Ecom::Core::User' belongs_to :approver, class_name: 'Ecom::Core::User' belongs_to :supervisor, class_name: 'Ecom::Core::User' belongs_to :quality_controller, class_name: 'Ecom::Core::User' belongs_to :work_component_template belongs_to :task validates :name, :assignment_status, :task_status, :percent_completed, presence: true end end end