ntq_excelsior_engine 0.4.1 → 0.4.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/models/ntq_excelsior_engine/import.rb +3 -1
- data/lib/ntq_excelsior_engine/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 13a03024396714dbe927960c5444dc3c6e494f58b1cc536e76149011f3fb808e
|
4
|
+
data.tar.gz: 80abc920a5774e739fb8fe305a2beabc89bb10d1769d49de0fbd3e03164010e0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3e271e7251b5bfb9bcb0fbe33478f5913b4853ee4be499cefff0b47ea65462c6c8b4d5f458e1fa9af88df98583a6595fda7323d7ca7383fe65a5fab1df9a82bf
|
7
|
+
data.tar.gz: e3a67f73dc0b58f5c64641844b582373068e5fdd151f15f12041263d0c90075b6e4675db060bc51619ea53c3b552ccb4fe76ba421eb05982f0adbd887892a038
|
@@ -2,6 +2,8 @@ module NtqExcelsiorEngine
|
|
2
2
|
class Import < ::ApplicationRecord
|
3
3
|
|
4
4
|
self.table_name = "excelsior_imports"
|
5
|
+
|
6
|
+
attr_accessor :async
|
5
7
|
|
6
8
|
enum state: { pending: 'pending', buffering: 'buffering', buffered: 'buffered', imported: 'imported', error: 'error', importing: 'importing', checking: 'checking', checked: 'checked' }
|
7
9
|
|
@@ -34,7 +36,7 @@ module NtqExcelsiorEngine
|
|
34
36
|
end
|
35
37
|
|
36
38
|
def process_import!(actions: NtqExcelsiorEngine.actions_on_create.map(&:to_s))
|
37
|
-
if NtqExcelsiorEngine.async
|
39
|
+
if async || (async.nil? && NtqExcelsiorEngine.async)
|
38
40
|
job_id = NtqExcelsiorEngine::ProcessImportJob.perform_async(id, actions.join(','))
|
39
41
|
p "ASYNC #{job_id}"
|
40
42
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ntq_excelsior_engine
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kevin
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-04-
|
11
|
+
date: 2023-04-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|