tessitura_rest 0.6.6 → 0.7.1

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: 6539d50947b155b8bc8ba6083d8f49b1033ff35b04db9d8aebe557b5d48319ac
4
- data.tar.gz: 6ae7e958f28bd77ff49c2401c2e028780ac1c1b1ed2f6c84a486d18de50fa097
3
+ metadata.gz: e3d65ff8d71ba192a1f6e15129022a33d3486d7781b11f37885493b133b468c9
4
+ data.tar.gz: 53ddf0b70e80f62767a97e4b9bc1326a0ccd6dc176c248e87fe086592706f6e1
5
5
  SHA512:
6
- metadata.gz: ae8858beb50593e268412a46fad5e5afead0f0e4cce7077099e04526db1afffe1d54bc457606aa9b4bf3d90d90907c6cd8d17906222a84310f931a46461c5950
7
- data.tar.gz: ae232f5728fd2492eeeb12f99a01ad80178471bf5dca04bd3813c9445993bae964d92bd9cdd78ee0c63277f68f4ffe5c9f023aa6d010fdf2d95d4e0dfb890f62
6
+ metadata.gz: 19b790415df66149917c7b01dc78497ff3f1738c4cb4dd9aaed094fd192ae629e11b2d290967407c5458d5c0376c0dcf35249df0ecc0ceb2da25c144bcefe15c
7
+ data.tar.gz: ceb55b8ab38524b9b5c68b4128403f55fb5f578a6d4eea029ca48940432f906aec0c0fe54eb9c1deb371c3df8c069b32dfd887e81804b34955e521b6d32205d2
@@ -14,4 +14,17 @@ module Email
14
14
  post = self.class.post(base_api_endpoint("Emails/LoginCredentials/#{login_id.first['Id']}/Send"), options)
15
15
  post.success?
16
16
  end
17
+
18
+ def send_order_confirmation(template_id, email, profile_id, order_id, params = '', options={})
19
+ parameters =
20
+ {
21
+ 'TemplateId': template_id,
22
+ 'EmailAddress': email,
23
+ 'EmailProfileId': profile_id
24
+ }
25
+ options.merge!(basic_auth: @auth, headers: @headers)
26
+ options.merge!(:body => parameters.to_json, :headers => {'Content-Type' => 'application/json'})
27
+ post = self.class.post(base_api_endpoint("Emails/OrderConfirmation/#{order_id}/Send"), options)
28
+ post.success?
29
+ end
17
30
  end
@@ -35,4 +35,10 @@ module Package
35
35
  response = self.class.get(base_api_endpoint("TXN/Packages/#{id}/PerformanceGroups?modeOfSaleId=#{mode_of_sale}"), options)
36
36
  JSON.parse(response.body)
37
37
  end
38
+
39
+ def get_package_seats(id, mode_of_sale, constituent_id, section_id, options={})
40
+ options.merge!(basic_auth: @auth, headers: @headers)
41
+ response = self.class.get(base_api_endpoint("TXN/Packages/#{id}/Seats?modeOfSaleId=#{mode_of_sale}&constituentId=#{constituent_id}&sectionIds=#{section_id}"), options)
42
+ JSON.parse(response.body)
43
+ end
38
44
  end
@@ -1,9 +1,10 @@
1
1
  module PerformanceExtension
2
2
 
3
- def get_performances_by_production(ids, options={})
3
+ def get_performances_by_production(ids, mode_of_sale=nil, options={})
4
4
  parameters =
5
5
  {
6
- 'ProductionSeasonIds': ids
6
+ 'ProductionSeasonIds': ids,
7
+ 'ModeOfSaleId': mode_of_sale
7
8
  }
8
9
  options.merge!(basic_auth: @auth, headers: @headers)
9
10
  options.merge!(:body => parameters)
@@ -28,9 +29,9 @@ module PerformanceExtension
28
29
  JSON.parse(response.body)
29
30
  end
30
31
 
31
- def get_performance_seats(id, mode_of_sale, constituent_id, options={})
32
+ def get_performance_seats(id, mode_of_sale, constituent_id, section_id, options={})
32
33
  options.merge!(basic_auth: @auth, headers: @headers)
33
- response = self.class.get(base_api_endpoint("TXN/Performances/#{id}/Seats?modeOfSaleId=#{mode_of_sale}&constituentId=#{constituent_id}"), options)
34
+ response = self.class.get(base_api_endpoint("TXN/Performances/#{id}/Seats?modeOfSaleId=#{mode_of_sale}&constituentId=#{constituent_id}&sectionIds=#{section_id}"), options)
34
35
  JSON.parse(response.body)
35
36
  end
36
37
 
@@ -1,3 +1,3 @@
1
1
  class TessituraRest
2
- VERSION = '0.6.6'
2
+ VERSION = '0.7.1'
3
3
  end
@@ -278,4 +278,16 @@ module Cart
278
278
  options.merge!(:body => parameters)
279
279
  self.class.post(base_api_endpoint("Web/Cart/#{session_key}/Validate"), options)
280
280
  end
281
+
282
+ def update_cart_properties_custom_data(session_key, index, value, options={})
283
+ parameters =
284
+ {
285
+ "Index": index,
286
+ "Value": value
287
+ }
288
+ options.merge!(basic_auth: @auth, headers: @headers)
289
+ options.merge!(:body => parameters)
290
+ put = self.class.put(base_api_endpoint("Web/Cart/#{session_key}/CustomData/#{index}"), options)
291
+ put.success?
292
+ end
281
293
  end
@@ -24,6 +24,12 @@ module Session
24
24
  JSON.parse(response.body)
25
25
  end
26
26
 
27
+ def get_variables(key, options={})
28
+ options.merge!(basic_auth: @auth, headers: @headers)
29
+ response = self.class.get(base_api_endpoint("Web/Session/#{key}/Variables"), options)
30
+ JSON.parse(response.body)
31
+ end
32
+
27
33
  def set_expiration(key, timeoffset, expiration, options={})
28
34
  parameters =
29
35
  {
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.6.6
4
+ version: 0.7.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brittany Martin
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-04-08 00:00:00.000000000 Z
11
+ date: 2020-06-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler