tessitura_rest 0.8.8 → 0.9.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2fa34426ec546055756c280dc4d77d789d63b59e89b5a43be5914f95fede2aae
4
- data.tar.gz: 3592bd2415fdd5887a1281f1641ec31c3bfde43dbcc1ca42cbd04308f29c8c4c
3
+ metadata.gz: 1539b3e5cf0a01c0c3176ad996ba759d5c4d4118b8804316e11f64f194c947f9
4
+ data.tar.gz: 7691109aecb3d23b930be0ba696884b8ceb4987a5b9da6ecabbc684a892128f3
5
5
  SHA512:
6
- metadata.gz: 6c257cdb5f389d3f352ed506cf811ae7d49b1d0fd9d14c58eff8e2bb4cf027ad4400b778545a8f9e38eb70b70f7997d4543039f9ab0d36a1b4eb18c774ea2f44
7
- data.tar.gz: cae55d00e90e6b06657ca5cedbdc7c6b2ccc0ec0d722944118cabc176ec94cc2903aaa0586dd5a4f29b8530f689aec057991e6816a6c9f384c0e63426c512c0a
6
+ metadata.gz: 5f41bd34bfd7d05ef981501ea882970e1b1c0540730f31442186538430d1abca31dacdee2786d4011fd3da501a71c68edc2088573133fc203b8b5219717e3e2c
7
+ data.tar.gz: 36ef56980412433946e98d39f5d6dbcd9e834ad91c3989aa5f4b7a192f86cdc7a25d9027aa4339917c1b06098ec282ab10683ea3a6f9027ac1ababf476d74a61
@@ -0,0 +1,8 @@
1
+ version: 2
2
+ updates:
3
+ - package-ecosystem: bundler
4
+ directory: "/"
5
+ schedule:
6
+ interval: monthly
7
+ time: "10:00"
8
+ open-pull-requests-limit: 10
@@ -69,14 +69,15 @@ module Constituents
69
69
  parameters =
70
70
  {
71
71
  "ConstituentType": {
72
- "Id": current["ConstituentType"]["Id"],
72
+ "Id": current['ConstituentType']['Id'],
73
73
  "Inactive": false,
74
74
  },
75
75
  "Id": constituent_id,
76
+ "UpdatedDateTime": current['UpdatedDateTime'],
76
77
  "FirstName": params[:first_name],
77
- "UpdatedDateTime": current["UpdatedDateTime"],
78
78
  "LastName": params[:last_name],
79
79
  "MiddleName": params[:middle_name],
80
+ "SortName": current['SortName'],
80
81
  "Prefix": {
81
82
  "Id": params[:prefix],
82
83
  "Inactive": false
@@ -86,7 +87,7 @@ module Constituents
86
87
  "Inactive": false
87
88
  },
88
89
  "OriginalSource": {
89
- "Id": current["OriginalSource"]["Id"],
90
+ "Id": current['OriginalSource']['Id'],
90
91
  "Inactive": false
91
92
  },
92
93
  }
@@ -99,22 +100,22 @@ module Constituents
99
100
  end
100
101
 
101
102
  def is_household?(snapshot)
102
- snapshot["ConstituentType"]["Id"] == 9
103
+ snapshot['ConstituentType']['Id'] == 9
103
104
  end
104
105
 
105
106
  def update_household(params, current, options={})
106
- constituents = current["Affiliates"].map{|c| c["RelatedConstituentId"]}
107
+ constituents = current['Affiliates'].map{|c| c['RelatedConstituentId']}
107
108
  constituents.each_with_index do |constituent, i|
108
109
  snapshot = get_constituent_snapshot(constituent)
109
110
  parameters =
110
111
  {
111
112
  "ConstituentType": {
112
- "Id": snapshot["ConstituentType"]["Id"],
113
+ "Id": snapshot['ConstituentType']['Id'],
113
114
  "Inactive": false,
114
115
  },
115
116
  "Id": constituent,
116
117
  "FirstName": i == 0 ? params[:first_name] : params[:first_name_2],
117
- "UpdatedDateTime": snapshot["UpdatedDateTime"],
118
+ "UpdatedDateTime": snapshot['UpdatedDateTime'],
118
119
  "LastName": i == 0 ? params[:last_name] : params[:last_name_2],
119
120
  "MiddleName": i == 0 ? params[:middle_name] : params[:middle_name_2],
120
121
  "Prefix": {
@@ -126,7 +127,7 @@ module Constituents
126
127
  "Inactive": false
127
128
  },
128
129
  "OriginalSource": {
129
- "Id": snapshot["OriginalSource"]["Id"],
130
+ "Id": snapshot['OriginalSource']['Id'],
130
131
  "Inactive": false
131
132
  },
132
133
  }
