seatschart 0.2.0 → 0.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/README.md +162 -15
- data/lib/seatschart/api/audit_api.rb +2 -2
- data/lib/seatschart/api/charts_api.rb +799 -66
- data/lib/seatschart/api/embed_api.rb +5 -5
- data/lib/seatschart/api/embed_origins_api.rb +63 -2
- data/lib/seatschart/api/event_log_api.rb +2 -2
- data/lib/seatschart/api/events_api.rb +1471 -155
- data/lib/seatschart/api/health_api.rb +244 -0
- data/lib/seatschart/api/map_designer_api.rb +11 -9
- data/lib/seatschart/api/public_api.rb +350 -0
- data/lib/seatschart/api/sandboxes_api.rb +672 -0
- data/lib/seatschart/api/seasons_api.rb +344 -36
- data/lib/seatschart/api/seats_api.rb +10 -10
- data/lib/seatschart/api/usage_api.rb +18 -15
- data/lib/seatschart/api/webhooks_api.rb +2 -2
- data/lib/seatschart/api/workspace_api.rb +306 -20
- data/lib/seatschart/models/api_error.rb +4 -4
- data/lib/seatschart/models/delete_api_sandboxes_by_sandbox_id200_response.rb +255 -0
- data/lib/seatschart/models/get_api_monitoring_requests200_response.rb +62 -4
- data/lib/seatschart/models/get_api_monitoring_requests200_response_points_inner.rb +21 -4
- data/lib/seatschart/models/get_api_sandboxes200_response.rb +239 -0
- data/lib/seatschart/models/get_api_sandboxes200_response_items_inner.rb +431 -0
- data/lib/seatschart/models/get_api_sandboxes200_response_items_inner_rate_limits.rb +270 -0
- data/lib/seatschart/models/get_api_sandboxes200_response_items_inner_usage.rb +287 -0
- data/lib/seatschart/models/get_api_status200_response.rb +387 -0
- data/lib/seatschart/models/get_api_status200_response_components_inner.rb +330 -0
- data/lib/seatschart/models/get_api_status200_response_components_inner_days_inner.rb +301 -0
- data/lib/seatschart/models/get_api_status200_response_incidents_inner.rb +374 -0
- data/lib/seatschart/models/get_api_status200_response_maintenance_inner.rb +350 -0
- data/lib/seatschart/models/get_api_status503_response.rb +271 -0
- data/lib/seatschart/models/get_api_workspace_buyer_extra_data200_response.rb +241 -0
- data/lib/seatschart/models/get_api_workspace_defaults200_response.rb +254 -0
- data/lib/seatschart/models/get_api_workspace_defaults200_response_renderer.rb +246 -0
- data/lib/seatschart/models/get_api_workspace_defaults200_response_renderer_built_in.rb +270 -0
- data/lib/seatschart/models/get_api_workspaces200_response_items_inner.rb +34 -5
- data/lib/seatschart/models/patch_api_events_by_event_id_request.rb +16 -6
- data/lib/seatschart/models/patch_api_seasons_by_season_id_request.rb +15 -5
- data/lib/seatschart/models/patch_api_workspace_chart_validation_request_severities.rb +25 -4
- data/lib/seatschart/models/patch_api_workspace_defaults_request.rb +224 -0
- data/lib/seatschart/models/patch_api_workspace_defaults_request_renderer.rb +249 -0
- data/lib/seatschart/models/patch_api_workspace_settings_request.rb +6 -6
- data/lib/seatschart/models/post_api_charts_by_chart_id_actions_copy_to_workspace_request.rb +39 -1
- data/lib/seatschart/models/post_api_charts_by_chart_id_actions_validate_request.rb +1 -0
- data/lib/seatschart/models/post_api_charts_by_chart_id_map_publish422_response_issues_inner.rb +64 -6
- data/lib/seatschart/models/post_api_charts_by_chart_id_map_publish_request.rb +1 -1
- data/lib/seatschart/models/post_api_embed_tokens_request.rb +18 -15
- data/lib/seatschart/models/post_api_embed_tokens_request_safe_mode_options.rb +226 -0
- data/lib/seatschart/models/post_api_events_actions_edit_for_sale_config_request.rb +251 -0
- data/lib/seatschart/models/post_api_events_actions_edit_for_sale_config_request_events_inner.rb +322 -0
- data/lib/seatschart/models/post_api_events_bulk_request_events_inner.rb +42 -1
- data/lib/seatschart/models/post_api_events_by_event_id_actions_edit_for_sale_config_request.rb +277 -0
- data/lib/seatschart/models/post_api_events_by_event_id_actions_edit_for_sale_config_request_for_sale_inner.rb +319 -0
- data/lib/seatschart/models/post_api_events_by_event_id_map_publish_request.rb +215 -0
- data/lib/seatschart/models/post_api_events_request.rb +42 -1
- data/lib/seatschart/models/{patch_api_events_by_event_id_request_categories_inner.rb → post_api_events_request_categories_inner.rb} +3 -3
- data/lib/seatschart/models/post_api_extract_seats200_response.rb +459 -0
- data/lib/seatschart/models/post_api_extract_seats200_response_seats_inner.rb +323 -0
- data/lib/seatschart/models/post_api_extract_seats200_response_suggested_inner.rb +320 -0
- data/lib/seatschart/models/post_api_extract_seats_request.rb +124 -4
- data/lib/seatschart/models/post_api_extract_seats_request_examples.rb +105 -0
- data/lib/seatschart/models/post_api_extract_seats_request_examples_any_of_inner.rb +293 -0
- data/lib/seatschart/models/post_api_extract_seats_request_negatives.rb +105 -0
- data/lib/seatschart/models/post_api_extract_seats_request_region.rb +105 -0
- data/lib/seatschart/models/post_api_extract_seats_request_region_any_of.rb +363 -0
- data/lib/seatschart/models/post_api_sandboxes201_response.rb +245 -0
- data/lib/seatschart/models/post_api_sandboxes201_response_admin_key.rb +286 -0
- data/lib/seatschart/models/post_api_sandboxes201_response_copied.rb +313 -0
- data/lib/seatschart/models/post_api_sandboxes201_response_copied_charts_inner.rb +281 -0
- data/lib/seatschart/models/post_api_sandboxes201_response_copied_events_inner.rb +281 -0
- data/lib/seatschart/models/post_api_sandboxes201_response_copied_events_with_own_map_inner.rb +265 -0
- data/lib/seatschart/models/post_api_sandboxes201_response_copied_key_conflicts_inner.rb +287 -0
- data/lib/seatschart/models/post_api_sandboxes201_response_copied_seasons_inner.rb +312 -0
- data/lib/seatschart/models/post_api_sandboxes_by_sandbox_id_actions_copy_from_production200_response.rb +313 -0
- data/lib/seatschart/models/post_api_sandboxes_by_sandbox_id_actions_copy_from_production_request.rb +255 -0
- data/lib/seatschart/models/post_api_sandboxes_by_sandbox_id_actions_join200_response.rb +271 -0
- data/lib/seatschart/models/post_api_sandboxes_by_sandbox_id_actions_reset200_response.rb +268 -0
- data/lib/seatschart/models/post_api_sandboxes_by_sandbox_id_actions_reset_request.rb +225 -0
- data/lib/seatschart/models/post_api_sandboxes_by_sandbox_id_admin_key201_response.rb +253 -0
- data/lib/seatschart/models/post_api_sandboxes_by_sandbox_id_admin_key201_response_api_key.rb +286 -0
- data/lib/seatschart/models/post_api_sandboxes_by_sandbox_id_admin_key_request.rb +252 -0
- data/lib/seatschart/models/post_api_sandboxes_request.rb +319 -0
- data/lib/seatschart/models/post_api_seasons_request.rb +14 -4
- data/lib/seatschart/models/post_api_seats_confirm_request.rb +5 -5
- data/lib/seatschart/models/post_api_seats_release_request.rb +5 -5
- data/lib/seatschart/models/post_api_seats_reserve_request.rb +5 -5
- data/lib/seatschart/models/post_api_workspaces_request.rb +1 -1
- data/lib/seatschart/models/put_api_charts_by_chart_id_map_draft_request.rb +1 -0
- data/lib/seatschart/models/put_api_workspace_buyer_extra_data_request.rb +260 -0
- data/lib/seatschart/models/put_internal_status_notices_request.rb +242 -0
- data/lib/seatschart/models/put_internal_status_notices_request_notices_inner.rb +445 -0
- data/lib/seatschart/retry.rb +106 -7
- data/lib/seatschart/version.rb +1 -1
- data/lib/seatschart.rb +53 -2
- metadata +55 -4
- data/lib/seatschart/api/default_api.rb +0 -763
|
@@ -18,12 +18,16 @@ module SeatsChart
|
|
|
18
18
|
# Target workspace id (see GET /workspaces).
|
|
19
19
|
attr_accessor :workspace_id
|
|
20
20
|
|
|
21
|
+
# Source workspace id (default: the calling workspace). seats.io copyFromWorkspaceTo: copy a chart of another workspace the same admin administers; pass the chart id (UUID), keys resolve in the calling workspace only.
|
|
22
|
+
attr_accessor :from_workspace_id
|
|
23
|
+
|
|
21
24
|
attr_accessor :name
|
|
22
25
|
|
|
23
26
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
24
27
|
def self.attribute_map
|
|
25
28
|
{
|
|
26
29
|
:'workspace_id' => :'workspaceId',
|
|
30
|
+
:'from_workspace_id' => :'fromWorkspaceId',
|
|
27
31
|
:'name' => :'name'
|
|
28
32
|
}
|
|
29
33
|
end
|
|
@@ -37,6 +41,7 @@ module SeatsChart
|
|
|
37
41
|
def self.openapi_types
|
|
38
42
|
{
|
|
39
43
|
:'workspace_id' => :'String',
|
|
44
|
+
:'from_workspace_id' => :'String',
|
|
40
45
|
:'name' => :'String'
|
|
41
46
|
}
|
|
42
47
|
end
|
|
@@ -68,6 +73,10 @@ module SeatsChart
|
|
|
68
73
|
self.workspace_id = nil
|
|
69
74
|
end
|
|
70
75
|
|
|
76
|
+
if attributes.key?(:'from_workspace_id')
|
|
77
|
+
self.from_workspace_id = attributes[:'from_workspace_id']
|
|
78
|
+
end
|
|
79
|
+
|
|
71
80
|
if attributes.key?(:'name')
|
|
72
81
|
self.name = attributes[:'name']
|
|
73
82
|
end
|
|
@@ -90,6 +99,14 @@ module SeatsChart
|
|
|
90
99
|
invalid_properties.push('invalid value for "workspace_id", the character length must be great than or equal to 1.')
|
|
91
100
|
end
|
|
92
101
|
|
|
102
|
+
if !@from_workspace_id.nil? && @from_workspace_id.to_s.length > 128
|
|
103
|
+
invalid_properties.push('invalid value for "from_workspace_id", the character length must be smaller than or equal to 128.')
|
|
104
|
+
end
|
|
105
|
+
|
|
106
|
+
if !@from_workspace_id.nil? && @from_workspace_id.to_s.length < 1
|
|
107
|
+
invalid_properties.push('invalid value for "from_workspace_id", the character length must be great than or equal to 1.')
|
|
108
|
+
end
|
|
109
|
+
|
|
93
110
|
if !@name.nil? && @name.to_s.length > 512
|
|
94
111
|
invalid_properties.push('invalid value for "name", the character length must be smaller than or equal to 512.')
|
|
95
112
|
end
|
|
@@ -108,6 +125,8 @@ module SeatsChart
|
|
|
108
125
|
return false if @workspace_id.nil?
|
|
109
126
|
return false if @workspace_id.to_s.length > 128
|
|
110
127
|
return false if @workspace_id.to_s.length < 1
|
|
128
|
+
return false if !@from_workspace_id.nil? && @from_workspace_id.to_s.length > 128
|
|
129
|
+
return false if !@from_workspace_id.nil? && @from_workspace_id.to_s.length < 1
|
|
111
130
|
return false if !@name.nil? && @name.to_s.length > 512
|
|
112
131
|
return false if !@name.nil? && @name.to_s.length < 1
|
|
113
132
|
true
|
|
@@ -131,6 +150,24 @@ module SeatsChart
|
|
|
131
150
|
@workspace_id = workspace_id
|
|
132
151
|
end
|
|
133
152
|
|
|
153
|
+
# Custom attribute writer method with validation
|
|
154
|
+
# @param [Object] from_workspace_id Value to be assigned
|
|
155
|
+
def from_workspace_id=(from_workspace_id)
|
|
156
|
+
if from_workspace_id.nil?
|
|
157
|
+
fail ArgumentError, 'from_workspace_id cannot be nil'
|
|
158
|
+
end
|
|
159
|
+
|
|
160
|
+
if from_workspace_id.to_s.length > 128
|
|
161
|
+
fail ArgumentError, 'invalid value for "from_workspace_id", the character length must be smaller than or equal to 128.'
|
|
162
|
+
end
|
|
163
|
+
|
|
164
|
+
if from_workspace_id.to_s.length < 1
|
|
165
|
+
fail ArgumentError, 'invalid value for "from_workspace_id", the character length must be great than or equal to 1.'
|
|
166
|
+
end
|
|
167
|
+
|
|
168
|
+
@from_workspace_id = from_workspace_id
|
|
169
|
+
end
|
|
170
|
+
|
|
134
171
|
# Custom attribute writer method with validation
|
|
135
172
|
# @param [Object] name Value to be assigned
|
|
136
173
|
def name=(name)
|
|
@@ -155,6 +192,7 @@ module SeatsChart
|
|
|
155
192
|
return true if self.equal?(o)
|
|
156
193
|
self.class == o.class &&
|
|
157
194
|
workspace_id == o.workspace_id &&
|
|
195
|
+
from_workspace_id == o.from_workspace_id &&
|
|
158
196
|
name == o.name
|
|
159
197
|
end
|
|
160
198
|
|
|
@@ -167,7 +205,7 @@ module SeatsChart
|
|
|
167
205
|
# Calculates hash code according to all attributes.
|
|
168
206
|
# @return [Integer] Hash code
|
|
169
207
|
def hash
|
|
170
|
-
[workspace_id, name].hash
|
|
208
|
+
[workspace_id, from_workspace_id, name].hash
|
|
171
209
|
end
|
|
172
210
|
|
|
173
211
|
# Builds the object from hash
|
|
@@ -17,6 +17,7 @@ module SeatsChart
|
|
|
17
17
|
class PostApiChartsByChartIdActionsValidateRequest
|
|
18
18
|
attr_accessor :seats
|
|
19
19
|
|
|
20
|
+
# Layout shapes (sections, zones, GA areas, tables, icons…) and one `layoutMeta`. `layoutMeta.settings3d` holds the authored 3D (elevation / rake per section or zone, floors, light preset, spectator target) and the 3D billboards: `billboards` (at most 64 boards, each `{ id, points: [{x, y}] (2-64, map px), height?: m (0.2-20, default 1), elevation?: m (-20-100), scroll?: \"reverse\" | \"off\" }`) and `billboardImages` (at most 12 sponsor images shared by every board, in scroll order: base64 WebP / PNG / JPEG data URLs, stored to the map-asset CDN when configured, or map-asset URLs). Invalid values are refused with 400 `validation_error`, never clamped. `settings3d.seatPicking` (boolean) is the chart-level \"Allow 3D seat picking\" switch (absent: on for charts that author 3D). Optional fields published only when set: tables `oneSide` (rectangular, every guest on one long side) and `openSpaces` (1-20 empty chair positions); text `bold` / `italic`; decorative shapes `layer: \"foreground\"` (drawn above the seats for buyers, never interactive); `layoutMeta.floors[].abbreviation` (at most 6 characters) and `layoutMeta.displayTypes` (object id → displayed type, at most 64 characters, seats.io `displayObjectType`). Designer-only metadata (`bytes` on images, `layoutMeta.backgroundBytes`) feeds the `images_size` check and is never published.
|
|
20
21
|
attr_accessor :shapes
|
|
21
22
|
|
|
22
23
|
attr_accessor :background
|
data/lib/seatschart/models/post_api_charts_by_chart_id_map_publish422_response_issues_inner.rb
CHANGED
|
@@ -38,6 +38,12 @@ module SeatsChart
|
|
|
38
38
|
|
|
39
39
|
attr_accessor :floor_id
|
|
40
40
|
|
|
41
|
+
# `duplicate_label` across sections: how many sections sharing the label `sectionId` (or unlabeled sections) hold the object.
|
|
42
|
+
attr_accessor :sections
|
|
43
|
+
|
|
44
|
+
# `images_size`: known total download size of the chart images, in bytes.
|
|
45
|
+
attr_accessor :bytes
|
|
46
|
+
|
|
41
47
|
class EnumAttributeValidator
|
|
42
48
|
attr_reader :datatype
|
|
43
49
|
attr_reader :allowable_values
|
|
@@ -72,7 +78,9 @@ module SeatsChart
|
|
|
72
78
|
:'section_id' => :'sectionId',
|
|
73
79
|
:'table_ids' => :'tableIds',
|
|
74
80
|
:'scope' => :'scope',
|
|
75
|
-
:'floor_id' => :'floorId'
|
|
81
|
+
:'floor_id' => :'floorId',
|
|
82
|
+
:'sections' => :'sections',
|
|
83
|
+
:'bytes' => :'bytes'
|
|
76
84
|
}
|
|
77
85
|
end
|
|
78
86
|
|
|
@@ -93,7 +101,9 @@ module SeatsChart
|
|
|
93
101
|
:'section_id' => :'String',
|
|
94
102
|
:'table_ids' => :'Array<String>',
|
|
95
103
|
:'scope' => :'String',
|
|
96
|
-
:'floor_id' => :'String'
|
|
104
|
+
:'floor_id' => :'String',
|
|
105
|
+
:'sections' => :'Integer',
|
|
106
|
+
:'bytes' => :'Integer'
|
|
97
107
|
}
|
|
98
108
|
end
|
|
99
109
|
|
|
@@ -171,6 +181,14 @@ module SeatsChart
|
|
|
171
181
|
if attributes.key?(:'floor_id')
|
|
172
182
|
self.floor_id = attributes[:'floor_id']
|
|
173
183
|
end
|
|
184
|
+
|
|
185
|
+
if attributes.key?(:'sections')
|
|
186
|
+
self.sections = attributes[:'sections']
|
|
187
|
+
end
|
|
188
|
+
|
|
189
|
+
if attributes.key?(:'bytes')
|
|
190
|
+
self.bytes = attributes[:'bytes']
|
|
191
|
+
end
|
|
174
192
|
end
|
|
175
193
|
|
|
176
194
|
# Show invalid properties with the reasons. Usually used together with valid?
|
|
@@ -202,6 +220,14 @@ module SeatsChart
|
|
|
202
220
|
invalid_properties.push('invalid value for "count", must be greater than or equal to 0.')
|
|
203
221
|
end
|
|
204
222
|
|
|
223
|
+
if !@sections.nil? && @sections < 2
|
|
224
|
+
invalid_properties.push('invalid value for "sections", must be greater than or equal to 2.')
|
|
225
|
+
end
|
|
226
|
+
|
|
227
|
+
if !@bytes.nil? && @bytes < 0
|
|
228
|
+
invalid_properties.push('invalid value for "bytes", must be greater than or equal to 0.')
|
|
229
|
+
end
|
|
230
|
+
|
|
205
231
|
invalid_properties
|
|
206
232
|
end
|
|
207
233
|
|
|
@@ -210,7 +236,7 @@ module SeatsChart
|
|
|
210
236
|
def valid?
|
|
211
237
|
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
212
238
|
return false if @code.nil?
|
|
213
|
-
code_validator = EnumAttributeValidator.new('String', ["no_objects", "empty_label", "duplicate_label", "uncategorized", "overlap", "table_too_small", "ga_invalid_capacity", "ga_table_capacity", "empty_floor", "empty_section", "outside_section", "multiple_object_types", "missing_focal_point", "zone_missing_focal_point", "orphan_gap"])
|
|
239
|
+
code_validator = EnumAttributeValidator.new('String', ["no_objects", "empty_label", "duplicate_label", "uncategorized", "overlap", "table_too_small", "ga_invalid_capacity", "ga_table_capacity", "empty_floor", "empty_section", "outside_section", "multiple_object_types", "missing_focal_point", "zone_missing_focal_point", "orphan_gap", "images_size"])
|
|
214
240
|
return false unless code_validator.valid?(@code)
|
|
215
241
|
return false if @severity.nil?
|
|
216
242
|
severity_validator = EnumAttributeValidator.new('String', ["error", "warning"])
|
|
@@ -219,13 +245,15 @@ module SeatsChart
|
|
|
219
245
|
return false if @message.nil?
|
|
220
246
|
return false if @count.nil?
|
|
221
247
|
return false if @count < 0
|
|
248
|
+
return false if !@sections.nil? && @sections < 2
|
|
249
|
+
return false if !@bytes.nil? && @bytes < 0
|
|
222
250
|
true
|
|
223
251
|
end
|
|
224
252
|
|
|
225
253
|
# Custom attribute writer method checking allowed values (enum).
|
|
226
254
|
# @param [Object] code Object to be assigned
|
|
227
255
|
def code=(code)
|
|
228
|
-
validator = EnumAttributeValidator.new('String', ["no_objects", "empty_label", "duplicate_label", "uncategorized", "overlap", "table_too_small", "ga_invalid_capacity", "ga_table_capacity", "empty_floor", "empty_section", "outside_section", "multiple_object_types", "missing_focal_point", "zone_missing_focal_point", "orphan_gap"])
|
|
256
|
+
validator = EnumAttributeValidator.new('String', ["no_objects", "empty_label", "duplicate_label", "uncategorized", "overlap", "table_too_small", "ga_invalid_capacity", "ga_table_capacity", "empty_floor", "empty_section", "outside_section", "multiple_object_types", "missing_focal_point", "zone_missing_focal_point", "orphan_gap", "images_size"])
|
|
229
257
|
unless validator.valid?(code)
|
|
230
258
|
fail ArgumentError, "invalid value for \"code\", must be one of #{validator.allowable_values}."
|
|
231
259
|
end
|
|
@@ -256,6 +284,34 @@ module SeatsChart
|
|
|
256
284
|
@count = count
|
|
257
285
|
end
|
|
258
286
|
|
|
287
|
+
# Custom attribute writer method with validation
|
|
288
|
+
# @param [Object] sections Value to be assigned
|
|
289
|
+
def sections=(sections)
|
|
290
|
+
if sections.nil?
|
|
291
|
+
fail ArgumentError, 'sections cannot be nil'
|
|
292
|
+
end
|
|
293
|
+
|
|
294
|
+
if sections < 2
|
|
295
|
+
fail ArgumentError, 'invalid value for "sections", must be greater than or equal to 2.'
|
|
296
|
+
end
|
|
297
|
+
|
|
298
|
+
@sections = sections
|
|
299
|
+
end
|
|
300
|
+
|
|
301
|
+
# Custom attribute writer method with validation
|
|
302
|
+
# @param [Object] bytes Value to be assigned
|
|
303
|
+
def bytes=(bytes)
|
|
304
|
+
if bytes.nil?
|
|
305
|
+
fail ArgumentError, 'bytes cannot be nil'
|
|
306
|
+
end
|
|
307
|
+
|
|
308
|
+
if bytes < 0
|
|
309
|
+
fail ArgumentError, 'invalid value for "bytes", must be greater than or equal to 0.'
|
|
310
|
+
end
|
|
311
|
+
|
|
312
|
+
@bytes = bytes
|
|
313
|
+
end
|
|
314
|
+
|
|
259
315
|
# Checks equality by comparing each attribute.
|
|
260
316
|
# @param [Object] Object to be compared
|
|
261
317
|
def ==(o)
|
|
@@ -270,7 +326,9 @@ module SeatsChart
|
|
|
270
326
|
section_id == o.section_id &&
|
|
271
327
|
table_ids == o.table_ids &&
|
|
272
328
|
scope == o.scope &&
|
|
273
|
-
floor_id == o.floor_id
|
|
329
|
+
floor_id == o.floor_id &&
|
|
330
|
+
sections == o.sections &&
|
|
331
|
+
bytes == o.bytes
|
|
274
332
|
end
|
|
275
333
|
|
|
276
334
|
# @see the `==` method
|
|
@@ -282,7 +340,7 @@ module SeatsChart
|
|
|
282
340
|
# Calculates hash code according to all attributes.
|
|
283
341
|
# @return [Integer] Hash code
|
|
284
342
|
def hash
|
|
285
|
-
[code, severity, object_ids, message, count, label, section_id, table_ids, scope, floor_id].hash
|
|
343
|
+
[code, severity, object_ids, message, count, label, section_id, table_ids, scope, floor_id, sections, bytes].hash
|
|
286
344
|
end
|
|
287
345
|
|
|
288
346
|
# Builds the object from hash
|
|
@@ -18,7 +18,7 @@ module SeatsChart
|
|
|
18
18
|
# Optional release note stored on the version record (shown in version history).
|
|
19
19
|
attr_accessor :note
|
|
20
20
|
|
|
21
|
-
# Set by the designer auto-publish option. The publish is refused with 409 `ERR_AUTO_PUBLISH_CHART_HAS_EVENTS` (params.eventCount) when any event uses the chart.
|
|
21
|
+
# Set by the designer auto-publish option. The publish is refused with 409 `ERR_AUTO_PUBLISH_CHART_HAS_EVENTS` (params.eventCount) when any event uses the chart, unless the workspace publishes designer changes directly (`draftChartDrawingsEnabled: false`, see GET /api/workspace/defaults).
|
|
22
22
|
attr_accessor :auto_publish
|
|
23
23
|
|
|
24
24
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
@@ -21,8 +21,11 @@ module SeatsChart
|
|
|
21
21
|
|
|
22
22
|
attr_accessor :event_id
|
|
23
23
|
|
|
24
|
+
# Designer tokens only, enforced by the API (default `normal`, full edit). `safe`: saves, publishes and version restores that would delete or relabel published objects, change the booking type of a published table or area, or change the capacity of a published area are refused with 403 `forbidden` / `ERR_DESIGNER_SAFE_MODE` (`reason`, `objectIds`). `readOnly`: every write is refused with 403 `forbidden` / `ERR_DESIGNER_READ_ONLY`.
|
|
24
25
|
attr_accessor :mode
|
|
25
26
|
|
|
27
|
+
attr_accessor :safe_mode_options
|
|
28
|
+
|
|
26
29
|
attr_accessor :ttl_seconds
|
|
27
30
|
|
|
28
31
|
class EnumAttributeValidator
|
|
@@ -54,6 +57,7 @@ module SeatsChart
|
|
|
54
57
|
:'chart_id' => :'chartId',
|
|
55
58
|
:'event_id' => :'eventId',
|
|
56
59
|
:'mode' => :'mode',
|
|
60
|
+
:'safe_mode_options' => :'safeModeOptions',
|
|
57
61
|
:'ttl_seconds' => :'ttlSeconds'
|
|
58
62
|
}
|
|
59
63
|
end
|
|
@@ -70,6 +74,7 @@ module SeatsChart
|
|
|
70
74
|
:'chart_id' => :'String',
|
|
71
75
|
:'event_id' => :'String',
|
|
72
76
|
:'mode' => :'String',
|
|
77
|
+
:'safe_mode_options' => :'PostApiEmbedTokensRequestSafeModeOptions',
|
|
73
78
|
:'ttl_seconds' => :'Integer'
|
|
74
79
|
}
|
|
75
80
|
end
|
|
@@ -113,6 +118,10 @@ module SeatsChart
|
|
|
113
118
|
self.mode = attributes[:'mode']
|
|
114
119
|
end
|
|
115
120
|
|
|
121
|
+
if attributes.key?(:'safe_mode_options')
|
|
122
|
+
self.safe_mode_options = attributes[:'safe_mode_options']
|
|
123
|
+
end
|
|
124
|
+
|
|
116
125
|
if attributes.key?(:'ttl_seconds')
|
|
117
126
|
self.ttl_seconds = attributes[:'ttl_seconds']
|
|
118
127
|
end
|
|
@@ -143,10 +152,6 @@ module SeatsChart
|
|
|
143
152
|
invalid_properties.push('invalid value for "event_id", the character length must be great than or equal to 36.')
|
|
144
153
|
end
|
|
145
154
|
|
|
146
|
-
if !@mode.nil? && @mode.to_s.length > 64
|
|
147
|
-
invalid_properties.push('invalid value for "mode", the character length must be smaller than or equal to 64.')
|
|
148
|
-
end
|
|
149
|
-
|
|
150
155
|
if !@ttl_seconds.nil? && @ttl_seconds > 1800
|
|
151
156
|
invalid_properties.push('invalid value for "ttl_seconds", must be smaller than or equal to 1800.')
|
|
152
157
|
end
|
|
@@ -169,7 +174,8 @@ module SeatsChart
|
|
|
169
174
|
return false if !@chart_id.nil? && @chart_id.to_s.length < 36
|
|
170
175
|
return false if !@event_id.nil? && @event_id.to_s.length > 36
|
|
171
176
|
return false if !@event_id.nil? && @event_id.to_s.length < 36
|
|
172
|
-
|
|
177
|
+
mode_validator = EnumAttributeValidator.new('String', ["normal", "safe", "readOnly"])
|
|
178
|
+
return false unless mode_validator.valid?(@mode)
|
|
173
179
|
return false if !@ttl_seconds.nil? && @ttl_seconds > 1800
|
|
174
180
|
return false if !@ttl_seconds.nil? && @ttl_seconds < 60
|
|
175
181
|
true
|
|
@@ -221,17 +227,13 @@ module SeatsChart
|
|
|
221
227
|
@event_id = event_id
|
|
222
228
|
end
|
|
223
229
|
|
|
224
|
-
# Custom attribute writer method
|
|
225
|
-
# @param [Object] mode
|
|
230
|
+
# Custom attribute writer method checking allowed values (enum).
|
|
231
|
+
# @param [Object] mode Object to be assigned
|
|
226
232
|
def mode=(mode)
|
|
227
|
-
|
|
228
|
-
|
|
233
|
+
validator = EnumAttributeValidator.new('String', ["normal", "safe", "readOnly"])
|
|
234
|
+
unless validator.valid?(mode)
|
|
235
|
+
fail ArgumentError, "invalid value for \"mode\", must be one of #{validator.allowable_values}."
|
|
229
236
|
end
|
|
230
|
-
|
|
231
|
-
if mode.to_s.length > 64
|
|
232
|
-
fail ArgumentError, 'invalid value for "mode", the character length must be smaller than or equal to 64.'
|
|
233
|
-
end
|
|
234
|
-
|
|
235
237
|
@mode = mode
|
|
236
238
|
end
|
|
237
239
|
|
|
@@ -262,6 +264,7 @@ module SeatsChart
|
|
|
262
264
|
chart_id == o.chart_id &&
|
|
263
265
|
event_id == o.event_id &&
|
|
264
266
|
mode == o.mode &&
|
|
267
|
+
safe_mode_options == o.safe_mode_options &&
|
|
265
268
|
ttl_seconds == o.ttl_seconds
|
|
266
269
|
end
|
|
267
270
|
|
|
@@ -274,7 +277,7 @@ module SeatsChart
|
|
|
274
277
|
# Calculates hash code according to all attributes.
|
|
275
278
|
# @return [Integer] Hash code
|
|
276
279
|
def hash
|
|
277
|
-
[purpose, chart_id, event_id, mode, ttl_seconds].hash
|
|
280
|
+
[purpose, chart_id, event_id, mode, safe_mode_options, ttl_seconds].hash
|
|
278
281
|
end
|
|
279
282
|
|
|
280
283
|
# Builds the object from hash
|
|
@@ -0,0 +1,226 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#SeatsChart API
|
|
3
|
+
|
|
4
|
+
#Seat inventory and locking API for B2B2C integrations. Authenticate using `x-api-key` (partners) or `Authorization: Bearer` with an HS256 JWT.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 1.0.0
|
|
7
|
+
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.11.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
require 'time'
|
|
15
|
+
|
|
16
|
+
module SeatsChart
|
|
17
|
+
# Exceptions to safe mode (seats.io `safeModeOptions`); only with `mode: \"safe\"`.
|
|
18
|
+
class PostApiEmbedTokensRequestSafeModeOptions
|
|
19
|
+
# Allow deleting published objects (default false).
|
|
20
|
+
attr_accessor :allow_deleting_objects
|
|
21
|
+
|
|
22
|
+
# Allow changing the capacity of published areas (default false).
|
|
23
|
+
attr_accessor :allow_editing_area_capacity
|
|
24
|
+
|
|
25
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
26
|
+
def self.attribute_map
|
|
27
|
+
{
|
|
28
|
+
:'allow_deleting_objects' => :'allowDeletingObjects',
|
|
29
|
+
:'allow_editing_area_capacity' => :'allowEditingAreaCapacity'
|
|
30
|
+
}
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
# Returns all the JSON keys this model knows about
|
|
34
|
+
def self.acceptable_attributes
|
|
35
|
+
attribute_map.values
|
|
36
|
+
end
|
|
37
|
+
|
|
38
|
+
# Attribute type mapping.
|
|
39
|
+
def self.openapi_types
|
|
40
|
+
{
|
|
41
|
+
:'allow_deleting_objects' => :'Boolean',
|
|
42
|
+
:'allow_editing_area_capacity' => :'Boolean'
|
|
43
|
+
}
|
|
44
|
+
end
|
|
45
|
+
|
|
46
|
+
# List of attributes with nullable: true
|
|
47
|
+
def self.openapi_nullable
|
|
48
|
+
Set.new([
|
|
49
|
+
])
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
# Initializes the object
|
|
53
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
54
|
+
def initialize(attributes = {})
|
|
55
|
+
if (!attributes.is_a?(Hash))
|
|
56
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `SeatsChart::PostApiEmbedTokensRequestSafeModeOptions` initialize method"
|
|
57
|
+
end
|
|
58
|
+
|
|
59
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
60
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
61
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
|
62
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `SeatsChart::PostApiEmbedTokensRequestSafeModeOptions`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
|
63
|
+
end
|
|
64
|
+
h[k.to_sym] = v
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
if attributes.key?(:'allow_deleting_objects')
|
|
68
|
+
self.allow_deleting_objects = attributes[:'allow_deleting_objects']
|
|
69
|
+
end
|
|
70
|
+
|
|
71
|
+
if attributes.key?(:'allow_editing_area_capacity')
|
|
72
|
+
self.allow_editing_area_capacity = attributes[:'allow_editing_area_capacity']
|
|
73
|
+
end
|
|
74
|
+
end
|
|
75
|
+
|
|
76
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
77
|
+
# @return Array for valid properties with the reasons
|
|
78
|
+
def list_invalid_properties
|
|
79
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
80
|
+
invalid_properties = Array.new
|
|
81
|
+
invalid_properties
|
|
82
|
+
end
|
|
83
|
+
|
|
84
|
+
# Check to see if the all the properties in the model are valid
|
|
85
|
+
# @return true if the model is valid
|
|
86
|
+
def valid?
|
|
87
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
88
|
+
true
|
|
89
|
+
end
|
|
90
|
+
|
|
91
|
+
# Checks equality by comparing each attribute.
|
|
92
|
+
# @param [Object] Object to be compared
|
|
93
|
+
def ==(o)
|
|
94
|
+
return true if self.equal?(o)
|
|
95
|
+
self.class == o.class &&
|
|
96
|
+
allow_deleting_objects == o.allow_deleting_objects &&
|
|
97
|
+
allow_editing_area_capacity == o.allow_editing_area_capacity
|
|
98
|
+
end
|
|
99
|
+
|
|
100
|
+
# @see the `==` method
|
|
101
|
+
# @param [Object] Object to be compared
|
|
102
|
+
def eql?(o)
|
|
103
|
+
self == o
|
|
104
|
+
end
|
|
105
|
+
|
|
106
|
+
# Calculates hash code according to all attributes.
|
|
107
|
+
# @return [Integer] Hash code
|
|
108
|
+
def hash
|
|
109
|
+
[allow_deleting_objects, allow_editing_area_capacity].hash
|
|
110
|
+
end
|
|
111
|
+
|
|
112
|
+
# Builds the object from hash
|
|
113
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
114
|
+
# @return [Object] Returns the model itself
|
|
115
|
+
def self.build_from_hash(attributes)
|
|
116
|
+
return nil unless attributes.is_a?(Hash)
|
|
117
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
118
|
+
transformed_hash = {}
|
|
119
|
+
openapi_types.each_pair do |key, type|
|
|
120
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
|
121
|
+
transformed_hash["#{key}"] = nil
|
|
122
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
123
|
+
# check to ensure the input is an array given that the attribute
|
|
124
|
+
# is documented as an array but the input is not
|
|
125
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
|
126
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
|
127
|
+
end
|
|
128
|
+
elsif !attributes[attribute_map[key]].nil?
|
|
129
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
|
130
|
+
end
|
|
131
|
+
end
|
|
132
|
+
new(transformed_hash)
|
|
133
|
+
end
|
|
134
|
+
|
|
135
|
+
# Deserializes the data based on type
|
|
136
|
+
# @param string type Data type
|
|
137
|
+
# @param string value Value to be deserialized
|
|
138
|
+
# @return [Object] Deserialized data
|
|
139
|
+
def self._deserialize(type, value)
|
|
140
|
+
case type.to_sym
|
|
141
|
+
when :Time
|
|
142
|
+
Time.parse(value)
|
|
143
|
+
when :Date
|
|
144
|
+
Date.parse(value)
|
|
145
|
+
when :String
|
|
146
|
+
value.to_s
|
|
147
|
+
when :Integer
|
|
148
|
+
value.to_i
|
|
149
|
+
when :Float
|
|
150
|
+
value.to_f
|
|
151
|
+
when :Boolean
|
|
152
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
153
|
+
true
|
|
154
|
+
else
|
|
155
|
+
false
|
|
156
|
+
end
|
|
157
|
+
when :Object
|
|
158
|
+
# generic object (usually a Hash), return directly
|
|
159
|
+
value
|
|
160
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
|
161
|
+
inner_type = Regexp.last_match[:inner_type]
|
|
162
|
+
value.map { |v| _deserialize(inner_type, v) }
|
|
163
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
164
|
+
k_type = Regexp.last_match[:k_type]
|
|
165
|
+
v_type = Regexp.last_match[:v_type]
|
|
166
|
+
{}.tap do |hash|
|
|
167
|
+
value.each do |k, v|
|
|
168
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
169
|
+
end
|
|
170
|
+
end
|
|
171
|
+
else # model
|
|
172
|
+
# models (e.g. Pet) or oneOf
|
|
173
|
+
klass = SeatsChart.const_get(type)
|
|
174
|
+
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
|
175
|
+
end
|
|
176
|
+
end
|
|
177
|
+
|
|
178
|
+
# Returns the string representation of the object
|
|
179
|
+
# @return [String] String presentation of the object
|
|
180
|
+
def to_s
|
|
181
|
+
to_hash.to_s
|
|
182
|
+
end
|
|
183
|
+
|
|
184
|
+
# to_body is an alias to to_hash (backward compatibility)
|
|
185
|
+
# @return [Hash] Returns the object in the form of hash
|
|
186
|
+
def to_body
|
|
187
|
+
to_hash
|
|
188
|
+
end
|
|
189
|
+
|
|
190
|
+
# Returns the object in the form of hash
|
|
191
|
+
# @return [Hash] Returns the object in the form of hash
|
|
192
|
+
def to_hash
|
|
193
|
+
hash = {}
|
|
194
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
195
|
+
value = self.send(attr)
|
|
196
|
+
if value.nil?
|
|
197
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
198
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
199
|
+
end
|
|
200
|
+
|
|
201
|
+
hash[param] = _to_hash(value)
|
|
202
|
+
end
|
|
203
|
+
hash
|
|
204
|
+
end
|
|
205
|
+
|
|
206
|
+
# Outputs non-array value in the form of hash
|
|
207
|
+
# For object, use to_hash. Otherwise, just return the value
|
|
208
|
+
# @param [Object] value Any valid value
|
|
209
|
+
# @return [Hash] Returns the value in the form of hash
|
|
210
|
+
def _to_hash(value)
|
|
211
|
+
if value.is_a?(Array)
|
|
212
|
+
value.compact.map { |v| _to_hash(v) }
|
|
213
|
+
elsif value.is_a?(Hash)
|
|
214
|
+
{}.tap do |hash|
|
|
215
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
216
|
+
end
|
|
217
|
+
elsif value.respond_to? :to_hash
|
|
218
|
+
value.to_hash
|
|
219
|
+
else
|
|
220
|
+
value
|
|
221
|
+
end
|
|
222
|
+
end
|
|
223
|
+
|
|
224
|
+
end
|
|
225
|
+
|
|
226
|
+
end
|