Sha256: b109343d67b292b66d15d9af7f488fcd9e3ccb5d7d2e074cd1f2d418585ebf2d
Contents?: true
Size: 542 Bytes
Versions: 2
Compression:
Stored size: 542 Bytes
Contents
# frozen_string_literals: true module Jobshop class RoutingProcess < ApplicationRecord self.primary_keys = %i[ organization_id routing_process_id ] after_initialize { self.routing_process_id ||= SecureRandom.uuid if new_record? } belongs_to :organization, inverse_of: :routing_processes belongs_to :product, inverse_of: :routing_process, foreign_key: %i[ organization_id product_id ] has_many :routing_steps, inverse_of: :routing_process, foreign_key: %i[ organization_id routing_process_id ] end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
jobshop-0.0.167 | app/models/jobshop/routing_process.rb |
jobshop-0.0.163 | app/models/jobshop/routing_process.rb |