comee_core 0.1.48 → 0.1.50

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e4dbbe8c8a9b605e180c997b14476dc4bd72f45d461d0c8c3e7d3c7b023aa1ed
4
- data.tar.gz: c0a69b00c5c198db04590dcf825d700750147f6179de44c3e3d0986ff0523f01
3
+ metadata.gz: a51ca3d0999e2d63a6317ab9904d82d443bbf134b8a0d3b11e6d8418df9b91a7
4
+ data.tar.gz: bf8c2ca5fc7a8da0b5e8980ffb39310ba6ebab238abb41b7ff88b6fde54b8d81
5
5
  SHA512:
6
- metadata.gz: 37bece99a80c1ebb5af969095e22f6db6ecc9f3a5cb60a41eb05d400420d5ff50466a1dabdd7672440867e356819ee0124ba0f53c75d5fffa999de858f70f743
7
- data.tar.gz: 63a792ebf8e7a58dc0d83c84cb200e9a98c058ecea0aaae545469d917ee7ae53eb5b9ae4b5e6ec8036e84ef78acd897135f18607fc7836cec233321e9d51bcb3
6
+ metadata.gz: 3d1cd55bdc12cb6cef7073a74606527ad93075da6f76547f566c49008c438020203db56908f48723610c3bbf50ff62705cb4c5f728a983246b9704dbd78bb4f6
7
+ data.tar.gz: 299531b1b48cc94381e8fe3cc41678497ea341f039f9417d3857fea39717fae09dee8dcfb7e51e049733bc6bd242c1487bd798f55e05bd1430d2896538adb044
@@ -3,6 +3,7 @@ module Comee
3
3
  class Inventory < ApplicationRecord
4
4
  belongs_to :product
5
5
 
6
+ validates :hash_code, presence: true
6
7
  validates :quantity, presence: true, numericality: {greater_than: 0}
7
8
  end
8
9
  end
@@ -1,6 +1,10 @@
1
1
  module Comee
2
2
  module Core
3
3
  class ItemStatus < ApplicationRecord
4
+ DELIVERY_NOTE_CREATED = "Delivery note created".freeze
5
+ COMPLETELY_PICKED_AND_PACKED = "Completely Picked & Packed".freeze
6
+ PARTIALLY_PICKED_AND_PACKED = "Partially Picked & Packed".freeze
7
+
4
8
  belongs_to :sales_order_item
5
9
 
6
10
  validates :hash_code, :status, :status_date, presence: true
@@ -6,6 +6,7 @@ module Comee
6
6
  belongs_to :product
7
7
  belongs_to :unit
8
8
  has_many :warehouse_shipment_items
9
+ has_many :item_statuses
9
10
 
10
11
  validates :customer_item_no, :delivery_date, presence: true
11
12
  validates :quantity, :price, presence: true, numericality: {greater_than: 0}
@@ -1,6 +1,7 @@
1
1
  class CreateComeeCoreInventories < ActiveRecord::Migration[7.0]
2
2
  def change
3
3
  create_table :comee_core_inventories do |t|
4
+ t.bigint :hash_code, null: false
4
5
  t.references :product,
5
6
  null: false,
6
7
  index: {name: "product_on_cci_indx"},
@@ -1,5 +1,5 @@
1
1
  module Comee
2
2
  module Core
3
- VERSION = "0.1.48".freeze
3
+ VERSION = "0.1.50".freeze
4
4
  end
5
5
  end
@@ -1,5 +1,6 @@
1
1
  FactoryBot.define do
2
2
  factory :inventory, class: "Comee::Core::Inventory" do
3
+ hash_code { rand(1000000) }
3
4
  quantity { 200 }
4
5
  product
5
6
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: comee_core
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.48
4
+ version: 0.1.50
5
5
  platform: ruby
6
6
  authors:
7
7
  - Henock L.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-12-09 00:00:00.000000000 Z
11
+ date: 2023-12-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: active_model_serializers