connectwise-ruby-sdk 1.0.1 → 1.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +13 -18
- data/connectwise-ruby-sdk.gemspec +2 -1
- data/lib/connectwise-ruby-sdk/api/documents_api.rb +8 -8
- data/lib/connectwise-ruby-sdk/api_client.rb +1 -1
- data/lib/connectwise-ruby-sdk/models/activity.rb +27 -15
- data/lib/connectwise-ruby-sdk/models/activity_status.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/activity_type.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/addition.rb +16 -12
- data/lib/connectwise-ruby-sdk/models/adjustment.rb +8 -6
- data/lib/connectwise-ruby-sdk/models/agreement.rb +43 -27
- data/lib/connectwise-ruby-sdk/models/agreement_type.rb +27 -15
- data/lib/connectwise-ruby-sdk/models/audit_trail_entry_insert_request.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/batch.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/board.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/callback_entry.rb +8 -6
- data/lib/connectwise-ruby-sdk/models/campaign.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/campaign_audit.rb +46 -20
- data/lib/connectwise-ruby-sdk/models/campaign_status.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/campaign_sub_type.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/campaign_type.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/catalog_item.rb +57 -27
- data/lib/connectwise-ruby-sdk/models/category.rb +27 -15
- data/lib/connectwise-ruby-sdk/models/code.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/company.rb +185 -123
- data/lib/connectwise-ruby-sdk/models/company_management_summary.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/company_site.rb +67 -45
- data/lib/connectwise-ruby-sdk/models/company_status.rb +19 -9
- data/lib/connectwise-ruby-sdk/models/company_type.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/configuration.rb +131 -93
- data/lib/connectwise-ruby-sdk/models/configuration_status.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/configuration_type.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/configuration_type_question.rb +24 -10
- data/lib/connectwise-ruby-sdk/models/connect_wise_hosted_setup.rb +30 -12
- data/lib/connectwise-ruby-sdk/models/contact.rb +128 -88
- data/lib/connectwise-ruby-sdk/models/contact_communication.rb +19 -9
- data/lib/connectwise-ruby-sdk/models/contact_communication_item.rb +19 -9
- data/lib/connectwise-ruby-sdk/models/contact_department.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/contact_relationship.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/contact_type.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/currency.rb +35 -21
- data/lib/connectwise-ruby-sdk/models/expense_type.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/forecast.rb +8 -6
- data/lib/connectwise-ruby-sdk/models/form_submitted.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/group.rb +8 -6
- data/lib/connectwise-ruby-sdk/models/integrator_login.rb +118 -78
- data/lib/connectwise-ruby-sdk/models/invoice.rb +32 -24
- data/lib/connectwise-ruby-sdk/models/item.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/link.rb +19 -9
- data/lib/connectwise-ruby-sdk/models/link_clicked.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/location.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/manufacturer.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/marketing_contact.rb +8 -6
- data/lib/connectwise-ruby-sdk/models/member.rb +129 -81
- data/lib/connectwise-ruby-sdk/models/menu_entry.rb +30 -12
- data/lib/connectwise-ruby-sdk/models/opportunity.rb +27 -15
- data/lib/connectwise-ruby-sdk/models/opportunity_rating.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/opportunity_status.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/opportunity_type.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/order.rb +8 -6
- data/lib/connectwise-ruby-sdk/models/order_status.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/pricing_schedule.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/priority.rb +22 -6
- data/lib/connectwise-ruby-sdk/models/product_item.rb +40 -30
- data/lib/connectwise-ruby-sdk/models/product_type.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/project.rb +27 -15
- data/lib/connectwise-ruby-sdk/models/project_phase.rb +19 -9
- data/lib/connectwise-ruby-sdk/models/purchase_order.rb +32 -24
- data/lib/connectwise-ruby-sdk/models/purchase_order_line_item.rb +59 -39
- data/lib/connectwise-ruby-sdk/models/schedule_entry.rb +8 -6
- data/lib/connectwise-ruby-sdk/models/schedule_status.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/schedule_type.rb +22 -6
- data/lib/connectwise-ruby-sdk/models/shipment_method.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/source.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/status.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/sub_category.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/sub_type.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/survey.rb +35 -21
- data/lib/connectwise-ruby-sdk/models/survey_question.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/survey_question_option.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/task.rb +13 -7
- data/lib/connectwise-ruby-sdk/models/team.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/ticket.rb +115 -81
- data/lib/connectwise-ruby-sdk/models/type.rb +11 -3
- data/lib/connectwise-ruby-sdk/models/unit_of_measure.rb +19 -9
- data/lib/connectwise-ruby-sdk/models/user_defined_field.rb +52 -22
- data/lib/connectwise-ruby-sdk/models/user_defined_field_option.rb +11 -3
- data/lib/connectwise-ruby-sdk/version.rb +1 -1
- data/spec/api_client_spec.rb +3 -2
- data/spec/configuration_spec.rb +1 -0
- data/spec/spec_helper.rb +1 -0
- metadata +2 -3
- data/git_push.sh +0 -67
@@ -356,6 +356,14 @@ module Connectwise
|
|
356
356
|
# @return Array for valid properies with the reasons
|
357
357
|
def list_invalid_properties
|
358
358
|
invalid_properties = Array.new
|
359
|
+
if @group_identifier.nil?
|
360
|
+
invalid_properties.push("invalid value for 'group_identifier', group_identifier cannot be nil.")
|
361
|
+
end
|
362
|
+
|
363
|
+
if @group_identifier.to_s.length > 100
|
364
|
+
invalid_properties.push("invalid value for 'group_identifier', the character length must be smaller than or equal to 100.")
|
365
|
+
end
|
366
|
+
|
359
367
|
return invalid_properties
|
360
368
|
end
|
361
369
|
|
@@ -363,7 +371,7 @@ module Connectwise
|
|
363
371
|
# @return true if the model is valid
|
364
372
|
def valid?
|
365
373
|
return false if @group_identifier.nil?
|
366
|
-
return false if @group_identifier.to_s.length
|
374
|
+
return false if @group_identifier.to_s.length > 100
|
367
375
|
device_type_validator = EnumAttributeValidator.new('String', ["WorkstationsAndServers", "BackupStats", "Servers", "Workstations"])
|
368
376
|
return false unless device_type_validator.valid?(@device_type)
|
369
377
|
return true
|
@@ -376,8 +384,8 @@ module Connectwise
|
|
376
384
|
fail ArgumentError, "group_identifier cannot be nil"
|
377
385
|
end
|
378
386
|
|
379
|
-
if group_identifier.to_s.length
|
380
|
-
fail ArgumentError, "invalid value for 'group_identifier', the character length must be
|
387
|
+
if group_identifier.to_s.length > 100
|
388
|
+
fail ArgumentError, "invalid value for 'group_identifier', the character length must be smaller than or equal to 100."
|
381
389
|
end
|
382
390
|
|
383
391
|
@group_identifier = group_identifier
|
@@ -214,6 +214,49 @@ module Connectwise
|
|
214
214
|
# @return Array for valid properies with the reasons
|
215
215
|
def list_invalid_properties
|
216
216
|
invalid_properties = Array.new
|
217
|
+
if @name.nil?
|
218
|
+
invalid_properties.push("invalid value for 'name', name cannot be nil.")
|
219
|
+
end
|
220
|
+
|
221
|
+
if @name.to_s.length > 50
|
222
|
+
invalid_properties.push("invalid value for 'name', the character length must be smaller than or equal to 50.")
|
223
|
+
end
|
224
|
+
|
225
|
+
|
226
|
+
if !@address_line1.nil? && @address_line1.to_s.length > 50
|
227
|
+
invalid_properties.push("invalid value for 'address_line1', the character length must be smaller than or equal to 50.")
|
228
|
+
end
|
229
|
+
|
230
|
+
|
231
|
+
if !@address_line2.nil? && @address_line2.to_s.length > 50
|
232
|
+
invalid_properties.push("invalid value for 'address_line2', the character length must be smaller than or equal to 50.")
|
233
|
+
end
|
234
|
+
|
235
|
+
|
236
|
+
if !@city.nil? && @city.to_s.length > 50
|
237
|
+
invalid_properties.push("invalid value for 'city', the character length must be smaller than or equal to 50.")
|
238
|
+
end
|
239
|
+
|
240
|
+
|
241
|
+
if !@state.nil? && @state.to_s.length > 50
|
242
|
+
invalid_properties.push("invalid value for 'state', the character length must be smaller than or equal to 50.")
|
243
|
+
end
|
244
|
+
|
245
|
+
|
246
|
+
if !@zip.nil? && @zip.to_s.length > 12
|
247
|
+
invalid_properties.push("invalid value for 'zip', the character length must be smaller than or equal to 12.")
|
248
|
+
end
|
249
|
+
|
250
|
+
|
251
|
+
if !@phone_number.nil? && @phone_number.to_s.length > 30
|
252
|
+
invalid_properties.push("invalid value for 'phone_number', the character length must be smaller than or equal to 30.")
|
253
|
+
end
|
254
|
+
|
255
|
+
|
256
|
+
if !@fax_number.nil? && @fax_number.to_s.length > 30
|
257
|
+
invalid_properties.push("invalid value for 'fax_number', the character length must be smaller than or equal to 30.")
|
258
|
+
end
|
259
|
+
|
217
260
|
return invalid_properties
|
218
261
|
end
|
219
262
|
|
@@ -221,14 +264,14 @@ module Connectwise
|
|
221
264
|
# @return true if the model is valid
|
222
265
|
def valid?
|
223
266
|
return false if @name.nil?
|
224
|
-
return false if @name.to_s.length
|
225
|
-
return false if @address_line1.to_s.length
|
226
|
-
return false if @address_line2.to_s.length
|
227
|
-
return false if @city.to_s.length
|
228
|
-
return false if @state.to_s.length
|
229
|
-
return false if @zip.to_s.length
|
230
|
-
return false if @phone_number.to_s.length
|
231
|
-
return false if @fax_number.to_s.length
|
267
|
+
return false if @name.to_s.length > 50
|
268
|
+
return false if !@address_line1.nil? && @address_line1.to_s.length > 50
|
269
|
+
return false if !@address_line2.nil? && @address_line2.to_s.length > 50
|
270
|
+
return false if !@city.nil? && @city.to_s.length > 50
|
271
|
+
return false if !@state.nil? && @state.to_s.length > 50
|
272
|
+
return false if !@zip.nil? && @zip.to_s.length > 12
|
273
|
+
return false if !@phone_number.nil? && @phone_number.to_s.length > 30
|
274
|
+
return false if !@fax_number.nil? && @fax_number.to_s.length > 30
|
232
275
|
return true
|
233
276
|
end
|
234
277
|
|
@@ -239,8 +282,8 @@ module Connectwise
|
|
239
282
|
fail ArgumentError, "name cannot be nil"
|
240
283
|
end
|
241
284
|
|
242
|
-
if name.to_s.length
|
243
|
-
fail ArgumentError, "invalid value for 'name', the character length must be
|
285
|
+
if name.to_s.length > 50
|
286
|
+
fail ArgumentError, "invalid value for 'name', the character length must be smaller than or equal to 50."
|
244
287
|
end
|
245
288
|
|
246
289
|
@name = name
|
@@ -249,12 +292,9 @@ module Connectwise
|
|
249
292
|
# Custom attribute writer method with validation
|
250
293
|
# @param [Object] address_line1 Value to be assigned
|
251
294
|
def address_line1=(address_line1)
|
252
|
-
if address_line1.nil?
|
253
|
-
fail ArgumentError, "address_line1 cannot be nil"
|
254
|
-
end
|
255
295
|
|
256
|
-
if address_line1.to_s.length
|
257
|
-
fail ArgumentError, "invalid value for 'address_line1', the character length must be
|
296
|
+
if !address_line1.nil? && address_line1.to_s.length > 50
|
297
|
+
fail ArgumentError, "invalid value for 'address_line1', the character length must be smaller than or equal to 50."
|
258
298
|
end
|
259
299
|
|
260
300
|
@address_line1 = address_line1
|
@@ -263,12 +303,9 @@ module Connectwise
|
|
263
303
|
# Custom attribute writer method with validation
|
264
304
|
# @param [Object] address_line2 Value to be assigned
|
265
305
|
def address_line2=(address_line2)
|
266
|
-
if address_line2.nil?
|
267
|
-
fail ArgumentError, "address_line2 cannot be nil"
|
268
|
-
end
|
269
306
|
|
270
|
-
if address_line2.to_s.length
|
271
|
-
fail ArgumentError, "invalid value for 'address_line2', the character length must be
|
307
|
+
if !address_line2.nil? && address_line2.to_s.length > 50
|
308
|
+
fail ArgumentError, "invalid value for 'address_line2', the character length must be smaller than or equal to 50."
|
272
309
|
end
|
273
310
|
|
274
311
|
@address_line2 = address_line2
|
@@ -277,12 +314,9 @@ module Connectwise
|
|
277
314
|
# Custom attribute writer method with validation
|
278
315
|
# @param [Object] city Value to be assigned
|
279
316
|
def city=(city)
|
280
|
-
if city.nil?
|
281
|
-
fail ArgumentError, "city cannot be nil"
|
282
|
-
end
|
283
317
|
|
284
|
-
if city.to_s.length
|
285
|
-
fail ArgumentError, "invalid value for 'city', the character length must be
|
318
|
+
if !city.nil? && city.to_s.length > 50
|
319
|
+
fail ArgumentError, "invalid value for 'city', the character length must be smaller than or equal to 50."
|
286
320
|
end
|
287
321
|
|
288
322
|
@city = city
|
@@ -291,12 +325,9 @@ module Connectwise
|
|
291
325
|
# Custom attribute writer method with validation
|
292
326
|
# @param [Object] state Value to be assigned
|
293
327
|
def state=(state)
|
294
|
-
if state.nil?
|
295
|
-
fail ArgumentError, "state cannot be nil"
|
296
|
-
end
|
297
328
|
|
298
|
-
if state.to_s.length
|
299
|
-
fail ArgumentError, "invalid value for 'state', the character length must be
|
329
|
+
if !state.nil? && state.to_s.length > 50
|
330
|
+
fail ArgumentError, "invalid value for 'state', the character length must be smaller than or equal to 50."
|
300
331
|
end
|
301
332
|
|
302
333
|
@state = state
|
@@ -305,12 +336,9 @@ module Connectwise
|
|
305
336
|
# Custom attribute writer method with validation
|
306
337
|
# @param [Object] zip Value to be assigned
|
307
338
|
def zip=(zip)
|
308
|
-
if zip.nil?
|
309
|
-
fail ArgumentError, "zip cannot be nil"
|
310
|
-
end
|
311
339
|
|
312
|
-
if zip.to_s.length
|
313
|
-
fail ArgumentError, "invalid value for 'zip', the character length must be
|
340
|
+
if !zip.nil? && zip.to_s.length > 12
|
341
|
+
fail ArgumentError, "invalid value for 'zip', the character length must be smaller than or equal to 12."
|
314
342
|
end
|
315
343
|
|
316
344
|
@zip = zip
|
@@ -319,12 +347,9 @@ module Connectwise
|
|
319
347
|
# Custom attribute writer method with validation
|
320
348
|
# @param [Object] phone_number Value to be assigned
|
321
349
|
def phone_number=(phone_number)
|
322
|
-
if phone_number.nil?
|
323
|
-
fail ArgumentError, "phone_number cannot be nil"
|
324
|
-
end
|
325
350
|
|
326
|
-
if phone_number.to_s.length
|
327
|
-
fail ArgumentError, "invalid value for 'phone_number', the character length must be
|
351
|
+
if !phone_number.nil? && phone_number.to_s.length > 30
|
352
|
+
fail ArgumentError, "invalid value for 'phone_number', the character length must be smaller than or equal to 30."
|
328
353
|
end
|
329
354
|
|
330
355
|
@phone_number = phone_number
|
@@ -333,12 +358,9 @@ module Connectwise
|
|
333
358
|
# Custom attribute writer method with validation
|
334
359
|
# @param [Object] fax_number Value to be assigned
|
335
360
|
def fax_number=(fax_number)
|
336
|
-
if fax_number.nil?
|
337
|
-
fail ArgumentError, "fax_number cannot be nil"
|
338
|
-
end
|
339
361
|
|
340
|
-
if fax_number.to_s.length
|
341
|
-
fail ArgumentError, "invalid value for 'fax_number', the character length must be
|
362
|
+
if !fax_number.nil? && fax_number.to_s.length > 30
|
363
|
+
fail ArgumentError, "invalid value for 'fax_number', the character length must be smaller than or equal to 30."
|
342
364
|
end
|
343
365
|
|
344
366
|
@fax_number = fax_number
|
@@ -142,6 +142,19 @@ module Connectwise
|
|
142
142
|
# @return Array for valid properies with the reasons
|
143
143
|
def list_invalid_properties
|
144
144
|
invalid_properties = Array.new
|
145
|
+
if @name.nil?
|
146
|
+
invalid_properties.push("invalid value for 'name', name cannot be nil.")
|
147
|
+
end
|
148
|
+
|
149
|
+
if @name.to_s.length > 50
|
150
|
+
invalid_properties.push("invalid value for 'name', the character length must be smaller than or equal to 50.")
|
151
|
+
end
|
152
|
+
|
153
|
+
|
154
|
+
if !@notification_message.nil? && @notification_message.to_s.length > 500
|
155
|
+
invalid_properties.push("invalid value for 'notification_message', the character length must be smaller than or equal to 500.")
|
156
|
+
end
|
157
|
+
|
145
158
|
return invalid_properties
|
146
159
|
end
|
147
160
|
|
@@ -149,8 +162,8 @@ module Connectwise
|
|
149
162
|
# @return true if the model is valid
|
150
163
|
def valid?
|
151
164
|
return false if @name.nil?
|
152
|
-
return false if @name.to_s.length
|
153
|
-
return false if @notification_message.to_s.length
|
165
|
+
return false if @name.to_s.length > 50
|
166
|
+
return false if !@notification_message.nil? && @notification_message.to_s.length > 500
|
154
167
|
return true
|
155
168
|
end
|
156
169
|
|
@@ -161,8 +174,8 @@ module Connectwise
|
|
161
174
|
fail ArgumentError, "name cannot be nil"
|
162
175
|
end
|
163
176
|
|
164
|
-
if name.to_s.length
|
165
|
-
fail ArgumentError, "invalid value for 'name', the character length must be
|
177
|
+
if name.to_s.length > 50
|
178
|
+
fail ArgumentError, "invalid value for 'name', the character length must be smaller than or equal to 50."
|
166
179
|
end
|
167
180
|
|
168
181
|
@name = name
|
@@ -171,12 +184,9 @@ module Connectwise
|
|
171
184
|
# Custom attribute writer method with validation
|
172
185
|
# @param [Object] notification_message Value to be assigned
|
173
186
|
def notification_message=(notification_message)
|
174
|
-
if notification_message.nil?
|
175
|
-
fail ArgumentError, "notification_message cannot be nil"
|
176
|
-
end
|
177
187
|
|
178
|
-
if notification_message.to_s.length
|
179
|
-
fail ArgumentError, "invalid value for 'notification_message', the character length must be
|
188
|
+
if !notification_message.nil? && notification_message.to_s.length > 500
|
189
|
+
fail ArgumentError, "invalid value for 'notification_message', the character length must be smaller than or equal to 500."
|
180
190
|
end
|
181
191
|
|
182
192
|
@notification_message = notification_message
|
@@ -94,6 +94,14 @@ module Connectwise
|
|
94
94
|
# @return Array for valid properies with the reasons
|
95
95
|
def list_invalid_properties
|
96
96
|
invalid_properties = Array.new
|
97
|
+
if @name.nil?
|
98
|
+
invalid_properties.push("invalid value for 'name', name cannot be nil.")
|
99
|
+
end
|
100
|
+
|
101
|
+
if @name.to_s.length > 50
|
102
|
+
invalid_properties.push("invalid value for 'name', the character length must be smaller than or equal to 50.")
|
103
|
+
end
|
104
|
+
|
97
105
|
return invalid_properties
|
98
106
|
end
|
99
107
|
|
@@ -101,7 +109,7 @@ module Connectwise
|
|
101
109
|
# @return true if the model is valid
|
102
110
|
def valid?
|
103
111
|
return false if @name.nil?
|
104
|
-
return false if @name.to_s.length
|
112
|
+
return false if @name.to_s.length > 50
|
105
113
|
return true
|
106
114
|
end
|
107
115
|
|
@@ -112,8 +120,8 @@ module Connectwise
|
|
112
120
|
fail ArgumentError, "name cannot be nil"
|
113
121
|
end
|
114
122
|
|
115
|
-
if name.to_s.length
|
116
|
-
fail ArgumentError, "invalid value for 'name', the character length must be
|
123
|
+
if name.to_s.length > 50
|
124
|
+
fail ArgumentError, "invalid value for 'name', the character length must be smaller than or equal to 50."
|
117
125
|
end
|
118
126
|
|
119
127
|
@name = name
|
@@ -458,6 +458,89 @@ module Connectwise
|
|
458
458
|
# @return Array for valid properies with the reasons
|
459
459
|
def list_invalid_properties
|
460
460
|
invalid_properties = Array.new
|
461
|
+
if @name.nil?
|
462
|
+
invalid_properties.push("invalid value for 'name', name cannot be nil.")
|
463
|
+
end
|
464
|
+
|
465
|
+
if @name.to_s.length > 100
|
466
|
+
invalid_properties.push("invalid value for 'name', the character length must be smaller than or equal to 100.")
|
467
|
+
end
|
468
|
+
|
469
|
+
|
470
|
+
if !@device_identifier.nil? && @device_identifier.to_s.length > 100
|
471
|
+
invalid_properties.push("invalid value for 'device_identifier', the character length must be smaller than or equal to 100.")
|
472
|
+
end
|
473
|
+
|
474
|
+
|
475
|
+
if !@serial_number.nil? && @serial_number.to_s.length > 250
|
476
|
+
invalid_properties.push("invalid value for 'serial_number', the character length must be smaller than or equal to 250.")
|
477
|
+
end
|
478
|
+
|
479
|
+
|
480
|
+
if !@model_number.nil? && @model_number.to_s.length > 50
|
481
|
+
invalid_properties.push("invalid value for 'model_number', the character length must be smaller than or equal to 50.")
|
482
|
+
end
|
483
|
+
|
484
|
+
|
485
|
+
if !@tag_number.nil? && @tag_number.to_s.length > 50
|
486
|
+
invalid_properties.push("invalid value for 'tag_number', the character length must be smaller than or equal to 50.")
|
487
|
+
end
|
488
|
+
|
489
|
+
|
490
|
+
if !@mac_address.nil? && @mac_address.to_s.length > 25
|
491
|
+
invalid_properties.push("invalid value for 'mac_address', the character length must be smaller than or equal to 25.")
|
492
|
+
end
|
493
|
+
|
494
|
+
|
495
|
+
if !@last_login_name.nil? && @last_login_name.to_s.length > 100
|
496
|
+
invalid_properties.push("invalid value for 'last_login_name', the character length must be smaller than or equal to 100.")
|
497
|
+
end
|
498
|
+
|
499
|
+
|
500
|
+
if !@backup_server_name.nil? && @backup_server_name.to_s.length > 50
|
501
|
+
invalid_properties.push("invalid value for 'backup_server_name', the character length must be smaller than or equal to 50.")
|
502
|
+
end
|
503
|
+
|
504
|
+
|
505
|
+
if !@ip_address.nil? && @ip_address.to_s.length > 50
|
506
|
+
invalid_properties.push("invalid value for 'ip_address', the character length must be smaller than or equal to 50.")
|
507
|
+
end
|
508
|
+
|
509
|
+
|
510
|
+
if !@default_gateway.nil? && @default_gateway.to_s.length > 50
|
511
|
+
invalid_properties.push("invalid value for 'default_gateway', the character length must be smaller than or equal to 50.")
|
512
|
+
end
|
513
|
+
|
514
|
+
|
515
|
+
if !@os_type.nil? && @os_type.to_s.length > 250
|
516
|
+
invalid_properties.push("invalid value for 'os_type', the character length must be smaller than or equal to 250.")
|
517
|
+
end
|
518
|
+
|
519
|
+
|
520
|
+
if !@os_info.nil? && @os_info.to_s.length > 250
|
521
|
+
invalid_properties.push("invalid value for 'os_info', the character length must be smaller than or equal to 250.")
|
522
|
+
end
|
523
|
+
|
524
|
+
|
525
|
+
if !@cpu_speed.nil? && @cpu_speed.to_s.length > 100
|
526
|
+
invalid_properties.push("invalid value for 'cpu_speed', the character length must be smaller than or equal to 100.")
|
527
|
+
end
|
528
|
+
|
529
|
+
|
530
|
+
if !@ram.nil? && @ram.to_s.length > 25
|
531
|
+
invalid_properties.push("invalid value for 'ram', the character length must be smaller than or equal to 25.")
|
532
|
+
end
|
533
|
+
|
534
|
+
|
535
|
+
if !@management_link.nil? && @management_link.to_s.length > 200
|
536
|
+
invalid_properties.push("invalid value for 'management_link', the character length must be smaller than or equal to 200.")
|
537
|
+
end
|
538
|
+
|
539
|
+
|
540
|
+
if !@remote_link.nil? && @remote_link.to_s.length > 200
|
541
|
+
invalid_properties.push("invalid value for 'remote_link', the character length must be smaller than or equal to 200.")
|
542
|
+
end
|
543
|
+
|
461
544
|
return invalid_properties
|
462
545
|
end
|
463
546
|
|
@@ -465,24 +548,24 @@ module Connectwise
|
|
465
548
|
# @return true if the model is valid
|
466
549
|
def valid?
|
467
550
|
return false if @name.nil?
|
468
|
-
return false if @name.to_s.length
|
551
|
+
return false if @name.to_s.length > 100
|
469
552
|
return false if @type.nil?
|
470
553
|
return false if @company.nil?
|
471
|
-
return false if @device_identifier.to_s.length
|
472
|
-
return false if @serial_number.to_s.length
|
473
|
-
return false if @model_number.to_s.length
|
474
|
-
return false if @tag_number.to_s.length
|
475
|
-
return false if @mac_address.to_s.length
|
476
|
-
return false if @last_login_name.to_s.length
|
477
|
-
return false if @backup_server_name.to_s.length
|
478
|
-
return false if @ip_address.to_s.length
|
479
|
-
return false if @default_gateway.to_s.length
|
480
|
-
return false if @os_type.to_s.length
|
481
|
-
return false if @os_info.to_s.length
|
482
|
-
return false if @cpu_speed.to_s.length
|
483
|
-
return false if @ram.to_s.length
|
484
|
-
return false if @management_link.to_s.length
|
485
|
-
return false if @remote_link.to_s.length
|
554
|
+
return false if !@device_identifier.nil? && @device_identifier.to_s.length > 100
|
555
|
+
return false if !@serial_number.nil? && @serial_number.to_s.length > 250
|
556
|
+
return false if !@model_number.nil? && @model_number.to_s.length > 50
|
557
|
+
return false if !@tag_number.nil? && @tag_number.to_s.length > 50
|
558
|
+
return false if !@mac_address.nil? && @mac_address.to_s.length > 25
|
559
|
+
return false if !@last_login_name.nil? && @last_login_name.to_s.length > 100
|
560
|
+
return false if !@backup_server_name.nil? && @backup_server_name.to_s.length > 50
|
561
|
+
return false if !@ip_address.nil? && @ip_address.to_s.length > 50
|
562
|
+
return false if !@default_gateway.nil? && @default_gateway.to_s.length > 50
|
563
|
+
return false if !@os_type.nil? && @os_type.to_s.length > 250
|
564
|
+
return false if !@os_info.nil? && @os_info.to_s.length > 250
|
565
|
+
return false if !@cpu_speed.nil? && @cpu_speed.to_s.length > 100
|
566
|
+
return false if !@ram.nil? && @ram.to_s.length > 25
|
567
|
+
return false if !@management_link.nil? && @management_link.to_s.length > 200
|
568
|
+
return false if !@remote_link.nil? && @remote_link.to_s.length > 200
|
486
569
|
return true
|
487
570
|
end
|
488
571
|
|
@@ -493,8 +576,8 @@ module Connectwise
|
|
493
576
|
fail ArgumentError, "name cannot be nil"
|
494
577
|
end
|
495
578
|
|
496
|
-
if name.to_s.length
|
497
|
-
fail ArgumentError, "invalid value for 'name', the character length must be
|
579
|
+
if name.to_s.length > 100
|
580
|
+
fail ArgumentError, "invalid value for 'name', the character length must be smaller than or equal to 100."
|
498
581
|
end
|
499
582
|
|
500
583
|
@name = name
|
@@ -503,12 +586,9 @@ module Connectwise
|
|
503
586
|
# Custom attribute writer method with validation
|
504
587
|
# @param [Object] device_identifier Value to be assigned
|
505
588
|
def device_identifier=(device_identifier)
|
506
|
-
if device_identifier.nil?
|
507
|
-
fail ArgumentError, "device_identifier cannot be nil"
|
508
|
-
end
|
509
589
|
|
510
|
-
if device_identifier.to_s.length
|
511
|
-
fail ArgumentError, "invalid value for 'device_identifier', the character length must be
|
590
|
+
if !device_identifier.nil? && device_identifier.to_s.length > 100
|
591
|
+
fail ArgumentError, "invalid value for 'device_identifier', the character length must be smaller than or equal to 100."
|
512
592
|
end
|
513
593
|
|
514
594
|
@device_identifier = device_identifier
|
@@ -517,12 +597,9 @@ module Connectwise
|
|
517
597
|
# Custom attribute writer method with validation
|
518
598
|
# @param [Object] serial_number Value to be assigned
|
519
599
|
def serial_number=(serial_number)
|
520
|
-
if serial_number.nil?
|
521
|
-
fail ArgumentError, "serial_number cannot be nil"
|
522
|
-
end
|
523
600
|
|
524
|
-
if serial_number.to_s.length
|
525
|
-
fail ArgumentError, "invalid value for 'serial_number', the character length must be
|
601
|
+
if !serial_number.nil? && serial_number.to_s.length > 250
|
602
|
+
fail ArgumentError, "invalid value for 'serial_number', the character length must be smaller than or equal to 250."
|
526
603
|
end
|
527
604
|
|
528
605
|
@serial_number = serial_number
|
@@ -531,12 +608,9 @@ module Connectwise
|
|
531
608
|
# Custom attribute writer method with validation
|
532
609
|
# @param [Object] model_number Value to be assigned
|
533
610
|
def model_number=(model_number)
|
534
|
-
if model_number.nil?
|
535
|
-
fail ArgumentError, "model_number cannot be nil"
|
536
|
-
end
|
537
611
|
|
538
|
-
if model_number.to_s.length
|
539
|
-
fail ArgumentError, "invalid value for 'model_number', the character length must be
|
612
|
+
if !model_number.nil? && model_number.to_s.length > 50
|
613
|
+
fail ArgumentError, "invalid value for 'model_number', the character length must be smaller than or equal to 50."
|
540
614
|
end
|
541
615
|
|
542
616
|
@model_number = model_number
|
@@ -545,12 +619,9 @@ module Connectwise
|
|
545
619
|
# Custom attribute writer method with validation
|
546
620
|
# @param [Object] tag_number Value to be assigned
|
547
621
|
def tag_number=(tag_number)
|
548
|
-
if tag_number.nil?
|
549
|
-
fail ArgumentError, "tag_number cannot be nil"
|
550
|
-
end
|
551
622
|
|
552
|
-
if tag_number.to_s.length
|
553
|
-
fail ArgumentError, "invalid value for 'tag_number', the character length must be
|
623
|
+
if !tag_number.nil? && tag_number.to_s.length > 50
|
624
|
+
fail ArgumentError, "invalid value for 'tag_number', the character length must be smaller than or equal to 50."
|
554
625
|
end
|
555
626
|
|
556
627
|
@tag_number = tag_number
|
@@ -559,12 +630,9 @@ module Connectwise
|
|
559
630
|
# Custom attribute writer method with validation
|
560
631
|
# @param [Object] mac_address Value to be assigned
|
561
632
|
def mac_address=(mac_address)
|
562
|
-
if mac_address.nil?
|
563
|
-
fail ArgumentError, "mac_address cannot be nil"
|
564
|
-
end
|
565
633
|
|
566
|
-
if mac_address.to_s.length
|
567
|
-
fail ArgumentError, "invalid value for 'mac_address', the character length must be
|
634
|
+
if !mac_address.nil? && mac_address.to_s.length > 25
|
635
|
+
fail ArgumentError, "invalid value for 'mac_address', the character length must be smaller than or equal to 25."
|
568
636
|
end
|
569
637
|
|
570
638
|
@mac_address = mac_address
|
@@ -573,12 +641,9 @@ module Connectwise
|
|
573
641
|
# Custom attribute writer method with validation
|
574
642
|
# @param [Object] last_login_name Value to be assigned
|
575
643
|
def last_login_name=(last_login_name)
|
576
|
-
if last_login_name.nil?
|
577
|
-
fail ArgumentError, "last_login_name cannot be nil"
|
578
|
-
end
|
579
644
|
|
580
|
-
if last_login_name.to_s.length
|
581
|
-
fail ArgumentError, "invalid value for 'last_login_name', the character length must be
|
645
|
+
if !last_login_name.nil? && last_login_name.to_s.length > 100
|
646
|
+
fail ArgumentError, "invalid value for 'last_login_name', the character length must be smaller than or equal to 100."
|
582
647
|
end
|
583
648
|
|
584
649
|
@last_login_name = last_login_name
|
@@ -587,12 +652,9 @@ module Connectwise
|
|
587
652
|
# Custom attribute writer method with validation
|
588
653
|
# @param [Object] backup_server_name Value to be assigned
|
589
654
|
def backup_server_name=(backup_server_name)
|
590
|
-
if backup_server_name.nil?
|
591
|
-
fail ArgumentError, "backup_server_name cannot be nil"
|
592
|
-
end
|
593
655
|
|
594
|
-
if backup_server_name.to_s.length
|
595
|
-
fail ArgumentError, "invalid value for 'backup_server_name', the character length must be
|
656
|
+
if !backup_server_name.nil? && backup_server_name.to_s.length > 50
|
657
|
+
fail ArgumentError, "invalid value for 'backup_server_name', the character length must be smaller than or equal to 50."
|
596
658
|
end
|
597
659
|
|
598
660
|
@backup_server_name = backup_server_name
|
@@ -601,12 +663,9 @@ module Connectwise
|
|
601
663
|
# Custom attribute writer method with validation
|
602
664
|
# @param [Object] ip_address Value to be assigned
|
603
665
|
def ip_address=(ip_address)
|
604
|
-
if ip_address.nil?
|
605
|
-
fail ArgumentError, "ip_address cannot be nil"
|
606
|
-
end
|
607
666
|
|
608
|
-
if ip_address.to_s.length
|
609
|
-
fail ArgumentError, "invalid value for 'ip_address', the character length must be
|
667
|
+
if !ip_address.nil? && ip_address.to_s.length > 50
|
668
|
+
fail ArgumentError, "invalid value for 'ip_address', the character length must be smaller than or equal to 50."
|
610
669
|
end
|
611
670
|
|
612
671
|
@ip_address = ip_address
|
@@ -615,12 +674,9 @@ module Connectwise
|
|
615
674
|
# Custom attribute writer method with validation
|
616
675
|
# @param [Object] default_gateway Value to be assigned
|
617
676
|
def default_gateway=(default_gateway)
|
618
|
-
if default_gateway.nil?
|
619
|
-
fail ArgumentError, "default_gateway cannot be nil"
|
620
|
-
end
|
621
677
|
|
622
|
-
if default_gateway.to_s.length
|
623
|
-
fail ArgumentError, "invalid value for 'default_gateway', the character length must be
|
678
|
+
if !default_gateway.nil? && default_gateway.to_s.length > 50
|
679
|
+
fail ArgumentError, "invalid value for 'default_gateway', the character length must be smaller than or equal to 50."
|
624
680
|
end
|
625
681
|
|
626
682
|
@default_gateway = default_gateway
|
@@ -629,12 +685,9 @@ module Connectwise
|
|
629
685
|
# Custom attribute writer method with validation
|
630
686
|
# @param [Object] os_type Value to be assigned
|
631
687
|
def os_type=(os_type)
|
632
|
-
if os_type.nil?
|
633
|
-
fail ArgumentError, "os_type cannot be nil"
|
634
|
-
end
|
635
688
|
|
636
|
-
if os_type.to_s.length
|
637
|
-
fail ArgumentError, "invalid value for 'os_type', the character length must be
|
689
|
+
if !os_type.nil? && os_type.to_s.length > 250
|
690
|
+
fail ArgumentError, "invalid value for 'os_type', the character length must be smaller than or equal to 250."
|
638
691
|
end
|
639
692
|
|
640
693
|
@os_type = os_type
|
@@ -643,12 +696,9 @@ module Connectwise
|
|
643
696
|
# Custom attribute writer method with validation
|
644
697
|
# @param [Object] os_info Value to be assigned
|
645
698
|
def os_info=(os_info)
|
646
|
-
if os_info.nil?
|
647
|
-
fail ArgumentError, "os_info cannot be nil"
|
648
|
-
end
|
649
699
|
|
650
|
-
if os_info.to_s.length
|
651
|
-
fail ArgumentError, "invalid value for 'os_info', the character length must be
|
700
|
+
if !os_info.nil? && os_info.to_s.length > 250
|
701
|
+
fail ArgumentError, "invalid value for 'os_info', the character length must be smaller than or equal to 250."
|
652
702
|
end
|
653
703
|
|
654
704
|
@os_info = os_info
|
@@ -657,12 +707,9 @@ module Connectwise
|
|
657
707
|
# Custom attribute writer method with validation
|
658
708
|
# @param [Object] cpu_speed Value to be assigned
|
659
709
|
def cpu_speed=(cpu_speed)
|
660
|
-
if cpu_speed.nil?
|
661
|
-
fail ArgumentError, "cpu_speed cannot be nil"
|
662
|
-
end
|
663
710
|
|
664
|
-
if cpu_speed.to_s.length
|
665
|
-
fail ArgumentError, "invalid value for 'cpu_speed', the character length must be
|
711
|
+
if !cpu_speed.nil? && cpu_speed.to_s.length > 100
|
712
|
+
fail ArgumentError, "invalid value for 'cpu_speed', the character length must be smaller than or equal to 100."
|
666
713
|
end
|
667
714
|
|
668
715
|
@cpu_speed = cpu_speed
|
@@ -671,12 +718,9 @@ module Connectwise
|
|
671
718
|
# Custom attribute writer method with validation
|
672
719
|
# @param [Object] ram Value to be assigned
|
673
720
|
def ram=(ram)
|
674
|
-
if ram.nil?
|
675
|
-
fail ArgumentError, "ram cannot be nil"
|
676
|
-
end
|
677
721
|
|
678
|
-
if ram.to_s.length
|
679
|
-
fail ArgumentError, "invalid value for 'ram', the character length must be
|
722
|
+
if !ram.nil? && ram.to_s.length > 25
|
723
|
+
fail ArgumentError, "invalid value for 'ram', the character length must be smaller than or equal to 25."
|
680
724
|
end
|
681
725
|
|
682
726
|
@ram = ram
|
@@ -685,12 +729,9 @@ module Connectwise
|
|
685
729
|
# Custom attribute writer method with validation
|
686
730
|
# @param [Object] management_link Value to be assigned
|
687
731
|
def management_link=(management_link)
|
688
|
-
if management_link.nil?
|
689
|
-
fail ArgumentError, "management_link cannot be nil"
|
690
|
-
end
|
691
732
|
|
692
|
-
if management_link.to_s.length
|
693
|
-
fail ArgumentError, "invalid value for 'management_link', the character length must be
|
733
|
+
if !management_link.nil? && management_link.to_s.length > 200
|
734
|
+
fail ArgumentError, "invalid value for 'management_link', the character length must be smaller than or equal to 200."
|
694
735
|
end
|
695
736
|
|
696
737
|
@management_link = management_link
|
@@ -699,12 +740,9 @@ module Connectwise
|
|
699
740
|
# Custom attribute writer method with validation
|
700
741
|
# @param [Object] remote_link Value to be assigned
|
701
742
|
def remote_link=(remote_link)
|
702
|
-
if remote_link.nil?
|
703
|
-
fail ArgumentError, "remote_link cannot be nil"
|
704
|
-
end
|
705
743
|
|
706
|
-
if remote_link.to_s.length
|
707
|
-
fail ArgumentError, "invalid value for 'remote_link', the character length must be
|
744
|
+
if !remote_link.nil? && remote_link.to_s.length > 200
|
745
|
+
fail ArgumentError, "invalid value for 'remote_link', the character length must be smaller than or equal to 200."
|
708
746
|
end
|
709
747
|
|
710
748
|
@remote_link = remote_link
|