Sha256: 56b13e5615d7350d386d7ab789c66d2733af1160c009d4d9d63dabbd43e6a42a
Contents?: true
Size: 587 Bytes
Versions: 9
Compression:
Stored size: 587 Bytes
Contents
module Logistics module Core class ChargeableService < ApplicationRecord validates :code, :name, presence: true, uniqueness: true validates :order, :chargeable_service_type_id, presence: true belongs_to :chargeable_service_type belongs_to :transport_service_type, optional: true def self.build(options = {}) ChargeableService.new(options) end def self.get_chargeable_service_type(cs_id) chargeable_service = ChargeableService.find(cs_id) chargeable_service.chargeable_service_type.name end end end end
Version data entries
9 entries across 9 versions & 1 rubygems