updox 0.3.0 → 0.4.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 -3
- data/Gemfile +1 -1
- data/lib/updox/models/application.rb +3 -1
- data/lib/updox/models/appointment.rb +9 -2
- data/lib/updox/models/auth.rb +5 -0
- data/lib/updox/models/calendar.rb +8 -4
- data/lib/updox/models/location.rb +3 -1
- data/lib/updox/models/patient.rb +11 -0
- data/lib/updox/models/user.rb +1 -0
- data/lib/updox/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: 6ec52e4b2310bf45c257d8c4092d3c65f2d9586e49ef18b9600943af750d8af5
|
4
|
+
data.tar.gz: 26a29009d85aab28861408b7266910c752486e9e93771e6d01601a3a76b426a5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0c539a3fc2bc50adafb03ec452e2c3a738fe476bbcd3bde154f8f6e16f861584770bfaceea9f2461ade369cbc6f617b95204840ba94ef6d29e340bfee7caaebe
|
7
|
+
data.tar.gz: 8a6fd9fd5711d3e6ba8dc8d3d607ffee81ca51f1980572f3364f1761c9c02fd596f89ed61939137dd5ae4e2152201734a3d9d78089a462c4707892af30ed2518
|
data/CHANGELOG.md
CHANGED
@@ -4,9 +4,10 @@ All notable changes to this project will be documented in this file.
|
|
4
4
|
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
|
5
5
|
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
|
6
6
|
|
7
|
-
## [0.
|
7
|
+
## [0.4.0] - 2020-02-11
|
8
8
|
### Changed
|
9
|
-
-
|
9
|
+
- Minor grammar fixes
|
10
|
+
- Added `alias_method` to models for snake to camel case
|
10
11
|
|
11
12
|
## [0.3.0] - 2020-02-06
|
12
13
|
### Added
|
@@ -24,7 +25,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
|
|
24
25
|
### Added
|
25
26
|
- Initial Release with ability to ping Updox api
|
26
27
|
|
27
|
-
[0.
|
28
|
+
[0.4.0]: https://github.com/WeInfuse/updox/compare/v0.3.0...v0.4.0
|
28
29
|
[0.3.0]: https://github.com/WeInfuse/updox/compare/v0.2.0...v0.3.0
|
29
30
|
[0.2.0]: https://github.com/WeInfuse/updox/compare/v0.1.0...v0.2.0
|
30
31
|
[0.1.0]: https://github.com/WeInfuse/updox/compare/v0.1.0
|
data/Gemfile
CHANGED
@@ -3,10 +3,12 @@ module Updox
|
|
3
3
|
class Application < Model
|
4
4
|
OPEN_ENDPOINT = '/ApplicationOpen'.freeze
|
5
5
|
|
6
|
-
property :ipAddress
|
6
|
+
property :ipAddress, from: :ip_address
|
7
7
|
property :timeout
|
8
8
|
property :metadata
|
9
9
|
|
10
|
+
alias_method :ip_address, :ipAddress
|
11
|
+
|
10
12
|
def url(account_id: , user_id: , base_uri: nil)
|
11
13
|
response = self.open(account_id: account_id, user_id: user_id)
|
12
14
|
|
@@ -8,8 +8,8 @@ module Updox
|
|
8
8
|
property :calendarId, required: true, from: :calendar_id
|
9
9
|
property :date, required: true
|
10
10
|
property :duration
|
11
|
-
property :patientId
|
12
|
-
property :typeId
|
11
|
+
property :patientId, from: :patient_id
|
12
|
+
property :typeId, from: :type_id
|
13
13
|
property :summary
|
14
14
|
property :details
|
15
15
|
property :blocked, required: true, transform_with: ->(v) { true == v }, default: false
|
@@ -17,6 +17,13 @@ module Updox
|
|
17
17
|
property :locationId, from: :location_id
|
18
18
|
property :reminderTokens, from: :reminder_tokens
|
19
19
|
|
20
|
+
alias_method :updox_id, :updoxId
|
21
|
+
alias_method :calendar_id, :calendarId
|
22
|
+
alias_method :patient_id, :patientId
|
23
|
+
alias_method :type_id, :typeId
|
24
|
+
alias_method :location_id, :locationId
|
25
|
+
alias_method :reminder_tokens, :reminderTokens
|
26
|
+
|
20
27
|
def to_h
|
21
28
|
result = super.to_h
|
22
29
|
|
data/lib/updox/models/auth.rb
CHANGED
@@ -16,6 +16,11 @@ module Updox
|
|
16
16
|
property :accountId, from: :account_id
|
17
17
|
property :userId, from: :user_id
|
18
18
|
|
19
|
+
alias_method :application_id, :applicationId
|
20
|
+
alias_method :application_password, :applicationPassword
|
21
|
+
alias_method :account_id, :accountId
|
22
|
+
alias_method :user_id, :userId
|
23
|
+
|
19
24
|
def to_h
|
20
25
|
{ auth: super.to_h }
|
21
26
|
end
|
@@ -5,11 +5,15 @@ module Updox
|
|
5
5
|
|
6
6
|
property :id, required: true
|
7
7
|
property :title, required: true
|
8
|
-
property :color, required: true, default: '#
|
9
|
-
property :textColor, required: true, default: '#FFFFFF'
|
10
|
-
property :publicCalendar, default: false, from: :public_calendar
|
8
|
+
property :color, required: true, default: '#2DA2C8'
|
9
|
+
property :textColor, required: true, from: :text_color, default: '#FFFFFF'
|
10
|
+
property :publicCalendar, default: false, from: :public_calendar
|
11
11
|
property :active, default: true
|
12
|
-
property :reminderTurnOff, default: false, from: :reminder_turn_off
|
12
|
+
property :reminderTurnOff, default: false, from: :reminder_turn_off
|
13
|
+
|
14
|
+
alias_method :text_color, :textColor
|
15
|
+
alias_method :public_calendar, :publicCalendar
|
16
|
+
alias_method :reminder_turn_off, :reminderTurnOff
|
13
17
|
|
14
18
|
def create(account_id: )
|
15
19
|
self.class.from_response(UpdoxClient.connection.request(endpoint: SYNC_ENDPOINT, body: self.to_h, auth: {accountId: account_id}, required_auths: Updox::Models::Auth::AUTH_ACCT))
|
@@ -6,9 +6,11 @@ module Updox
|
|
6
6
|
property :id
|
7
7
|
property :code
|
8
8
|
property :name
|
9
|
-
property :showInPortal, default: false, from: :show_in_portal
|
9
|
+
property :showInPortal, default: false, from: :show_in_portal
|
10
10
|
property :active, default: true
|
11
11
|
|
12
|
+
alias_method :show_in_portal, :showInPortal
|
13
|
+
|
12
14
|
def save(account_id: )
|
13
15
|
self.class.sync([self], account_id: account_id)
|
14
16
|
end
|
data/lib/updox/models/patient.rb
CHANGED
@@ -14,6 +14,17 @@ module Updox
|
|
14
14
|
property :mobileNumber, from: :mobile_number
|
15
15
|
property :active, default: true
|
16
16
|
|
17
|
+
alias_method :email, :emailAddress
|
18
|
+
alias_method :email_address, :emailAddress
|
19
|
+
alias_method :internal_id, :internalId
|
20
|
+
alias_method :first_name, :firstName
|
21
|
+
alias_method :middle_name, :middleName
|
22
|
+
alias_method :last_name, :lastName
|
23
|
+
alias_method :home_phone, :homePhone
|
24
|
+
alias_method :work_phone, :workPhone
|
25
|
+
alias_method :mobile_number, :mobileNumber
|
26
|
+
alias_method :mobile_phone, :mobileNumber
|
27
|
+
|
17
28
|
def save(account_id: )
|
18
29
|
self.class.sync([self], account_id: account_id)
|
19
30
|
end
|
data/lib/updox/models/user.rb
CHANGED
@@ -26,6 +26,7 @@ module Updox
|
|
26
26
|
alias_method :user_id, :userId
|
27
27
|
alias_method :first_name, :firstName
|
28
28
|
alias_method :last_name, :lastName
|
29
|
+
alias_method :login_password, :loginPassword
|
29
30
|
|
30
31
|
def create
|
31
32
|
UpdoxClient.connection.request(endpoint: SAVE_ENDPOINT, body: self.to_h, required_auths: Updox::Models::Auth::AUTH_APP)
|
data/lib/updox/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: updox
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mike Crockett
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-02-
|
11
|
+
date: 2020-02-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: httparty
|