seatsio 36.0.0 → 36.3.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 +12 -2
- data/lib/seatsio/events.rb +8 -5
- 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: cbcb6b61676780895b75ec4c86587da0223f6d9ec19f7e668f1c1f81ed45fae0
|
4
|
+
data.tar.gz: 80cd400a2508ce534ec72b33adba1d65841f179f691db99f5da92bd5630033fc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3e61bedd0b730bf12191278435508d6262b3b4c18caad4f645fdc8029fbc0ce58bbda28222afd9ca4bb0dcfff38a365f885c79bf5ae06dcf051633ab4d4515d5
|
7
|
+
data.tar.gz: 9557685849608a9af3a5494c0cfd34171af2ffa9d92ce8b9c668fb8675f21942251823f9eb1489b73a0eeff8dad60d3f569068d276506854a5266266f007ec0a
|
data/Gemfile.lock
CHANGED
data/lib/seatsio/domain.rb
CHANGED
@@ -127,7 +127,9 @@ module Seatsio
|
|
127
127
|
|
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
|
-
:social_distancing_ruleset_key
|
130
|
+
:social_distancing_ruleset_key, :is_top_level_season, :is_partial_season,
|
131
|
+
:is_event_in_season, :top_level_season_key,
|
132
|
+
:social_distancing_ruleset_key, :object_categories
|
131
133
|
|
132
134
|
def initialize(data)
|
133
135
|
@id = data['id']
|
@@ -142,6 +144,11 @@ module Seatsio
|
|
142
144
|
|d| Channel.new(d['key'], d['name'], d['color'], d['index'], d['objects'])
|
143
145
|
} if data['channels']
|
144
146
|
@social_distancing_ruleset_key = data['socialDistancingRulesetKey']
|
147
|
+
@is_top_level_season = data['isTopLevelSeason']
|
148
|
+
@is_partial_season = data['isPartialSeason']
|
149
|
+
@is_event_in_season = data['isEventInSeason']
|
150
|
+
@top_level_season_key = data['topLevelSeasonKey']
|
151
|
+
@object_categories = data['objectCategories']
|
145
152
|
end
|
146
153
|
|
147
154
|
def is_season
|
@@ -491,7 +498,8 @@ module Seatsio
|
|
491
498
|
end
|
492
499
|
|
493
500
|
class StatusChange
|
494
|
-
attr_reader :extra_data, :object_label, :date, :id, :status, :event_id, :origin, :order_id, :quantity, :hold_token
|
501
|
+
attr_reader :extra_data, :object_label, :date, :id, :status, :event_id, :origin, :order_id, :quantity, :hold_token,
|
502
|
+
:is_present_on_chart, :not_present_on_chart_reason
|
495
503
|
|
496
504
|
def initialize(data)
|
497
505
|
@id = data['id']
|
@@ -504,6 +512,8 @@ module Seatsio
|
|
504
512
|
@order_id = data['orderId']
|
505
513
|
@quantity = data['quantity']
|
506
514
|
@hold_token = data['holdToken']
|
515
|
+
@is_present_on_chart = data['isPresentOnChart']
|
516
|
+
@not_present_on_chart_reason = data['notPresentOnChartReason']
|
507
517
|
end
|
508
518
|
end
|
509
519
|
|
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
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: 36.
|
4
|
+
version: 36.3.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-02-
|
11
|
+
date: 2022-02-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|