Sha256: 9c38c2cc2810ef339b9275bae177798e455355ce932f9199a69f29d0b2cec885
Contents?: true
Size: 582 Bytes
Versions: 49
Compression:
Stored size: 582 Bytes
Contents
require 'subj_models/concerns/comprising_external_id' module SubjModels module OrderDeliveryCourierModule def self.included(including_class) including_class.class_eval do include SubjModels::ComprisingExternalId belongs_to :order belongs_to :city validates :street_name,:delivery_time_from, :delivery_time_to, :house_number, presence: true scope :order_id, -> (order_id) { parent_id_scope("order", order_id) } end end def to_s "#{street_name}, #{house_number}" end end end
Version data entries
49 entries across 49 versions & 2 rubygems