@@ -6,9 +6,9 @@ module PriceTypes
6
6
  JSON.parse(response.body)
7
7
  end
8
8
 
9
- def get_price_type_details(id, mode_of_sale, options={})
9
+ def get_price_type_details(id, mode_of_sale, source, options={})
10
10
  options.merge!(basic_auth: @auth, headers: @headers)
11
- response = self.class.get(base_api_endpoint("TXN/PriceTypes/Details?performanceIds=#{id}&modeOfSaleId=#{mode_of_sale}"), options)
11
+ response = self.class.get(base_api_endpoint("TXN/PriceTypes/Details?performanceIds=#{id}&modeOfSaleId=#{mode_of_sale}&sourceId=#{source}"), options)
12
12
  JSON.parse(response.body)
13
13
  end
14
14
 
@@ -1,3 +1,3 @@
1
1
  class TessituraRest
2
- VERSION = '0.8.8'.freeze
2
+ VERSION = '0.9.1.2'.freeze
3
3
  end
@@ -5,6 +5,11 @@ module Cart
5
5
  self.class.get(base_api_endpoint("Web/Cart/#{session_key}"), options)
6
6
  end
7
7
 
8
+ def get_checkout_complete(session_key, options={})
9
+ options.merge!(basic_auth: @auth, headers: @headers)
10
+ self.class.get(base_api_endpoint("Web/Cart/#{session_key}&savedCart=true"), options)
11
+ end
12
+
8
13
  def empty_cart(session_key, options={})
9
14
  options.merge!(basic_auth: @auth, headers: @headers)
10
15
  self.class.delete(base_api_endpoint("Web/Cart/#{session_key}"), options)
@@ -177,9 +182,8 @@ module Cart
177
182
  "ParentPackageLineItemId": parent_package_line_item_id,
178
183
  "Unseated": unseated
179
184
  }
180
-
181
185
  options.merge!(basic_auth: @auth, headers: @headers)
182
- options.merge!(:body => parameters)
186
+ options.merge!(:body => parameters.to_json, :headers => {'Content-Type' => 'application/json'})
183
187
  self.class.post(base_api_endpoint("Web/Cart/#{session_key}/Packages/Fixed"), options)
184
188
  end
185
189
 
@@ -306,7 +310,7 @@ module Cart
306
310
  "AuthorizationCode": order_authorization_code,
307
311
  }
308
312
  options.merge!(basic_auth: @auth, headers: @headers)
309
- options.merge!(:body => parameters)
313
+ options.merge!(:body => parameters.to_json, :headers => {'Content-Type' => 'application/json'})
310
314
  self.class.post(base_api_endpoint("Web/Cart/#{session_key}/Checkout"), options)
311
315
  end
312
316
 
@@ -1,6 +1,6 @@
1
1
  module Registration
2
2
 
3
- def register_user(session_key, address, first_name, last_name, email, password, special_offer, phone, options={})
3
+ def register_user(session_key, address, first_name, last_name, email, password, promotion, special_offer, phone, options={})
4
4
  parameters =
5
5
  {
6
6
  'FirstName': first_name,
@@ -25,6 +25,7 @@ module Registration
25
25
  },
26
26
  'ConstituentTypeId': 1,
27
27
  'OriginalSourceId': 3,
28
+ 'SourceId': promotion,
28
29
  'Phones':
29
30
  [
30
31
  {
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tessitura_rest
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.8
4
+ version: 0.9.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brittany Martin, Danielle Greaves, Craig Donavin, Patrick FitzGerald
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-04-23 00:00:00.000000000 Z
11
+ date: 2021-06-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -118,6 +118,7 @@ extra_rdoc_files: []
118
118
  files:
119
119
  - ".codeclimate.yml"
120
120
  - ".env.enc"
121
+ - ".github/dependabot.yml"
121
122
  - ".gitignore"
122
123
  - ".rspec"
123
124
  - ".rubocop.yml"
@@ -185,7 +186,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
185
186
  - !ruby/object:Gem::Version
186
187
  version: '0'
187
188
  requirements: []
188
- rubygems_version: 3.0.9
189
+ rubygems_version: 3.0.3
189
190
  signing_key:
190
191
  specification_version: 4
191
192
  summary: Rest API Endpoint for the Tessitura Rest API (v14+).