openapply 1.0.3.7 → 1.0.3.9

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: baeb574c2b8b4f3929b9e375f0a25781cfc85591787f1a07939c41e89d83bf36
4
- data.tar.gz: 3b504d28b79caa20ed63db7d1918537e0720304356b551f1f81d4339e6dd8877
3
+ metadata.gz: f3d0417741f52d557be754a657e3b87a659e6bc81c7ffaa8e574dde30c50f7a3
4
+ data.tar.gz: 233e89a964ac7d94004593679395ad85ff8c5d84ec911bebbb3040969cd711a8
5
5
  SHA512:
6
- metadata.gz: ff039ff3ec1a40da9cf2f50fd3cdfb0af5b8dfafe155d292c5b8ad585b5e2ab2565f3cabf8761da8e98d177a2537626d0c19a0e6101ba5dd5f1169e4dfdb7d17
7
- data.tar.gz: 2803fde506d4b389b1c3316466b4449f4b74fb2121ea9f41e380f10ec1e9903753f036682c0b17fc4f1e7e0bb6870784e1c229a2dae83be04202f75b8471ec5b
6
+ metadata.gz: 03f77e33cc388f099ce3b99b1870eca761affe2b32591f881c7db63a2b09645d8306b34460181312c3a609b6d6ecb687765ab80715827be697b6e4f3ef0fe13f
7
+ data.tar.gz: 296569f8e3fb219ecd1dee1ae02800bbe5d4362c6e2239b0a51f58599116de867175dfea9aa70ee83b7adb93ea71414919a69266562f34ec51eb408aa81adba7
data/CHANGE_LOG.md CHANGED
@@ -1,5 +1,8 @@
1
1
  ### Openapply CHANGE LOG
2
2
 
3
+ * **v1.0.3.9** - compatible with 1.0.x - 2026-04-20
4
+ - retrieve guardian summary data from students' `parent_guardian` key instead of the linked hash
5
+
3
6
  * **v1.0.3.5** - compatible with 1.0.x - 2022-08-23
4
7
  - add a debug env variable to debug queries
5
8
 
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- openapply (1.0.3.6)
4
+ openapply (1.0.3.9)
5
5
  httparty (~> 0.20)
6
6
  json (~> 2.6)
7
7
  oauth2 (~> 2.0)
@@ -11,66 +11,78 @@ GEM
11
11
  specs:
12
12
  addressable (2.8.1)
13
13
  public_suffix (>= 2.0.2, < 6.0)
14
+ base64 (0.3.0)
15
+ bigdecimal (4.1.2)
14
16
  codacy-coverage (2.2.1)
15
17
  simplecov
16
18
  coderay (1.1.3)
17
19
  crack (0.4.5)
18
20
  rexml
21
+ csv (3.3.5)
19
22
  diff-lcs (1.5.0)
20
23
  docile (1.4.0)
21
- faraday (2.5.2)
22
- faraday-net_http (>= 2.0, < 3.1)
23
- ruby2_keywords (>= 0.0.4)
24
- faraday-net_http (3.0.0)
24
+ faraday (2.14.1)
25
+ faraday-net_http (>= 2.0, < 3.5)
26
+ json
27
+ logger
28
+ faraday-net_http (3.4.2)
29
+ net-http (~> 0.5)
25
30
  hashdiff (1.0.1)
26
- hashie (5.0.0)
27
- httparty (0.20.0)
28
- mime-types (~> 3.0)
31
+ hashie (5.1.0)
32
+ logger
33
+ httparty (0.24.2)
34
+ csv
35
+ mini_mime (>= 1.0.0)
29
36
  multi_xml (>= 0.5.2)
30
- json (2.6.2)
31
- jwt (2.4.1)
37
+ json (2.19.4)
38
+ jwt (3.1.2)
39
+ base64
40
+ logger (1.7.0)
32
41
  method_source (1.0.0)
33
- mime-types (3.4.1)
34
- mime-types-data (~> 3.2015)
35
- mime-types-data (3.2022.0105)
36
- multi_xml (0.6.0)
37
- oauth2 (2.0.7)
38
- faraday (>= 0.17.3, < 3.0)
39
- jwt (>= 1.0, < 3.0)
42
+ mini_mime (1.1.5)
43
+ multi_xml (0.8.1)
44
+ bigdecimal (>= 3.1, < 5)
45
+ net-http (0.9.1)
46
+ uri (>= 0.11.1)
47
+ oauth2 (2.0.18)
48
+ faraday (>= 0.17.3, < 4.0)
49
+ jwt (>= 1.0, < 4.0)
50
+ logger (~> 1.2)
40
51
  multi_xml (~> 0.5)
41
- rack (>= 1.2, < 3)
42
- rash_alt (>= 0.4, < 1)
43
- version_gem (~> 1.1)
44
- pry (0.14.1)
52
+ rack (>= 1.2, < 4)
53
+ snaky_hash (~> 2.0, >= 2.0.3)
54
+ version_gem (~> 1.1, >= 1.1.9)
55
+ pry (0.14.2)
45
56
  coderay (~> 1.1)
46
57
  method_source (~> 1.0)
47
- public_suffix (5.0.0)
48
- rack (2.2.4)
58
+ public_suffix (5.0.1)
59
+ rack (3.2.6)
49
60
  rake (13.0.6)
50
- rash_alt (0.4.12)
51
- hashie (>= 3.4)
52
61
  rexml (3.2.5)
