apidae 1.3.2 → 1.3.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/models/apidae/apidae_data_parser.rb +1 -1
- data/app/models/apidae/selection.rb +4 -3
- data/app/models/apidae/territory.rb +1 -0
- data/db/migrate/20210607214647_add_apidae_type_to_apidae_territories.rb +5 -0
- data/lib/apidae/version.rb +1 -1
- data/test/dummy/log/development.log +2 -0
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d1f8d7ad0798847cc0b3882958e5f557f1f01219
|
4
|
+
data.tar.gz: 94d139b245115c273ec4c73b385c380bf816da87
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 47dea0045600b59233e78a4616396aee8341de70e9121a335741fbe66d39ffea03e18503564a83c4cd9fe496ebe7058b7ba13690c902f794f46967146d65b16d
|
7
|
+
data.tar.gz: 2350154e37a3fac1d56eed268eb322309842fcf8b349c2e2b28c63af4605aa3cb15c1b629f31a60d740ffe6ec6b9778e9c2a9ae4f03414ae9c86a3023661c719
|
@@ -69,7 +69,7 @@ module Apidae
|
|
69
69
|
key = cache_key(:agenda, from, to)
|
70
70
|
res = $apidae_cache.read(key)
|
71
71
|
unless res
|
72
|
-
query_args = build_args(AGENDA_ENDPOINT, {selection_ids: [apidae_id], from: from, to: to})
|
72
|
+
query_args = build_args(AGENDA_ENDPOINT, {selection_ids: [apidae_id], from: from, to: to, count: 200})
|
73
73
|
res = query_api(query_args, true)
|
74
74
|
$apidae_cache.write(key, res)
|
75
75
|
end
|
@@ -142,14 +142,15 @@ module Apidae
|
|
142
142
|
|
143
143
|
if all_results
|
144
144
|
loops = 0
|
145
|
+
max_loops = only_ids ? 50 : MAX_LOOPS
|
145
146
|
query_args[:first] = 0
|
146
|
-
query_args[:count]
|
147
|
+
query_args[:count] ||= MAX_COUNT
|
147
148
|
query_args[:locales] ||= apidae_project && !apidae_project.locales.blank? ? apidae_project.locales : [DEFAULT_LOCALE]
|
148
149
|
response = JSON.parse get_response(query_args), symbolize_names: false
|
149
150
|
total = response['numFound']
|
150
151
|
query_result[:results] = (only_ids ? response['objetTouristiqueIds'] : response['objetsTouristiques']) || {}
|
151
152
|
|
152
|
-
while total > results_count(query_result) && loops <
|
153
|
+
while total > results_count(query_result) && loops < max_loops
|
153
154
|
loops += 1
|
154
155
|
query_args[:first] += MAX_COUNT
|
155
156
|
response = JSON.parse get_response(query_args), symbolize_names: false
|
data/lib/apidae/version.rb
CHANGED
@@ -65,3 +65,5 @@ Migrating to AddLocalesDataToApidaeProjects (20190123214635)
|
|
65
65
|
[1m[35m (0.2ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
|
66
66
|
[1m[36mApidae::Obj Load (26.8ms)[0m [1m[34mSELECT apidae_id, COUNT(id) FROM "apidae_objs" WHERE "apidae_objs"."root_obj_id" IS NULL GROUP BY "apidae_objs"."apidae_id" HAVING (COUNT(id) > 1)[0m
|
67
67
|
[1m[36mApidae::Obj Load (2.4ms)[0m [1m[34mSELECT apidae_id, COUNT(id) FROM "apidae_objs" WHERE "apidae_objs"."root_obj_id" IS NULL GROUP BY "apidae_objs"."apidae_id" HAVING (COUNT(id) > 1)[0m
|
68
|
+
[1m[36mApidae::Obj Load (0.8ms)[0m [1m[34mSELECT "apidae_objs".* FROM "apidae_objs" ORDER BY "apidae_objs"."id" ASC LIMIT $1[0m [["LIMIT", 1]]
|
69
|
+
[1m[35m (3.4ms)[0m [1m[34mSELECT COUNT(*) FROM "apidae_objs"[0m
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: apidae
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.3.
|
4
|
+
version: 1.3.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jean-Baptiste Vilain
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-06-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -190,6 +190,7 @@ files:
|
|
190
190
|
- db/migrate/20200522124205_rename_objs_contact_to_contact_data.rb
|
191
191
|
- db/migrate/20200528101957_add_is_active_to_apidae_references.rb
|
192
192
|
- db/migrate/20201112080847_create_apidae_territories.rb
|
193
|
+
- db/migrate/20210607214647_add_apidae_type_to_apidae_territories.rb
|
193
194
|
- lib/apidae.rb
|
194
195
|
- lib/apidae/engine.rb
|
195
196
|
- lib/apidae/version.rb
|