Sha256: 3f10491b5bd9d3bd32ed15fa481e693fed74904961721098e45b7f07273f219f
Contents?: true
Size: 561 Bytes
Versions: 16
Compression:
Stored size: 561 Bytes
Contents
module Ecom module Core class MaintenanceServiceOrder < ApplicationRecord NEW = 'New'.freeze IN_PROGRESS = 'In Progress'.freeze COMPLETED = 'Completed'.freeze STATUSES = [NEW, IN_PROGRESS, COMPLETED].freeze belongs_to :equipment_item belongs_to :maintenance_type belongs_to :prepared_by, class_name: 'Ecom::Core::User' belongs_to :approved_by, class_name: 'Ecom::Core::User' validates :title, :status, :current_reading, presence: true validates :status, inclusion: STATUSES end end end
Version data entries
16 entries across 16 versions & 1 rubygems