telephone_appointments 0.1.1 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/lib/telephone_appointments/api.rb +2 -2
- data/lib/telephone_appointments/dropped_summary_document_activity.rb +15 -0
- data/lib/telephone_appointments/version.rb +1 -1
- data/lib/telephone_appointments.rb +1 -0
- data/telephone_appointments.gemspec +2 -2
- metadata +6 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a0833e76d754a1c08862298b51678dd20c1944dc
|
4
|
+
data.tar.gz: de4b7cefceb040bcb9ff66bd70c743d66432ff79
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: af6ed1168619ad462a94231e85c65d1b0bb68fe65531a063c9d8f5c99c25589b7e124b0c639fd108a3668790b2bebc8a94011027f29239f5e71d95af2b9cd184
|
7
|
+
data.tar.gz: 0d30ef66052885230217eb73bb9d8a37b5992c9aa61c9eeadcbd362feb0cd57ecfc66582682b30f20052d3b013b737c72c16380f00409391af04ad9998ab100b
|
data/CHANGELOG.md
CHANGED
@@ -4,13 +4,13 @@ module TelephoneAppointments
|
|
4
4
|
class Api
|
5
5
|
SSL_PORT = 443
|
6
6
|
|
7
|
-
def post(path, form_data)
|
7
|
+
def post(path, form_data = nil)
|
8
8
|
uri = URI.parse("#{api_uri}#{path}")
|
9
9
|
http = Net::HTTP.new(uri.host, uri.port)
|
10
10
|
http.read_timeout = read_timeout
|
11
11
|
http.use_ssl = true if uri.port == SSL_PORT
|
12
12
|
request = Net::HTTP::Post.new(uri.request_uri, headers)
|
13
|
-
request.set_form_data(form_data)
|
13
|
+
request.set_form_data(form_data) if form_data
|
14
14
|
|
15
15
|
TelephoneAppointments::Response.new(http.request(request))
|
16
16
|
end
|
@@ -0,0 +1,15 @@
|
|
1
|
+
module TelephoneAppointments
|
2
|
+
class DroppedSummaryDocumentActivity
|
3
|
+
def initialize(appointment_id)
|
4
|
+
@appointment_id = appointment_id
|
5
|
+
end
|
6
|
+
|
7
|
+
def save
|
8
|
+
response = TelephoneAppointments.api.post(
|
9
|
+
"/api/v1/appointments/#{@appointment_id}/dropped_summary_documents"
|
10
|
+
)
|
11
|
+
|
12
|
+
response.success?
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
@@ -3,6 +3,7 @@ require 'telephone_appointments/api'
|
|
3
3
|
|
4
4
|
require 'telephone_appointments/response'
|
5
5
|
require 'telephone_appointments/summary_document_activity'
|
6
|
+
require 'telephone_appointments/dropped_summary_document_activity'
|
6
7
|
|
7
8
|
require 'active_support/core_ext/module/attribute_accessors'
|
8
9
|
|
@@ -6,8 +6,8 @@ require 'telephone_appointments/version'
|
|
6
6
|
Gem::Specification.new do |spec|
|
7
7
|
spec.name = 'telephone_appointments'
|
8
8
|
spec.version = TelephoneAppointments::VERSION
|
9
|
-
spec.authors = ['David Henry']
|
10
|
-
spec.email = ['david@decoybecoy.com']
|
9
|
+
spec.authors = ['Ben Lovell', 'David Henry']
|
10
|
+
spec.email = ['benjamin.lovell@gmail.com', 'david@decoybecoy.com']
|
11
11
|
|
12
12
|
spec.summary = 'Pension Guidance Telephone Appointment Planner API adapter'
|
13
13
|
spec.homepage = 'https://github.com/guidance-guarantee-programme/telephone_appointments'
|
metadata
CHANGED
@@ -1,14 +1,15 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: telephone_appointments
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
|
+
- Ben Lovell
|
7
8
|
- David Henry
|
8
9
|
autorequire:
|
9
10
|
bindir: exe
|
10
11
|
cert_chain: []
|
11
|
-
date: 2017-
|
12
|
+
date: 2017-02-24 00:00:00.000000000 Z
|
12
13
|
dependencies:
|
13
14
|
- !ruby/object:Gem::Dependency
|
14
15
|
name: activesupport
|
@@ -130,6 +131,7 @@ dependencies:
|
|
130
131
|
version: '0'
|
131
132
|
description:
|
132
133
|
email:
|
134
|
+
- benjamin.lovell@gmail.com
|
133
135
|
- david@decoybecoy.com
|
134
136
|
executables: []
|
135
137
|
extensions: []
|
@@ -148,6 +150,7 @@ files:
|
|
148
150
|
- bin/setup
|
149
151
|
- lib/telephone_appointments.rb
|
150
152
|
- lib/telephone_appointments/api.rb
|
153
|
+
- lib/telephone_appointments/dropped_summary_document_activity.rb
|
151
154
|
- lib/telephone_appointments/response.rb
|
152
155
|
- lib/telephone_appointments/stub_api.rb
|
153
156
|
- lib/telephone_appointments/summary_document_activity.rb
|
@@ -173,7 +176,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
173
176
|
version: '0'
|
174
177
|
requirements: []
|
175
178
|
rubyforge_project:
|
176
|
-
rubygems_version: 2.
|
179
|
+
rubygems_version: 2.6.10
|
177
180
|
signing_key:
|
178
181
|
specification_version: 4
|
179
182
|
summary: Pension Guidance Telephone Appointment Planner API adapter
|