logistics_core 20.10.3 → 21.11.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 81514660f26da73a58d10271aa5c8c2ac2495c01e9294aab3a80c53d16f3c8d9
4
- data.tar.gz: 4842efbecfa140fa0994f44e316c672ba06cb9f7a7ae68cee3ef6cc5e0b72e24
3
+ metadata.gz: b0b4ba96f9be16a584acd02c42ab63cc65df7853a696f954208c49938445abbf
4
+ data.tar.gz: d18669a7ef8ebf73fc0e119e37ff81dee61d370c3f65280a5927b9b11bcc2612
5
5
  SHA512:
6
- metadata.gz: 07d9c75abd272714f34c2da65a6ad198bd66697f9ac0b88e42480d26d50d35692a8330b3330f2f46b48633e87ea54e2a68e6daf6155aedd904da90269e7f883c
7
- data.tar.gz: c7f0751450ed8e7f248b0d8d69531f7ed6e992647b47454b6f13313c5b64cac1e83e61c21bba04dd7e873cd81575e10c2ed8ad3357dee5dfc6caee18d48b181b
6
+ metadata.gz: c17ee3f0b18c6f578ad3eee7cd1cc6b2f0de756037365d6c66575323ce04e3a05df75383f21a979084fd77bf8463d23bb122faa0016826b03c35efcecf8aca5d
7
+ data.tar.gz: 462b4013b8278ca334bfabf0b0f62fa81750a5b6063303b49e55326902383a7163942b46c3d41505cf68216f8bcf72235bbc153f88177bcb860e936653da8997
@@ -101,7 +101,11 @@ module Logistics
101
101
  :acquisition_mode_id, :payment_term_id, :delivery_term_id, :tin_number,
102
102
  :container_arrangement_id, :customs_transport_tariff_id, :transfer_tin_no,
103
103
  :warehouse_id, :trade_license_number, :esl_transport_tariff_id, :is_transfer,
104
- :investment_license_number, :transfer_name, :transport_modality)
104
+ :investment_license_number, :transfer_name, :transport_modality, :free_days,
105
+ :vessel_etd, :vessel_eta, :invoice_submitted_to_client_on,
106
+ :invoice_submitted_to_finance_on, :demurrage, :storage, :payment_settled_on,
107
+ :departure_on, :arrival_on, :remark, :airway_bill_collected_from_airliner_on,
108
+ :airway_bill_delivered_to_client_on)
105
109
  end
106
110
  end
107
111
  end
@@ -73,7 +73,8 @@ module Logistics
73
73
  end
74
74
 
75
75
  def get_requests_by_security_status(security_status)
76
- offer_requests = OfferRequest.where(security_status: security_status)
76
+ offer_requests = OfferRequest.includes(:transaction_type, :client, :communication_channel, :operation_type, :contract)
77
+ .where(security_status: security_status)
77
78
  return offer_requests
78
79
  end
79
80
 
@@ -1,6 +1,9 @@
1
1
  module Logistics
2
2
  module Core
3
3
  class OperationType < Lookup
4
+ SEA = 'Sea'.freeze
5
+ AIR = 'Air'.freeze
6
+ ROAD = 'Road'.freeze
4
7
  end
5
8
  end
6
- end
9
+ end
@@ -1,6 +1,8 @@
1
1
  module Logistics
2
2
  module Core
3
3
  class TransactionType < Lookup
4
+ IMPORT = 'Import'.freeze
5
+ EXPORT = 'Export'.freeze
4
6
  end
5
7
  end
6
- end
8
+ end
@@ -9,7 +9,10 @@ module Logistics
9
9
  :container_arrangement_id, :container_arrangement_name, :customs_transport_tariff_id,
10
10
  :esl_transport_tariff_id, :warehouse_id, :warehouse_name, :trade_license_number, :tin_number, :t_number,
11
11
  :investment_license_number, :load_level, :is_transfer, :transfer_name, :transfer_tin_no,
12
- :transport_modality, :request_no, :created_at, :client_reference
12
+ :transport_modality, :request_no, :created_at, :client_reference, :free_days, :vessel_etd,
13
+ :vessel_eta, :invoice_submitted_to_client_on, :invoice_submitted_to_finance_on, :demurrage, :storage,
14
+ :payment_settled_on, :departure_on, :arrival_on, :remark, :airway_bill_collected_from_airliner_on,
15
+ :airway_bill_delivered_to_client_on
13
16
  end
14
17
  end
15
- end
18
+ end
@@ -1,11 +1,7 @@
1
1
  module Logistics
2
2
  module Core
3
3
  class SimpleOfferRequestSerializer < ActiveModel::Serializer
4
- attributes :id, :request_no, :name
5
-
6
- def name
7
- "#{object.request_no} #{object&.client&.name}"
8
- end
4
+ attributes :id, :request_no
9
5
  end
10
6
  end
11
7
  end
@@ -1,7 +1,10 @@
1
1
  module Logistics
2
2
  module Core
3
3
  class SimpleOperationSerializer < ActiveModel::Serializer
