connectwise-ruby-sdk 1.0.1 → 1.0.2
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 +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
|
@@ -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 @description.nil?
|
|
98
|
+
invalid_properties.push("invalid value for 'description', description cannot be nil.")
|
|
99
|
+
end
|
|
100
|
+
|
|
101
|
+
if @description.to_s.length > 50
|
|
102
|
+
invalid_properties.push("invalid value for 'description', 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 @description.nil?
|
|
104
|
-
return false if @description.to_s.length
|
|
112
|
+
return false if @description.to_s.length > 50
|
|
105
113
|
return true
|
|
106
114
|
end
|
|
107
115
|
|
|
@@ -112,8 +120,8 @@ module Connectwise
|
|
|
112
120
|
fail ArgumentError, "description cannot be nil"
|
|
113
121
|
end
|
|
114
122
|
|
|
115
|
-
if description.to_s.length
|
|
116
|
-
fail ArgumentError, "invalid value for 'description', the character length must be
|
|
123
|
+
if description.to_s.length > 50
|
|
124
|
+
fail ArgumentError, "invalid value for 'description', the character length must be smaller than or equal to 50."
|
|
117
125
|
end
|
|
118
126
|
|
|
119
127
|
@description = description
|
|
@@ -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
|
|
@@ -165,6 +165,23 @@ module Connectwise
|
|
|
165
165
|
# @return Array for valid properies with the reasons
|
|
166
166
|
def list_invalid_properties
|
|
167
167
|
invalid_properties = Array.new
|
|
168
|
+
if @question.nil?
|
|
169
|
+
invalid_properties.push("invalid value for 'question', question cannot be nil.")
|
|
170
|
+
end
|
|
171
|
+
|
|
172
|
+
if @question.to_s.length > 1000
|
|
173
|
+
invalid_properties.push("invalid value for 'question', the character length must be smaller than or equal to 1000.")
|
|
174
|
+
end
|
|
175
|
+
|
|
176
|
+
|
|
177
|
+
if !@number_of_decimals.nil? && @number_of_decimals > 5.0
|
|
178
|
+
invalid_properties.push("invalid value for 'number_of_decimals', must be smaller than or equal to 5.0.")
|
|
179
|
+
end
|
|
180
|
+
|
|
181
|
+
if !@number_of_decimals.nil? && @number_of_decimals < 0.0
|
|
182
|
+
invalid_properties.push("invalid value for 'number_of_decimals', must be greater than or equal to 0.0.")
|
|
183
|
+
end
|
|
184
|
+
|
|
168
185
|
return invalid_properties
|
|
169
186
|
end
|
|
170
187
|
|
|
@@ -178,9 +195,9 @@ module Connectwise
|
|
|
178
195
|
entry_type_validator = EnumAttributeValidator.new('String', ["EntryField", "List", "Option"])
|
|
179
196
|
return false unless entry_type_validator.valid?(@entry_type)
|
|
180
197
|
return false if @question.nil?
|
|
181
|
-
return false if @question.to_s.length
|
|
182
|
-
return false if @number_of_decimals > 5.0
|
|
183
|
-
return false if @number_of_decimals < 0.0
|
|
198
|
+
return false if @question.to_s.length > 1000
|
|
199
|
+
return false if !@number_of_decimals.nil? && @number_of_decimals > 5.0
|
|
200
|
+
return false if !@number_of_decimals.nil? && @number_of_decimals < 0.0
|
|
184
201
|
return true
|
|
185
202
|
end
|
|
186
203
|
|
|
@@ -211,8 +228,8 @@ module Connectwise
|
|
|
211
228
|
fail ArgumentError, "question cannot be nil"
|
|
212
229
|
end
|
|
213
230
|
|
|
214
|
-
if question.to_s.length
|
|
215
|
-
fail ArgumentError, "invalid value for 'question', the character length must be
|
|
231
|
+
if question.to_s.length > 1000
|
|
232
|
+
fail ArgumentError, "invalid value for 'question', the character length must be smaller than or equal to 1000."
|
|
216
233
|
end
|
|
217
234
|
|
|
218
235
|
@question = question
|
|
@@ -221,15 +238,12 @@ module Connectwise
|
|
|
221
238
|
# Custom attribute writer method with validation
|
|
222
239
|
# @param [Object] number_of_decimals Value to be assigned
|
|
223
240
|
def number_of_decimals=(number_of_decimals)
|
|
224
|
-
if number_of_decimals.nil?
|
|
225
|
-
fail ArgumentError, "number_of_decimals cannot be nil"
|
|
226
|
-
end
|
|
227
241
|
|
|
228
|
-
if number_of_decimals > 5.0
|
|
242
|
+
if !number_of_decimals.nil? && number_of_decimals > 5.0
|
|
229
243
|
fail ArgumentError, "invalid value for 'number_of_decimals', must be smaller than or equal to 5.0."
|
|
230
244
|
end
|
|
231
245
|
|
|
232
|
-
if number_of_decimals < 0.0
|
|
246
|
+
if !number_of_decimals.nil? && number_of_decimals < 0.0
|
|
233
247
|
fail ArgumentError, "invalid value for 'number_of_decimals', must be greater than or equal to 0.0."
|
|
234
248
|
end
|
|
235
249
|
|
|
@@ -164,6 +164,27 @@ module Connectwise
|
|
|
164
164
|
# @return Array for valid properies with the reasons
|
|
165
165
|
def list_invalid_properties
|
|
166
166
|
invalid_properties = Array.new
|
|
167
|
+
if @description.nil?
|
|
168
|
+
invalid_properties.push("invalid value for 'description', description cannot be nil.")
|
|
169
|
+
end
|
|
170
|
+
|
|
171
|
+
if @description.to_s.length > 255
|
|
172
|
+
invalid_properties.push("invalid value for 'description', the character length must be smaller than or equal to 255.")
|
|
173
|
+
end
|
|
174
|
+
|
|
175
|
+
|
|
176
|
+
if !@origin.nil? && @origin.to_s.length > 50
|
|
177
|
+
invalid_properties.push("invalid value for 'origin', the character length must be smaller than or equal to 50.")
|
|
178
|
+
end
|
|
179
|
+
|
|
180
|
+
if @url.nil?
|
|
181
|
+
invalid_properties.push("invalid value for 'url', url cannot be nil.")
|
|
182
|
+
end
|
|
183
|
+
|
|
184
|
+
if @url.to_s.length > 1024
|
|
185
|
+
invalid_properties.push("invalid value for 'url', the character length must be smaller than or equal to 1024.")
|
|
186
|
+
end
|
|
187
|
+
|
|
167
188
|
return invalid_properties
|
|
168
189
|
end
|
|
169
190
|
|
|
@@ -172,10 +193,10 @@ module Connectwise
|
|
|
172
193
|
def valid?
|
|
173
194
|
return false if @screen_id.nil?
|
|
174
195
|
return false if @description.nil?
|
|
175
|
-
return false if @description.to_s.length
|
|
176
|
-
return false if @origin.to_s.length
|
|
196
|
+
return false if @description.to_s.length > 255
|
|
197
|
+
return false if !@origin.nil? && @origin.to_s.length > 50
|
|
177
198
|
return false if @url.nil?
|
|
178
|
-
return false if @url.to_s.length
|
|
199
|
+
return false if @url.to_s.length > 1024
|
|
179
200
|
return false if @type.nil?
|
|
180
201
|
type_validator = EnumAttributeValidator.new('String', ["Tab", "Pod"])
|
|
181
202
|
return false unless type_validator.valid?(@type)
|
|
@@ -189,8 +210,8 @@ module Connectwise
|
|
|
189
210
|
fail ArgumentError, "description cannot be nil"
|
|
190
211
|
end
|
|
191
212
|
|
|
192
|
-
if description.to_s.length
|
|
193
|
-
fail ArgumentError, "invalid value for 'description', the character length must be
|
|
213
|
+
if description.to_s.length > 255
|
|
214
|
+
fail ArgumentError, "invalid value for 'description', the character length must be smaller than or equal to 255."
|
|
194
215
|
end
|
|
195
216
|
|
|
196
217
|
@description = description
|
|
@@ -199,12 +220,9 @@ module Connectwise
|
|
|
199
220
|
# Custom attribute writer method with validation
|
|
200
221
|
# @param [Object] origin Value to be assigned
|
|
201
222
|
def origin=(origin)
|
|
202
|
-
if origin.nil?
|
|
203
|
-
fail ArgumentError, "origin cannot be nil"
|
|
204
|
-
end
|
|
205
223
|
|
|
206
|
-
if origin.to_s.length
|
|
207
|
-
fail ArgumentError, "invalid value for 'origin', the character length must be
|
|
224
|
+
if !origin.nil? && origin.to_s.length > 50
|
|
225
|
+
fail ArgumentError, "invalid value for 'origin', the character length must be smaller than or equal to 50."
|
|
208
226
|
end
|
|
209
227
|
|
|
210
228
|
@origin = origin
|
|
@@ -217,8 +235,8 @@ module Connectwise
|
|
|
217
235
|
fail ArgumentError, "url cannot be nil"
|
|
218
236
|
end
|
|
219
237
|
|
|
220
|
-
if url.to_s.length
|
|
221
|
-
fail ArgumentError, "invalid value for 'url', the character length must be
|
|
238
|
+
if url.to_s.length > 1024
|
|
239
|
+
fail ArgumentError, "invalid value for 'url', the character length must be smaller than or equal to 1024."
|
|
222
240
|
end
|
|
223
241
|
|
|
224
242
|
@url = url
|
|
@@ -399,6 +399,88 @@ module Connectwise
|
|
|
399
399
|
# @return Array for valid properies with the reasons
|
|
400
400
|
def list_invalid_properties
|
|
401
401
|
invalid_properties = Array.new
|
|
402
|
+
if @first_name.nil?
|
|
403
|
+
invalid_properties.push("invalid value for 'first_name', first_name cannot be nil.")
|
|
404
|
+
end
|
|
405
|
+
|
|
406
|
+
if @first_name.to_s.length > 30
|
|
407
|
+
invalid_properties.push("invalid value for 'first_name', the character length must be smaller than or equal to 30.")
|
|
408
|
+
end
|
|
409
|
+
|
|
410
|
+
|
|
411
|
+
if !@last_name.nil? && @last_name.to_s.length > 30
|
|
412
|
+
invalid_properties.push("invalid value for 'last_name', the character length must be smaller than or equal to 30.")
|
|
413
|
+
end
|
|
414
|
+
|
|
415
|
+
|
|
416
|
+
if !@address_line1.nil? && @address_line1.to_s.length > 50
|
|
417
|
+
invalid_properties.push("invalid value for 'address_line1', the character length must be smaller than or equal to 50.")
|
|
418
|
+
end
|
|
419
|
+
|
|
420
|
+
|
|
421
|
+
if !@address_line2.nil? && @address_line2.to_s.length > 50
|
|
422
|
+
invalid_properties.push("invalid value for 'address_line2', the character length must be smaller than or equal to 50.")
|
|
423
|
+
end
|
|
424
|
+
|
|
425
|
+
|
|
426
|
+
if !@city.nil? && @city.to_s.length > 50
|
|
427
|
+
invalid_properties.push("invalid value for 'city', the character length must be smaller than or equal to 50.")
|
|
428
|
+
end
|
|
429
|
+
|
|
430
|
+
|
|
431
|
+
if !@state.nil? && @state.to_s.length > 50
|
|
432
|
+
invalid_properties.push("invalid value for 'state', the character length must be smaller than or equal to 50.")
|
|
433
|
+
end
|
|
434
|
+
|
|
435
|
+
|
|
436
|
+
if !@zip.nil? && @zip.to_s.length > 12
|
|
437
|
+
invalid_properties.push("invalid value for 'zip', the character length must be smaller than or equal to 12.")
|
|
438
|
+
end
|
|
439
|
+
|
|
440
|
+
|
|
441
|
+
if !@country.nil? && @country.to_s.length > 50
|
|
442
|
+
invalid_properties.push("invalid value for 'country', the character length must be smaller than or equal to 50.")
|
|
443
|
+
end
|
|
444
|
+
|
|
445
|
+
|
|
446
|
+
if !@security_identifier.nil? && @security_identifier.to_s.length > 184
|
|
447
|
+
invalid_properties.push("invalid value for 'security_identifier', the character length must be smaller than or equal to 184.")
|
|
448
|
+
end
|
|
449
|
+
|
|
450
|
+
|
|
451
|
+
if !@title.nil? && @title.to_s.length > 100
|
|
452
|
+
invalid_properties.push("invalid value for 'title', the character length must be smaller than or equal to 100.")
|
|
453
|
+
end
|
|
454
|
+
|
|
455
|
+
|
|
456
|
+
if !@school.nil? && @school.to_s.length > 50
|
|
457
|
+
invalid_properties.push("invalid value for 'school', the character length must be smaller than or equal to 50.")
|
|
458
|
+
end
|
|
459
|
+
|
|
460
|
+
|
|
461
|
+
if !@nick_name.nil? && @nick_name.to_s.length > 30
|
|
462
|
+
invalid_properties.push("invalid value for 'nick_name', the character length must be smaller than or equal to 30.")
|
|
463
|
+
end
|
|
464
|
+
|
|
465
|
+
|
|
466
|
+
if !@significant_other.nil? && @significant_other.to_s.length > 30
|
|
467
|
+
invalid_properties.push("invalid value for 'significant_other', the character length must be smaller than or equal to 30.")
|
|
468
|
+
end
|
|
469
|
+
|
|
470
|
+
|
|
471
|
+
if !@portal_password.nil? && @portal_password.to_s.length > 15
|
|
472
|
+
invalid_properties.push("invalid value for 'portal_password', the character length must be smaller than or equal to 15.")
|
|
473
|
+
end
|
|
474
|
+
|
|
475
|
+
|
|
476
|
+
if !@portal_security_level.nil? && @portal_security_level > 6.0
|
|
477
|
+
invalid_properties.push("invalid value for 'portal_security_level', must be smaller than or equal to 6.0.")
|
|
478
|
+
end
|
|
479
|
+
|
|
480
|
+
if !@portal_security_level.nil? && @portal_security_level < 1.0
|
|
481
|
+
invalid_properties.push("invalid value for 'portal_security_level', must be greater than or equal to 1.0.")
|
|
482
|
+
end
|
|
483
|
+
|
|
402
484
|
return invalid_properties
|
|
403
485
|
end
|
|
404
486
|
|
|
@@ -406,22 +488,22 @@ module Connectwise
|
|
|
406
488
|
# @return true if the model is valid
|
|
407
489
|
def valid?
|
|
408
490
|
return false if @first_name.nil?
|
|
409
|
-
return false if @first_name.to_s.length
|
|
410
|
-
return false if @last_name.to_s.length
|
|
411
|
-
return false if @address_line1.to_s.length
|
|
412
|
-
return false if @address_line2.to_s.length
|
|
413
|
-
return false if @city.to_s.length
|
|
414
|
-
return false if @state.to_s.length
|
|
415
|
-
return false if @zip.to_s.length
|
|
416
|
-
return false if @country.to_s.length
|
|
417
|
-
return false if @security_identifier.to_s.length
|
|
418
|
-
return false if @title.to_s.length
|
|
419
|
-
return false if @school.to_s.length
|
|
420
|
-
return false if @nick_name.to_s.length
|
|
421
|
-
return false if @significant_other.to_s.length
|
|
422
|
-
return false if @portal_password.to_s.length
|
|
423
|
-
return false if @portal_security_level > 6.0
|
|
424
|
-
return false if @portal_security_level < 1.0
|
|
491
|
+
return false if @first_name.to_s.length > 30
|
|
492
|
+
return false if !@last_name.nil? && @last_name.to_s.length > 30
|
|
493
|
+
return false if !@address_line1.nil? && @address_line1.to_s.length > 50
|
|
494
|
+
return false if !@address_line2.nil? && @address_line2.to_s.length > 50
|
|
495
|
+
return false if !@city.nil? && @city.to_s.length > 50
|
|
496
|
+
return false if !@state.nil? && @state.to_s.length > 50
|
|
497
|
+
return false if !@zip.nil? && @zip.to_s.length > 12
|
|
498
|
+
return false if !@country.nil? && @country.to_s.length > 50
|
|
499
|
+
return false if !@security_identifier.nil? && @security_identifier.to_s.length > 184
|
|
500
|
+
return false if !@title.nil? && @title.to_s.length > 100
|
|
501
|
+
return false if !@school.nil? && @school.to_s.length > 50
|
|
502
|
+
return false if !@nick_name.nil? && @nick_name.to_s.length > 30
|
|
503
|
+
return false if !@significant_other.nil? && @significant_other.to_s.length > 30
|
|
504
|
+
return false if !@portal_password.nil? && @portal_password.to_s.length > 15
|
|
505
|
+
return false if !@portal_security_level.nil? && @portal_security_level > 6.0
|
|
506
|
+
return false if !@portal_security_level.nil? && @portal_security_level < 1.0
|
|
425
507
|
gender_validator = EnumAttributeValidator.new('String', ["Male", "Female"])
|
|
426
508
|
return false unless gender_validator.valid?(@gender)
|
|
427
509
|
presence_validator = EnumAttributeValidator.new('String', ["Online", "DoNotDisturb", "Away", "Offline", "NoAgent"])
|
|
@@ -436,8 +518,8 @@ module Connectwise
|
|
|
436
518
|
fail ArgumentError, "first_name cannot be nil"
|
|
437
519
|
end
|
|
438
520
|
|
|
439
|
-
if first_name.to_s.length
|
|
440
|
-
fail ArgumentError, "invalid value for 'first_name', the character length must be
|
|
521
|
+
if first_name.to_s.length > 30
|
|
522
|
+
fail ArgumentError, "invalid value for 'first_name', the character length must be smaller than or equal to 30."
|
|
441
523
|
end
|
|
442
524
|
|
|
443
525
|
@first_name = first_name
|
|
@@ -446,12 +528,9 @@ module Connectwise
|
|
|
446
528
|
# Custom attribute writer method with validation
|
|
447
529
|
# @param [Object] last_name Value to be assigned
|
|
448
530
|
def last_name=(last_name)
|
|
449
|
-
if last_name.nil?
|
|
450
|
-
fail ArgumentError, "last_name cannot be nil"
|
|
451
|
-
end
|
|
452
531
|
|
|
453
|
-
if last_name.to_s.length
|
|
454
|
-
fail ArgumentError, "invalid value for 'last_name', the character length must be
|
|
532
|
+
if !last_name.nil? && last_name.to_s.length > 30
|
|
533
|
+
fail ArgumentError, "invalid value for 'last_name', the character length must be smaller than or equal to 30."
|
|
455
534
|
end
|
|
456
535
|
|
|
457
536
|
@last_name = last_name
|
|
@@ -460,12 +539,9 @@ module Connectwise
|
|
|
460
539
|
# Custom attribute writer method with validation
|
|
461
540
|
# @param [Object] address_line1 Value to be assigned
|
|
462
541
|
def address_line1=(address_line1)
|
|
463
|
-
if address_line1.nil?
|
|
464
|
-
fail ArgumentError, "address_line1 cannot be nil"
|
|
465
|
-
end
|
|
466
542
|
|
|
467
|
-
if address_line1.to_s.length
|
|
468
|
-
fail ArgumentError, "invalid value for 'address_line1', the character length must be
|
|
543
|
+
if !address_line1.nil? && address_line1.to_s.length > 50
|
|
544
|
+
fail ArgumentError, "invalid value for 'address_line1', the character length must be smaller than or equal to 50."
|
|
469
545
|
end
|
|
470
546
|
|
|
471
547
|
@address_line1 = address_line1
|
|
@@ -474,12 +550,9 @@ module Connectwise
|
|
|
474
550
|
# Custom attribute writer method with validation
|
|
475
551
|
# @param [Object] address_line2 Value to be assigned
|
|
476
552
|
def address_line2=(address_line2)
|
|
477
|
-
if address_line2.nil?
|
|
478
|
-
fail ArgumentError, "address_line2 cannot be nil"
|
|
479
|
-
end
|
|
480
553
|
|
|
481
|
-
if address_line2.to_s.length
|
|
482
|
-
fail ArgumentError, "invalid value for 'address_line2', the character length must be
|
|
554
|
+
if !address_line2.nil? && address_line2.to_s.length > 50
|
|
555
|
+
fail ArgumentError, "invalid value for 'address_line2', the character length must be smaller than or equal to 50."
|
|
483
556
|
end
|
|
484
557
|
|
|
485
558
|
@address_line2 = address_line2
|
|
@@ -488,12 +561,9 @@ module Connectwise
|
|
|
488
561
|
# Custom attribute writer method with validation
|
|
489
562
|
# @param [Object] city Value to be assigned
|
|
490
563
|
def city=(city)
|
|
491
|
-
if city.nil?
|
|
492
|
-
fail ArgumentError, "city cannot be nil"
|
|
493
|
-
end
|
|
494
564
|
|
|
495
|
-
if city.to_s.length
|
|
496
|
-
fail ArgumentError, "invalid value for 'city', the character length must be
|
|
565
|
+
if !city.nil? && city.to_s.length > 50
|
|
566
|
+
fail ArgumentError, "invalid value for 'city', the character length must be smaller than or equal to 50."
|
|
497
567
|
end
|
|
498
568
|
|
|
499
569
|
@city = city
|
|
@@ -502,12 +572,9 @@ module Connectwise
|
|
|
502
572
|
# Custom attribute writer method with validation
|
|
503
573
|
# @param [Object] state Value to be assigned
|
|
504
574
|
def state=(state)
|
|
505
|
-
if state.nil?
|
|
506
|
-
fail ArgumentError, "state cannot be nil"
|
|
507
|
-
end
|
|
508
575
|
|
|
509
|
-
if state.to_s.length
|
|
510
|
-
fail ArgumentError, "invalid value for 'state', the character length must be
|
|
576
|
+
if !state.nil? && state.to_s.length > 50
|
|
577
|
+
fail ArgumentError, "invalid value for 'state', the character length must be smaller than or equal to 50."
|
|
511
578
|
end
|
|
512
579
|
|
|
513
580
|
@state = state
|
|
@@ -516,12 +583,9 @@ module Connectwise
|
|
|
516
583
|
# Custom attribute writer method with validation
|
|
517
584
|
# @param [Object] zip Value to be assigned
|
|
518
585
|
def zip=(zip)
|
|
519
|
-
if zip.nil?
|
|
520
|
-
fail ArgumentError, "zip cannot be nil"
|
|
521
|
-
end
|
|
522
586
|
|
|
523
|
-
if zip.to_s.length
|
|
524
|
-
fail ArgumentError, "invalid value for 'zip', the character length must be
|
|
587
|
+
if !zip.nil? && zip.to_s.length > 12
|
|
588
|
+
fail ArgumentError, "invalid value for 'zip', the character length must be smaller than or equal to 12."
|
|
525
589
|
end
|
|
526
590
|
|
|
527
591
|
@zip = zip
|
|
@@ -530,12 +594,9 @@ module Connectwise
|
|
|
530
594
|
# Custom attribute writer method with validation
|
|
531
595
|
# @param [Object] country Value to be assigned
|
|
532
596
|
def country=(country)
|
|
533
|
-
if country.nil?
|
|
534
|
-
fail ArgumentError, "country cannot be nil"
|
|
535
|
-
end
|
|
536
597
|
|
|
537
|
-
if country.to_s.length
|
|
538
|
-
fail ArgumentError, "invalid value for 'country', the character length must be
|
|
598
|
+
if !country.nil? && country.to_s.length > 50
|
|
599
|
+
fail ArgumentError, "invalid value for 'country', the character length must be smaller than or equal to 50."
|
|
539
600
|
end
|
|
540
601
|
|
|
541
602
|
@country = country
|
|
@@ -544,12 +605,9 @@ module Connectwise
|
|
|
544
605
|
# Custom attribute writer method with validation
|
|
545
606
|
# @param [Object] security_identifier Value to be assigned
|
|
546
607
|
def security_identifier=(security_identifier)
|
|
547
|
-
if security_identifier.nil?
|
|
548
|
-
fail ArgumentError, "security_identifier cannot be nil"
|
|
549
|
-
end
|
|
550
608
|
|
|
551
|
-
if security_identifier.to_s.length
|
|
552
|
-
fail ArgumentError, "invalid value for 'security_identifier', the character length must be
|
|
609
|
+
if !security_identifier.nil? && security_identifier.to_s.length > 184
|
|
610
|
+
fail ArgumentError, "invalid value for 'security_identifier', the character length must be smaller than or equal to 184."
|
|
553
611
|
end
|
|
554
612
|
|
|
555
613
|
@security_identifier = security_identifier
|
|
@@ -558,12 +616,9 @@ module Connectwise
|
|
|
558
616
|
# Custom attribute writer method with validation
|
|
559
617
|
# @param [Object] title Value to be assigned
|
|
560
618
|
def title=(title)
|
|
561
|
-
if title.nil?
|
|
562
|
-
fail ArgumentError, "title cannot be nil"
|
|
563
|
-
end
|
|
564
619
|
|
|
565
|
-
if title.to_s.length
|
|
566
|
-
fail ArgumentError, "invalid value for 'title', the character length must be
|
|
620
|
+
if !title.nil? && title.to_s.length > 100
|
|
621
|
+
fail ArgumentError, "invalid value for 'title', the character length must be smaller than or equal to 100."
|
|
567
622
|
end
|
|
568
623
|
|
|
569
624
|
@title = title
|
|
@@ -572,12 +627,9 @@ module Connectwise
|
|
|
572
627
|
# Custom attribute writer method with validation
|
|
573
628
|
# @param [Object] school Value to be assigned
|
|
574
629
|
def school=(school)
|
|
575
|
-
if school.nil?
|
|
576
|
-
fail ArgumentError, "school cannot be nil"
|
|
577
|
-
end
|
|
578
630
|
|
|
579
|
-
if school.to_s.length
|
|
580
|
-
fail ArgumentError, "invalid value for 'school', the character length must be
|
|
631
|
+
if !school.nil? && school.to_s.length > 50
|
|
632
|
+
fail ArgumentError, "invalid value for 'school', the character length must be smaller than or equal to 50."
|
|
581
633
|
end
|
|
582
634
|
|
|
583
635
|
@school = school
|
|
@@ -586,12 +638,9 @@ module Connectwise
|
|
|
586
638
|
# Custom attribute writer method with validation
|
|
587
639
|
# @param [Object] nick_name Value to be assigned
|
|
588
640
|
def nick_name=(nick_name)
|
|
589
|
-
if nick_name.nil?
|
|
590
|
-
fail ArgumentError, "nick_name cannot be nil"
|
|
591
|
-
end
|
|
592
641
|
|
|
593
|
-
if nick_name.to_s.length
|
|
594
|
-
fail ArgumentError, "invalid value for 'nick_name', the character length must be
|
|
642
|
+
if !nick_name.nil? && nick_name.to_s.length > 30
|
|
643
|
+
fail ArgumentError, "invalid value for 'nick_name', the character length must be smaller than or equal to 30."
|
|
595
644
|
end
|
|
596
645
|
|
|
597
646
|
@nick_name = nick_name
|
|
@@ -600,12 +649,9 @@ module Connectwise
|
|
|
600
649
|
# Custom attribute writer method with validation
|
|
601
650
|
# @param [Object] significant_other Value to be assigned
|
|
602
651
|
def significant_other=(significant_other)
|
|
603
|
-
if significant_other.nil?
|
|
604
|
-
fail ArgumentError, "significant_other cannot be nil"
|
|
605
|
-
end
|
|
606
652
|
|
|
607
|
-
if significant_other.to_s.length
|
|
608
|
-
fail ArgumentError, "invalid value for 'significant_other', the character length must be
|
|
653
|
+
if !significant_other.nil? && significant_other.to_s.length > 30
|
|
654
|
+
fail ArgumentError, "invalid value for 'significant_other', the character length must be smaller than or equal to 30."
|
|
609
655
|
end
|
|
610
656
|
|
|
611
657
|
@significant_other = significant_other
|
|
@@ -614,12 +660,9 @@ module Connectwise
|
|
|
614
660
|
# Custom attribute writer method with validation
|
|
615
661
|
# @param [Object] portal_password Value to be assigned
|
|
616
662
|
def portal_password=(portal_password)
|
|
617
|
-
if portal_password.nil?
|
|
618
|
-
fail ArgumentError, "portal_password cannot be nil"
|
|
619
|
-
end
|
|
620
663
|
|
|
621
|
-
if portal_password.to_s.length
|
|
622
|
-
fail ArgumentError, "invalid value for 'portal_password', the character length must be
|
|
664
|
+
if !portal_password.nil? && portal_password.to_s.length > 15
|
|
665
|
+
fail ArgumentError, "invalid value for 'portal_password', the character length must be smaller than or equal to 15."
|
|
623
666
|
end
|
|
624
667
|
|
|
625
668
|
@portal_password = portal_password
|
|
@@ -628,15 +671,12 @@ module Connectwise
|
|
|
628
671
|
# Custom attribute writer method with validation
|
|
629
672
|
# @param [Object] portal_security_level Value to be assigned
|
|
630
673
|
def portal_security_level=(portal_security_level)
|
|
631
|
-
if portal_security_level.nil?
|
|
632
|
-
fail ArgumentError, "portal_security_level cannot be nil"
|
|
633
|
-
end
|
|
634
674
|
|
|
635
|
-
if portal_security_level > 6.0
|
|
675
|
+
if !portal_security_level.nil? && portal_security_level > 6.0
|
|
636
676
|
fail ArgumentError, "invalid value for 'portal_security_level', must be smaller than or equal to 6.0."
|
|
637
677
|
end
|
|
638
678
|
|
|
639
|
-
if portal_security_level < 1.0
|
|
679
|
+
if !portal_security_level.nil? && portal_security_level < 1.0
|
|
640
680
|
fail ArgumentError, "invalid value for 'portal_security_level', must be greater than or equal to 1.0."
|
|
641
681
|
end
|
|
642
682
|
|