53
- rspec (3.11.0)
54
- rspec-core (~> 3.11.0)
55
- rspec-expectations (~> 3.11.0)
56
- rspec-mocks (~> 3.11.0)
57
- rspec-core (3.11.0)
58
- rspec-support (~> 3.11.0)
59
- rspec-expectations (3.11.0)
62
+ rspec (3.12.0)
63
+ rspec-core (~> 3.12.0)
64
+ rspec-expectations (~> 3.12.0)
65
+ rspec-mocks (~> 3.12.0)
66
+ rspec-core (3.12.1)
67
+ rspec-support (~> 3.12.0)
68
+ rspec-expectations (3.12.2)
60
69
  diff-lcs (>= 1.2.0, < 2.0)
61
- rspec-support (~> 3.11.0)
62
- rspec-mocks (3.11.1)
70
+ rspec-support (~> 3.12.0)
71
+ rspec-mocks (3.12.3)
63
72
  diff-lcs (>= 1.2.0, < 2.0)
64
- rspec-support (~> 3.11.0)
65
- rspec-support (3.11.0)
66
- ruby2_keywords (0.0.5)
67
- simplecov (0.21.2)
73
+ rspec-support (~> 3.12.0)
74
+ rspec-support (3.12.0)
75
+ simplecov (0.22.0)
68
76
  docile (~> 1.1)
69
77
  simplecov-html (~> 0.11)
70
78
  simplecov_json_formatter (~> 0.1)
71
79
  simplecov-html (0.12.3)
72
80
  simplecov_json_formatter (0.1.4)
73
- version_gem (1.1.0)
81
+ snaky_hash (2.0.3)
82
+ hashie (>= 0.1.0, < 6)
83
+ version_gem (>= 1.1.8, < 3)
84
+ uri (1.1.1)
85
+ version_gem (1.1.9)
74
86
  webmock (3.18.1)
75
87
  addressable (>= 2.8.0)
76
88
  crack (>= 0.3.2)
@@ -78,6 +90,8 @@ GEM
78
90
 
79
91
  PLATFORMS
80
92
  arm64-darwin-20
93
+ arm64-darwin-25
94
+ x86_64-darwin-21
81
95
 
82
96
  DEPENDENCIES
83
97
  bundler (~> 2.3)
@@ -89,4 +103,4 @@ DEPENDENCIES
89
103
  webmock (~> 3.18)
90
104
 
91
105
  BUNDLED WITH
92
- 2.3.20
106
+ 2.3.26
@@ -85,7 +85,7 @@ module Openapply
85
85
  answer = oa_answer( url )
86
86
  break if answer.nil? or answer[:students].nil? or answer[:students].empty?
87
87
  students += answer[:students]
88
- guardians += answer[:linked][:parents]
88
+ guardians += extract_parents_from_students( answer[:students] )
89
89
  last_student = answer[:students].last
90
90
  since_id = last_student[:id]
91
91
  page_number = answer[:meta][:pages].to_i unless answer[:meta].nil?
@@ -113,5 +113,14 @@ module Openapply
113
113
  return "#{api_path}/students/?#{url_options.join('&')}"
114
114
  end
115
115
 
116
+ def extract_parents_from_students( students )
117
+ parents = []
118
+ students.each do |student|
119
+ next if student[:parent_guardian].nil? or student[:parent_guardian].empty?
120
+ parents = student[:parent_guardian]
121
+ end
122
+ return parents
123
+ end
124
+
116
125
  end
117
126
  end
data/lib/openapply/put.rb CHANGED
@@ -16,6 +16,11 @@ module Openapply
16
16
  return oa_answer( url, {student: {student_id: student_id}})
17
17
  end
18
18
 
19
+ def update_student_email(oa_id, student_email)
20
+ # url = "#{api_path}#{oa_id}"
21
+ url = "#{api_path}/students/#{oa_id}"
22
+ return oa_answer( url, {student: {email: student_email}})
23
+ end
19
24
  # # @note Update one student's status
20
25
  # # @param oa_id - (Integer) - id of student to update
21
26
  # # @param status - (string) - status to update for student
@@ -1,5 +1,5 @@
1
1
  module Openapply
2
2
  module Version
3
- VERSION = "1.0.3.7"
3
+ VERSION = "1.0.3.9"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,15 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: openapply
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.3.7
4
+ version: 1.0.3.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bill Tihen
8
8
  - Elliott Hébert
9
- autorequire:
10
9
  bindir: exe
11
10
  cert_chain: []
12
- date: 2022-09-20 00:00:00.000000000 Z
11
+ date: 1980-01-02 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: httparty
@@ -137,7 +136,6 @@ dependencies:
137
136
  - - "~>"
138
137
  - !ruby/object:Gem::Version
139
138
  version: '0.14'
140
- description:
141
139
  email:
142
140
  - btihen@gmail.com
143
141
  - btihen@las.ch
@@ -172,7 +170,6 @@ homepage: https://github.com/las-it/openapply
172
170
  licenses:
173
171
  - MIT
174
172
  metadata: {}
175
- post_install_message:
176
173
  rdoc_options: []
177
174
  require_paths:
178
175
  - lib
@@ -187,8 +184,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
187
184
  - !ruby/object:Gem::Version
188
185
  version: '0'
189
186
  requirements: []
190
- rubygems_version: 3.3.20
191
- signing_key:
187
+ rubygems_version: 3.6.9
192
188
  specification_version: 4
193
189
  summary: Access OpenApply's APIs with Ruby
194
190
  test_files: []