Sha256: 4d840279ab99d8dbff7861b68a46b734a7e1dfde6a4cf18b17e00a76c187a7dc

Contents?: true

Size: 305 Bytes

Versions: 8

Compression:

Stored size: 305 Bytes

Contents

module Piggybak
  class Shipment < ActiveRecord::Base
    belongs_to :order
    belongs_to :shipping_method
    belongs_to :line_item

    validates :status, presence: true
    validates :shipping_method_id, presence: true
    
    def status_enum
      ["new", "processing", "shipped"]
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
piggybak-0.7.7 app/models/piggybak/shipment.rb
piggybak-0.7.6 app/models/piggybak/shipment.rb
piggybak-0.7.5 app/models/piggybak/shipment.rb
piggybak-0.7.4 app/models/piggybak/shipment.rb
piggybak-0.7.3 app/models/piggybak/shipment.rb
piggybak-0.7.2 app/models/piggybak/shipment.rb
piggybak-0.7.1 app/models/piggybak/shipment.rb
piggybak-0.7.0 app/models/piggybak/shipment.rb