portal_scraper 2.2.1 → 2.3.0
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 +4 -4
- data/lib/portal_scraper/accounts/client.rb +2 -1
- data/lib/portal_scraper/version.rb +2 -2
- 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: b5b77cb5759492b2d73d62b20dc152bd3b28647c7be2212538c0f647fd5db5f4
|
|
4
|
+
data.tar.gz: 1e2d37f32f66e12b9853636684e02fa6f1d611773c85de8a97ed74533ff6f41a
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: a05dc807833a9668268335c68ee157c078b8ab52d316878b79b56c859fb14f6634f85332a24faabcc1895fb693643e2b1e1fc2819e4ad10048358f411d77fe72
|
|
7
|
+
data.tar.gz: e6657265707f3d4d3e8891332928ae5bb5b55fd7b60e43f6793ee3288470092663167a64398e263df7d3342f418394e443ce14be66ba84183cd3a0a13d59aaa8
|
|
@@ -11,6 +11,7 @@ module PortalScraper
|
|
|
11
11
|
CODE_TO_COUNTRY_MAPPING = JSON.parse(File.read(File.join(File.dirname(__FILE__), 'code_to_country.json')))
|
|
12
12
|
IS_POSTAL_CODE_DOM = JSON.parse(File.read(File.join(File.dirname(__FILE__), 'is_postal_code_dom.json')))
|
|
13
13
|
MINIMUM_AMOUNT = 10
|
|
14
|
+
PROPOSITION_INDEX = 5
|
|
14
15
|
|
|
15
16
|
def initialize(app_id = nil, secret = nil)
|
|
16
17
|
@app_id = app_id || config.app_id
|
|
@@ -131,7 +132,7 @@ module PortalScraper
|
|
|
131
132
|
end
|
|
132
133
|
|
|
133
134
|
def proposition
|
|
134
|
-
proposition_page = app.get(url_for('/propositionDetail.do'), { idx:
|
|
135
|
+
proposition_page = app.get(url_for('/propositionDetail.do'), { idx: PROPOSITION_INDEX })
|
|
135
136
|
proposition_form = proposition_page.form_with(name: /proposition/i)
|
|
136
137
|
try_form_fields(proposition_form, %w(montant amount), MINIMUM_AMOUNT)
|
|
137
138
|
proposition_form['regimeFiscal'] = 'I'
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: portal_scraper
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.3.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Armand Mégrot
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date: 2020-
|
|
12
|
+
date: 2020-10-26 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: mechanize
|