seatsio 36.1.0 → 36.2.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 +3 -1
- data/lib/seatsio/events.rb +8 -5
- data/lib/seatsio/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 51b6694e67b96449da75241064889f2cafefafcd19ce9681068243811e4e7139
|
4
|
+
data.tar.gz: '049e16db09bbca9860f4bd59544eeaa33e9515e220526f5e6ebec8195556fd2d'
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0ffe2521637b1b337eb70d79aac50271f1534811960c40b5fd4c60757e88aa0853bf84c1e8c0ed004ba7612cc3d9019bd668f0757619ddfd167cc8c02aeb6a04
|
7
|
+
data.tar.gz: 44904bc6ff34588a454dcaa501136be6f6b577fa8a039b3c866737e0cf13c1da98d1bf37193f3f95983cce19dd46351acd2fea9b1552d33e9e2cc8ecf10df82e
|
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
|
132
133
|
|
133
134
|
def initialize(data)
|
134
135
|
@id = data['id']
|
@@ -147,6 +148,7 @@ 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']
|
150
152
|
end
|
151
153
|
|
152
154
|
def is_season
|
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/version.rb
CHANGED