seatsio 36.1.0 → 37.0.0
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 +4 -4
- data/Gemfile.lock +1 -1
- data/lib/seatsio/domain.rb +8 -2
- data/lib/seatsio/events.rb +8 -5
- data/lib/seatsio/seasons.rb +1 -1
- data/lib/seatsio/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: 642683cac1004690ea1b9ff67b597a707af152d97496331422c49522ad0143ef
|
4
|
+
data.tar.gz: 9a27cedb746acd0c37f7b215bc6357de4a49a4c7dcec709cf21b079ecfa2951f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1e4702987535eb043a8d3fbfd43b32e29d7c7d75d9ed4253a74f0fbe2c1b0967ffbb568ca6126b83e68a9e82398a376e7cdd878b9f71c2c954ad3803fe472016
|
7
|
+
data.tar.gz: 4ba09151dbe54589911cb8c22b9653978e382fa6f7cd8623a224a7a5de61b0ecff380d58ba777d045b88a9c2cf8cb7b9ad7f0e56fc7685ed78090646daba870e
|
data/Gemfile.lock
CHANGED
data/lib/seatsio/domain.rb
CHANGED
@@ -128,7 +128,8 @@ module Seatsio
|
|
128
128
|
attr_accessor :id, :key, :chart_key, :supports_best_available,
|
129
129
|
:table_booking_config, :for_sale_config, :created_on, :updated_on, :channels,
|
130
130
|
:social_distancing_ruleset_key, :is_top_level_season, :is_partial_season,
|
131
|
-
:is_event_in_season, :top_level_season_key
|
131
|
+
:is_event_in_season, :top_level_season_key,
|
132
|
+
:social_distancing_ruleset_key, :object_categories, :categories
|
132
133
|
|
133
134
|
def initialize(data)
|
134
135
|
@id = data['id']
|
@@ -147,6 +148,8 @@ module Seatsio
|
|
147
148
|
@is_partial_season = data['isPartialSeason']
|
148
149
|
@is_event_in_season = data['isEventInSeason']
|
149
150
|
@top_level_season_key = data['topLevelSeasonKey']
|
151
|
+
@object_categories = data['objectCategories']
|
152
|
+
@categories = data['categories']
|
150
153
|
end
|
151
154
|
|
152
155
|
def is_season
|
@@ -496,7 +499,8 @@ module Seatsio
|
|
496
499
|
end
|
497
500
|
|
498
501
|
class StatusChange
|
499
|
-
attr_reader :extra_data, :object_label, :date, :id, :status, :event_id, :origin, :order_id, :quantity, :hold_token
|
502
|
+
attr_reader :extra_data, :object_label, :date, :id, :status, :event_id, :origin, :order_id, :quantity, :hold_token,
|
503
|
+
:is_present_on_chart, :not_present_on_chart_reason
|
500
504
|
|
501
505
|
def initialize(data)
|
502
506
|
@id = data['id']
|
@@ -509,6 +513,8 @@ module Seatsio
|
|
509
513
|
@order_id = data['orderId']
|
510
514
|
@quantity = data['quantity']
|
511
515
|
@hold_token = data['holdToken']
|
516
|
+
@is_present_on_chart = data['isPresentOnChart']
|
517
|
+
@not_present_on_chart_reason = data['notPresentOnChartReason']
|
512
518
|
end
|
513
519
|
end
|
514
520
|
|
data/lib/seatsio/events.rb
CHANGED
@@ -14,9 +14,11 @@ module Seatsio
|
|
14
14
|
@http_client = http_client
|
15
15
|
end
|
16
16
|
|
17
|
-
def create(chart_key: nil, event_key: nil, table_booking_config: nil, social_distancing_ruleset_key: nil)
|
17
|
+
def create(chart_key: nil, event_key: nil, table_booking_config: nil, social_distancing_ruleset_key: nil, object_categories: nil)
|
18
18
|
payload = build_event_request(chart_key: chart_key, event_key: event_key,
|
19
|
-
table_booking_config: table_booking_config,
|
19
|
+
table_booking_config: table_booking_config,
|
20
|
+
social_distancing_ruleset_key: social_distancing_ruleset_key,
|
21
|
+
object_categories: object_categories)
|
20
22
|
response = @http_client.post("events", payload)
|
21
23
|
Event.new(response)
|
22
24
|
end
|
@@ -27,8 +29,8 @@ module Seatsio
|
|
27
29
|
Events.new(response).events
|
28
30
|
end
|
29
31
|
|
30
|
-
def update(key:, chart_key: nil, event_key: nil, table_booking_config: nil, social_distancing_ruleset_key: nil)
|
31
|
-
payload = build_event_request(chart_key: chart_key, event_key: event_key, table_booking_config: table_booking_config, social_distancing_ruleset_key: social_distancing_ruleset_key)
|
32
|
+
def update(key:, chart_key: nil, event_key: nil, table_booking_config: nil, social_distancing_ruleset_key: nil, object_categories: nil)
|
33
|
+
payload = build_event_request(chart_key: chart_key, event_key: event_key, table_booking_config: table_booking_config, social_distancing_ruleset_key: social_distancing_ruleset_key, object_categories: object_categories)
|
32
34
|
@http_client.post("/events/#{key}", payload)
|
33
35
|
end
|
34
36
|
|
@@ -163,12 +165,13 @@ module Seatsio
|
|
163
165
|
payload
|
164
166
|
end
|
165
167
|
|
166
|
-
def build_event_request(chart_key: nil, event_key: nil, table_booking_config: nil, social_distancing_ruleset_key: nil)
|
168
|
+
def build_event_request(chart_key: nil, event_key: nil, table_booking_config: nil, social_distancing_ruleset_key: nil, object_categories: nil)
|
167
169
|
result = {}
|
168
170
|
result["chartKey"] = chart_key if chart_key
|
169
171
|
result["eventKey"] = event_key if event_key
|
170
172
|
result["tableBookingConfig"] = table_booking_config_to_request(table_booking_config) if table_booking_config != nil
|
171
173
|
result["socialDistancingRulesetKey"] = social_distancing_ruleset_key if social_distancing_ruleset_key != nil
|
174
|
+
result["objectCategories"] = object_categories if object_categories != nil
|
172
175
|
result
|
173
176
|
end
|
174
177
|
|
data/lib/seatsio/seasons.rb
CHANGED
@@ -38,7 +38,7 @@ module Seatsio
|
|
38
38
|
request['eventKeys'] = event_keys if event_keys
|
39
39
|
request['numberOfEvents'] = number_of_events if number_of_events
|
40
40
|
response = @http_client.post("/seasons/#{key}/actions/create-events", request)
|
41
|
-
|
41
|
+
Events.new(response).events
|
42
42
|
end
|
43
43
|
|
44
44
|
def add_events_to_partial_season(top_level_season_key:, partial_season_key:, event_keys:)
|
data/lib/seatsio/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: seatsio
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 37.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Seats.io
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-03-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|