4
- attributes :id, :operation_number, :created_at, :request_no, :client_reference
4
+ attributes :id, :operation_number, :created_at, :request_no, :client_reference, :free_days, :vessel_etd,
5
+ :vessel_eta, :invoice_submitted_to_client_on, :invoice_submitted_to_finance_on, :demurrage, :storage,
6
+ :payment_settled_on, :departure_on, :arrival_on, :remark, :airway_bill_collected_from_airliner_on,
7
+ :airway_bill_delivered_to_client_on
5
8
  end
6
9
  end
7
- end
10
+ end
@@ -0,0 +1,17 @@
1
+ class AddOptionalFieldsToOperation < ActiveRecord::Migration[5.1]
2
+ def change
3
+ add_column :logistics_core_operations, :free_days, :integer
4
+ add_column :logistics_core_operations, :vessel_etd, :date
5
+ add_column :logistics_core_operations, :vessel_eta, :date
6
+ add_column :logistics_core_operations, :invoice_submitted_to_client_on, :date
7
+ add_column :logistics_core_operations, :invoice_submitted_to_finance_on, :date
8
+ add_column :logistics_core_operations, :demurrage, :decimal
9
+ add_column :logistics_core_operations, :storage, :decimal
10
+ add_column :logistics_core_operations, :payment_settled_on, :date
11
+ add_column :logistics_core_operations, :departure_on, :date
12
+ add_column :logistics_core_operations, :arrival_on, :date
13
+ add_column :logistics_core_operations, :remark, :string
14
+ add_column :logistics_core_operations, :airway_bill_collected_from_airliner_on, :date
15
+ add_column :logistics_core_operations, :airway_bill_delivered_to_client_on, :date
16
+ end
17
+ end
@@ -1,5 +1,5 @@
1
1
  module Logistics
2
2
  module Core
3
- VERSION = '20.10.3'
3
+ VERSION = '21.11.2'.freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: logistics_core
3
3
  version: !ruby/object:Gem::Version
4
- version: 20.10.3
4
+ version: 21.11.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Henock L.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-11-01 00:00:00.000000000 Z
11
+ date: 2021-11-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -572,6 +572,7 @@ files:
572
572
  - db/migrate/20200320085930_add_date_accepted_to_operation_documents.rb
573
573
  - db/migrate/20200903094152_add_per_file_field_to_chargeable_service.rb
574
574
  - db/migrate/20201011085541_add_acceptor_to_operation_document.rb
575
+ - db/migrate/20210311200310_add_optional_fields_to_operation.rb
575
576
  - lib/logistics/core.rb
576
577
  - lib/logistics/core/engine.rb
577
578
  - lib/logistics/core/version.rb
@@ -659,7 +660,6 @@ files:
659
660
  - spec/dummy/config/application.rb
660
661
  - spec/dummy/config/boot.rb
661
662
  - spec/dummy/config/cable.yml
662
- - spec/dummy/config/database.yml
663
663
  - spec/dummy/config/environment.rb
664
664
  - spec/dummy/config/environments/development.rb
665
665
  - spec/dummy/config/environments/production.rb
@@ -680,8 +680,6 @@ files:
680
680
  - spec/dummy/config/secrets.yml
681
681
  - spec/dummy/config/spring.rb
682
682
  - spec/dummy/db/schema.rb
683
- - spec/dummy/log/development.log
684
- - spec/dummy/log/test.log
685
683
  - spec/dummy/public/404.html
686
684
  - spec/dummy/public/422.html
687
685
  - spec/dummy/public/500.html
@@ -982,7 +980,6 @@ test_files:
982
980
  - spec/dummy/config/environment.rb
983
981
  - spec/dummy/config/application.rb
984
982
  - spec/dummy/config/puma.rb
985
- - spec/dummy/config/database.yml
986
983
  - spec/dummy/config/boot.rb
987
984
  - spec/dummy/config/initializers/application_controller_renderer.rb
988
985
  - spec/dummy/config/initializers/backtrace_silencers.rb
@@ -1003,8 +1000,6 @@ test_files:
1003
1000
  - spec/dummy/public/404.html
1004
1001
  - spec/dummy/public/apple-touch-icon-precomposed.png
1005
1002
  - spec/dummy/db/schema.rb
1006
- - spec/dummy/log/test.log
1007
- - spec/dummy/log/development.log
1008
1003
  - spec/route_helper.rb
1009
1004
  - spec/models/logistics/core/container_demurrage_rate_spec.rb
1010
1005
  - spec/models/logistics/core/content_type_spec.rb
@@ -1,19 +0,0 @@
1
- default: &default
2
- adapter: postgresql
3
- encoding: unicode
4
- host: localhost
5
- port: 5555
6
- pool: <%= ENV.fetch("RAILS_MAX_THREADS") { 5 } %>
7
- timeout: 5000
8
-
9
- development:
10
- <<: *default
11
- database: logistics_core_development
12
- username: postgres
13
- password:
14
-
15
- test:
16
- <<: *default
17
- database: logistics_core_test
18
- username: postgres
19
- password: