ZCRMSDK 2.0.0 → 3.0.1
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/src/ZCRMSDK.rb +87 -2
- data/src/com/zoho/api/authenticator/oauth_token.rb +86 -31
- data/src/com/zoho/api/authenticator/store/db_store.rb +71 -29
- data/src/com/zoho/api/authenticator/store/file_store.rb +91 -21
- data/src/com/zoho/api/authenticator/store/token_store.rb +7 -0
- data/src/com/zoho/api/logger/sdk_logger.rb +18 -9
- data/src/com/zoho/crm/api/assignment_rules/api_exception.rb +121 -0
- data/src/com/zoho/crm/api/assignment_rules/assignment_rule.rb +215 -0
- data/src/com/zoho/crm/api/assignment_rules/assignment_rules_operations.rb +61 -0
- data/src/com/zoho/crm/api/assignment_rules/default_user.rb +80 -0
- data/src/com/zoho/crm/api/assignment_rules/response_handler.rb +10 -0
- data/src/com/zoho/crm/api/assignment_rules/response_wrapper.rb +63 -0
- data/src/com/zoho/crm/api/attachments/attachment.rb +42 -4
- data/src/com/zoho/crm/api/attachments/attachments_operations.rb +6 -6
- data/src/com/zoho/crm/api/blue_print/blue_print_operations.rb +2 -2
- data/src/com/zoho/crm/api/blue_print/escalation.rb +80 -0
- data/src/com/zoho/crm/api/blue_print/field.rb +1127 -0
- data/src/com/zoho/crm/api/blue_print/next_transition.rb +38 -0
- data/src/com/zoho/crm/api/blue_print/process_info.rb +4 -4
- data/src/com/zoho/crm/api/blue_print/transition.rb +19 -1
- data/src/com/zoho/crm/api/blue_print/validation_error.rb +57 -0
- data/src/com/zoho/crm/api/bulk_read/bulk_read_operations.rb +3 -3
- data/src/com/zoho/crm/api/bulk_read/criteria.rb +20 -0
- data/src/com/zoho/crm/api/bulk_read/query.rb +5 -4
- data/src/com/zoho/crm/api/bulk_write/bulk_write_operations.rb +3 -3
- data/src/com/zoho/crm/api/bulk_write/resource.rb +24 -4
- data/src/com/zoho/crm/api/contact_roles/contact_roles_operations.rb +7 -7
- data/src/com/zoho/crm/api/currencies/currencies_operations.rb +7 -7
- data/src/com/zoho/crm/api/custom_views/criteria.rb +5 -4
- data/src/com/zoho/crm/api/custom_views/custom_view.rb +100 -41
- data/src/com/zoho/crm/api/custom_views/custom_views_operations.rb +2 -2
- data/src/com/zoho/crm/api/custom_views/{shared_details.rb → shared_to.rb} +2 -2
- data/src/com/zoho/crm/api/dc/au_datacenter.rb +3 -3
- data/src/com/zoho/crm/api/dc/cn_datacenter.rb +3 -3
- data/src/com/zoho/crm/api/dc/datacenter.rb +3 -2
- data/src/com/zoho/crm/api/dc/eu_datacenter.rb +3 -3
- data/src/com/zoho/crm/api/dc/in_datacenter.rb +3 -3
- data/src/com/zoho/crm/api/dc/us_datacenter.rb +3 -3
- data/src/com/zoho/crm/api/email_templates/api_exception.rb +121 -0
- data/src/com/zoho/crm/api/email_templates/attachment.rb +118 -0
- data/src/com/zoho/crm/api/email_templates/email_template.rb +390 -0
- data/src/com/zoho/crm/api/email_templates/email_templates_operations.rb +61 -0
- data/src/com/zoho/crm/api/email_templates/response_handler.rb +10 -0
- data/src/com/zoho/crm/api/email_templates/response_wrapper.rb +83 -0
- data/src/com/zoho/crm/api/field_attachments/api_exception.rb +121 -0
- data/src/com/zoho/crm/api/field_attachments/body_wrapper.rb +62 -0
- data/src/com/zoho/crm/api/field_attachments/field_attachments_operations.rb +52 -0
- data/src/com/zoho/crm/api/field_attachments/file_body_wrapper.rb +64 -0
- data/src/com/zoho/crm/api/field_attachments/response_handler.rb +10 -0
- data/src/com/zoho/crm/api/fields/external.rb +99 -0
- data/src/com/zoho/crm/api/fields/field.rb +215 -61
- data/src/com/zoho/crm/api/fields/fields_operations.rb +2 -2
- data/src/com/zoho/crm/api/fields/history_tracking.rb +80 -0
- data/src/com/zoho/crm/api/fields/maps.rb +80 -0
- data/src/com/zoho/crm/api/fields/multi_module_lookup.rb +99 -0
- data/src/com/zoho/crm/api/fields/multi_select_lookup.rb +19 -0
- data/src/com/zoho/crm/api/fields/multi_user_lookup.rb +175 -0
- data/src/com/zoho/crm/api/fields/pick_list_value.rb +19 -0
- data/src/com/zoho/crm/api/fields/related_details.rb +19 -0
- data/src/com/zoho/crm/api/files/file_operations.rb +2 -2
- data/src/com/zoho/crm/api/initializer.rb +45 -17
- data/src/com/zoho/crm/api/inventory_templates/api_exception.rb +121 -0
- data/src/com/zoho/crm/api/inventory_templates/inventory_template.rb +352 -0
- data/src/com/zoho/crm/api/inventory_templates/inventory_templates_operations.rb +82 -0
- data/src/com/zoho/crm/api/inventory_templates/response_handler.rb +10 -0
- data/src/com/zoho/crm/api/inventory_templates/response_wrapper.rb +83 -0
- data/src/com/zoho/crm/api/layouts/layout.rb +38 -0
- data/src/com/zoho/crm/api/layouts/layouts_operations.rb +2 -2
- data/src/com/zoho/crm/api/layouts/section.rb +19 -0
- data/src/com/zoho/crm/api/modules/module.rb +57 -0
- data/src/com/zoho/crm/api/modules/modules_operations.rb +4 -4
- data/src/com/zoho/crm/api/notes/note.rb +19 -0
- data/src/com/zoho/crm/api/notes/notes_operations.rb +7 -7
- data/src/com/zoho/crm/api/notification/notification_operations.rb +6 -6
- data/src/com/zoho/crm/api/org/hierarchy_preference.rb +61 -0
- data/src/com/zoho/crm/api/org/org.rb +38 -0
- data/src/com/zoho/crm/api/org/org_operations.rb +2 -2
- data/src/com/zoho/crm/api/pipeline/action_handler.rb +10 -0
- data/src/com/zoho/crm/api/pipeline/action_response.rb +10 -0
- data/src/com/zoho/crm/api/pipeline/action_wrapper.rb +63 -0
- data/src/com/zoho/crm/api/pipeline/api_exception.rb +129 -0
- data/src/com/zoho/crm/api/pipeline/body_wrapper.rb +61 -0
- data/src/com/zoho/crm/api/pipeline/forecast_category.rb +80 -0
- data/src/com/zoho/crm/api/pipeline/pick_list_value.rb +175 -0
- data/src/com/zoho/crm/api/pipeline/pipeline.rb +213 -0
- data/src/com/zoho/crm/api/pipeline/pipeline_operations.rb +165 -0
- data/src/com/zoho/crm/api/pipeline/response_handler.rb +10 -0
- data/src/com/zoho/crm/api/pipeline/response_wrapper.rb +63 -0
- data/src/com/zoho/crm/api/pipeline/stage.rb +80 -0
- data/src/com/zoho/crm/api/pipeline/success_response.rb +123 -0
- data/src/com/zoho/crm/api/pipeline/transfer_action_handler.rb +10 -0
- data/src/com/zoho/crm/api/pipeline/transfer_action_response.rb +10 -0
- data/src/com/zoho/crm/api/pipeline/transfer_action_wrapper.rb +63 -0
- data/src/com/zoho/crm/api/pipeline/transfer_and_delete_wrapper.rb +61 -0
- data/src/com/zoho/crm/api/pipeline/transfer_pipe_line.rb +80 -0
- data/src/com/zoho/crm/api/profiles/category.rb +19 -0
- data/src/com/zoho/crm/api/profiles/default_view.rb +99 -0
- data/src/com/zoho/crm/api/profiles/profile.rb +49 -11
- data/src/com/zoho/crm/api/profiles/profiles_operations.rb +2 -2
- data/src/com/zoho/crm/api/query/query_operations.rb +1 -1
- data/src/com/zoho/crm/api/record/api_exception.rb +2 -0
- data/src/com/zoho/crm/api/record/body_wrapper.rb +0 -19
- data/src/com/zoho/crm/api/record/count_handler.rb +10 -0
- data/src/com/zoho/crm/api/record/count_wrapper.rb +63 -0
- data/src/com/zoho/crm/api/record/field.rb +17 -17
- data/src/com/zoho/crm/api/record/image_upload.rb +213 -0
- data/src/com/zoho/crm/api/record/line_tax.rb +19 -0
- data/src/com/zoho/crm/api/record/mass_update_body_wrapper.rb +4 -4
- data/src/com/zoho/crm/api/record/mass_update_territory.rb +80 -0
- data/src/com/zoho/crm/api/record/multi_select_lookup.rb +99 -0
- data/src/com/zoho/crm/api/record/multi_select_picklist.rb +80 -0
- data/src/com/zoho/crm/api/record/price_book.rb +31 -0
- data/src/com/zoho/crm/api/record/record_operations.rb +196 -26
- data/src/com/zoho/crm/api/record/tax.rb +80 -0
- data/src/com/zoho/crm/api/record/territory.rb +70 -12
- data/src/com/zoho/crm/api/record/widget.rb +80 -0
- data/src/com/zoho/crm/api/record/wizard.rb +80 -0
- data/src/com/zoho/crm/api/related_lists/related_lists_operations.rb +2 -2
- data/src/com/zoho/crm/api/related_records/related_records_operations.rb +6 -6
- data/src/com/zoho/crm/api/request_proxy.rb +3 -4
- data/src/com/zoho/crm/api/roles/roles_operations.rb +2 -2
- data/src/com/zoho/crm/api/sdk_config.rb +2 -68
- data/src/com/zoho/crm/api/send_mail/action_handler.rb +10 -0
- data/src/com/zoho/crm/api/send_mail/action_response.rb +10 -0
- data/src/com/zoho/crm/api/send_mail/action_wrapper.rb +63 -0
- data/src/com/zoho/crm/api/send_mail/api_exception.rb +125 -0
- data/src/com/zoho/crm/api/send_mail/body_wrapper.rb +61 -0
- data/src/com/zoho/crm/api/send_mail/data_subject_request.rb +80 -0
- data/src/com/zoho/crm/api/send_mail/inventory_details.rb +100 -0
- data/src/com/zoho/crm/api/send_mail/mail.rb +423 -0
- data/src/com/zoho/crm/api/send_mail/response_handler.rb +10 -0
- data/src/com/zoho/crm/api/send_mail/response_wrapper.rb +63 -0
- data/src/com/zoho/crm/api/send_mail/send_mail_operations.rb +61 -0
- data/src/com/zoho/crm/api/send_mail/success_response.rb +121 -0
- data/src/com/zoho/crm/api/send_mail/template.rb +10 -0
- data/src/com/zoho/crm/api/send_mail/user_address.rb +137 -0
- data/src/com/zoho/crm/api/share_records/share_records_operations.rb +4 -4
- data/src/com/zoho/crm/api/tags/tag.rb +19 -0
- data/src/com/zoho/crm/api/tags/tags_operations.rb +11 -11
- data/src/com/zoho/crm/api/taxes/taxes_operations.rb +6 -6
- data/src/com/zoho/crm/api/territories/response_wrapper.rb +20 -0
- data/src/com/zoho/crm/api/territories/territories_operations.rb +2 -2
- data/src/com/zoho/crm/api/territories/territory.rb +61 -23
- data/src/com/zoho/crm/api/users/user.rb +34 -0
- data/src/com/zoho/crm/api/users/users_operations.rb +6 -6
- data/src/com/zoho/crm/api/util/api_http_connector.rb +6 -5
- data/src/com/zoho/crm/api/util/common_api_handler.rb +5 -3
- data/src/com/zoho/crm/api/util/constants.rb +140 -15
- data/src/com/zoho/crm/api/util/converter.rb +30 -7
- data/src/com/zoho/crm/api/util/data_type_converter.rb +8 -2
- data/src/com/zoho/crm/api/util/form_data_converter.rb +4 -15
- data/src/com/zoho/crm/api/util/json_converter.rb +7 -9
- data/src/com/zoho/crm/api/util/module_fields_handler.rb +1 -1
- data/src/com/zoho/crm/api/util/utility.rb +274 -87
- data/src/com/zoho/crm/api/variable_groups/variable_groups_operations.rb +3 -3
- data/src/com/zoho/crm/api/variables/variables_operations.rb +9 -9
- data/src/com/zoho/crm/api/wizards/api_exception.rb +121 -0
- data/src/com/zoho/crm/api/wizards/button.rb +252 -0
- data/src/com/zoho/crm/api/wizards/chart_data.rb +118 -0
- data/src/com/zoho/crm/api/wizards/connection.rb +80 -0
- data/src/com/zoho/crm/api/wizards/container.rb +119 -0
- data/src/com/zoho/crm/api/wizards/node.rb +118 -0
- data/src/com/zoho/crm/api/wizards/response_handler.rb +10 -0
- data/src/com/zoho/crm/api/wizards/response_wrapper.rb +63 -0
- data/src/com/zoho/crm/api/wizards/screen.rb +99 -0
- data/src/com/zoho/crm/api/wizards/segment.rb +176 -0
- data/src/com/zoho/crm/api/wizards/transition.rb +80 -0
- data/src/com/zoho/crm/api/wizards/wizard.rb +273 -0
- data/src/com/zoho/crm/api/wizards/wizards_operations.rb +61 -0
- data/src/resources/JSONDetails.json +1 -1
- data/src/version.rb +1 -1
- metadata +92 -7
- data/src/com/zoho/crm/api/record/inventory_line_items.rb +0 -235
@@ -22,7 +22,7 @@ module Profiles
|
|
22
22
|
def get_profiles
|
23
23
|
handler_instance = Handler::CommonAPIHandler.new
|
24
24
|
api_path = ''
|
25
|
-
api_path = api_path + '/crm/v2/settings/profiles'
|
25
|
+
api_path = api_path + '/crm/v2.1/settings/profiles'
|
26
26
|
handler_instance.api_path = api_path
|
27
27
|
handler_instance.http_method = Constants::REQUEST_METHOD_GET
|
28
28
|
handler_instance.category_method = 'READ'
|
@@ -41,7 +41,7 @@ module Profiles
|
|
41
41
|
end
|
42
42
|
handler_instance = Handler::CommonAPIHandler.new
|
43
43
|
api_path = ''
|
44
|
-
api_path = api_path + '/crm/v2/settings/profiles/'
|
44
|
+
api_path = api_path + '/crm/v2.1/settings/profiles/'
|
45
45
|
api_path = api_path + id.to_s
|
46
46
|
handler_instance.api_path = api_path
|
47
47
|
handler_instance.http_method = Constants::REQUEST_METHOD_GET
|
@@ -20,7 +20,7 @@ module Query
|
|
20
20
|
end
|
21
21
|
handler_instance = Handler::CommonAPIHandler.new
|
22
22
|
api_path = ''
|
23
|
-
api_path = api_path + '/crm/v2/coql'
|
23
|
+
api_path = api_path + '/crm/v2.1/coql'
|
24
24
|
handler_instance.api_path = api_path
|
25
25
|
handler_instance.http_method = Constants::REQUEST_METHOD_POST
|
26
26
|
handler_instance.category_method = 'CREATE'
|
@@ -14,6 +14,7 @@ module Record
|
|
14
14
|
require_relative 'mass_update_action_handler'
|
15
15
|
require_relative 'mass_update_response'
|
16
16
|
require_relative 'mass_update_response_handler'
|
17
|
+
require_relative 'count_handler'
|
17
18
|
class APIException
|
18
19
|
include Util::Model
|
19
20
|
include ResponseHandler
|
@@ -28,6 +29,7 @@ module Record
|
|
28
29
|
include MassUpdateActionHandler
|
29
30
|
include MassUpdateResponse
|
30
31
|
include MassUpdateResponseHandler
|
32
|
+
include CountHandler
|
31
33
|
|
32
34
|
# Creates an instance of APIException
|
33
35
|
def initialize
|
@@ -8,7 +8,6 @@ module Record
|
|
8
8
|
def initialize
|
9
9
|
@data = nil
|
10
10
|
@trigger = nil
|
11
|
-
@process = nil
|
12
11
|
@duplicate_check_fields = nil
|
13
12
|
@wf_trigger = nil
|
14
13
|
@lar_id = nil
|
@@ -51,24 +50,6 @@ module Record
|
|
51
50
|
@key_modified['trigger'] = 1
|
52
51
|
end
|
53
52
|
|
54
|
-
# The method to get the process
|
55
|
-
# @return An instance of Array
|
56
|
-
|
57
|
-
def process
|
58
|
-
@process
|
59
|
-
end
|
60
|
-
|
61
|
-
# The method to set the value to process
|
62
|
-
# @param process [Array] An instance of Array
|
63
|
-
|
64
|
-
def process=(process)
|
65
|
-
if process!=nil and !process.is_a? Array
|
66
|
-
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: process EXPECTED TYPE: Array', nil, nil)
|
67
|
-
end
|
68
|
-
@process = process
|
69
|
-
@key_modified['process'] = 1
|
70
|
-
end
|
71
|
-
|
72
53
|
# The method to get the duplicate_check_fields
|
73
54
|
# @return An instance of Array
|
74
55
|
|
@@ -0,0 +1,63 @@
|
|
1
|
+
require_relative '../util/model'
|
2
|
+
|
3
|
+
module Record
|
4
|
+
require_relative 'count_handler'
|
5
|
+
class CountWrapper
|
6
|
+
include Util::Model
|
7
|
+
include CountHandler
|
8
|
+
|
9
|
+
# Creates an instance of CountWrapper
|
10
|
+
def initialize
|
11
|
+
@count = nil
|
12
|
+
@key_modified = Hash.new
|
13
|
+
end
|
14
|
+
|
15
|
+
# The method to get the count
|
16
|
+
# @return A String value
|
17
|
+
|
18
|
+
def count
|
19
|
+
@count
|
20
|
+
end
|
21
|
+
|
22
|
+
# The method to set the value to count
|
23
|
+
# @param count [String] A String
|
24
|
+
|
25
|
+
def count=(count)
|
26
|
+
if count!=nil and !count.is_a? String
|
27
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: count EXPECTED TYPE: String', nil, nil)
|
28
|
+
end
|
29
|
+
@count = count
|
30
|
+
@key_modified['count'] = 1
|
31
|
+
end
|
32
|
+
|
33
|
+
# The method to check if the user has modified the given key
|
34
|
+
# @param key [String] A String
|
35
|
+
# @return A Integer value
|
36
|
+
|
37
|
+
def is_key_modified(key)
|
38
|
+
if key!=nil and !key.is_a? String
|
39
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: key EXPECTED TYPE: String', nil, nil)
|
40
|
+
end
|
41
|
+
if @key_modified.key?(key)
|
42
|
+
return @key_modified[key]
|
43
|
+
end
|
44
|
+
|
45
|
+
nil
|
46
|
+
end
|
47
|
+
|
48
|
+
# The method to mark the given key as modified
|
49
|
+
# @param key [String] A String
|
50
|
+
# @param modification [Integer] A Integer
|
51
|
+
|
52
|
+
def set_key_modified(key, modification)
|
53
|
+
if key!=nil and !key.is_a? String
|
54
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: key EXPECTED TYPE: String', nil, nil)
|
55
|
+
end
|
56
|
+
if modification!=nil and !modification.is_a? Integer
|
57
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: modification EXPECTED TYPE: Integer', nil, nil)
|
58
|
+
end
|
59
|
+
@key_modified[key] = modification
|
60
|
+
end
|
61
|
+
|
62
|
+
end
|
63
|
+
end
|
@@ -1,10 +1,10 @@
|
|
1
1
|
require_relative '../layouts/layout'
|
2
|
-
require_relative '../record/inventory_line_items'
|
3
2
|
require_relative '../record/participants'
|
4
3
|
require_relative '../record/pricing_details'
|
5
4
|
require_relative '../record/record'
|
6
5
|
require_relative '../record/recurring_activity'
|
7
6
|
require_relative '../record/remind_at'
|
7
|
+
require_relative '../record/tax'
|
8
8
|
require_relative '../tags/tag'
|
9
9
|
require_relative '../users/user'
|
10
10
|
require_relative '../util/choice'
|
@@ -790,6 +790,10 @@ module Record
|
|
790
790
|
def self.Carrier
|
791
791
|
@@Carrier
|
792
792
|
end
|
793
|
+
@@Quoted_items = Field.new('Quoted_Items')
|
794
|
+
def self.Quoted_items
|
795
|
+
@@Quoted_items
|
796
|
+
end
|
793
797
|
@@Quote_stage = Field.new('Quote_Stage')
|
794
798
|
def self.Quote_stage
|
795
799
|
@@Quote_stage
|
@@ -826,10 +830,6 @@ module Record
|
|
826
830
|
def self.Billing_code
|
827
831
|
@@Billing_code
|
828
832
|
end
|
829
|
-
@@Product_details = Field.new('Product_Details')
|
830
|
-
def self.Product_details
|
831
|
-
@@Product_details
|
832
|
-
end
|
833
833
|
@@Subject = Field.new('Subject')
|
834
834
|
def self.Subject
|
835
835
|
@@Subject
|
@@ -905,6 +905,10 @@ module Record
|
|
905
905
|
def self.Modified_by
|
906
906
|
@@Modified_by
|
907
907
|
end
|
908
|
+
@@Invoiced_items = Field.new('Invoiced_Items')
|
909
|
+
def self.Invoiced_items
|
910
|
+
@@Invoiced_items
|
911
|
+
end
|
908
912
|
@@Billing_country = Field.new('Billing_Country')
|
909
913
|
def self.Billing_country
|
910
914
|
@@Billing_country
|
@@ -969,10 +973,6 @@ module Record
|
|
969
973
|
def self.Billing_code
|
970
974
|
@@Billing_code
|
971
975
|
end
|
972
|
-
@@Product_details = Field.new('Product_Details')
|
973
|
-
def self.Product_details
|
974
|
-
@@Product_details
|
975
|
-
end
|
976
976
|
@@Subject = Field.new('Subject')
|
977
977
|
def self.Subject
|
978
978
|
@@Subject
|
@@ -1162,6 +1162,10 @@ module Record
|
|
1162
1162
|
def self.Carrier
|
1163
1163
|
@@Carrier
|
1164
1164
|
end
|
1165
|
+
@@Ordered_items = Field.new('Ordered_Items')
|
1166
|
+
def self.Ordered_items
|
1167
|
+
@@Ordered_items
|
1168
|
+
end
|
1165
1169
|
@@Quote_name = Field.new('Quote_Name')
|
1166
1170
|
def self.Quote_name
|
1167
1171
|
@@Quote_name
|
@@ -1210,10 +1214,6 @@ module Record
|
|
1210
1214
|
def self.Billing_code
|
1211
1215
|
@@Billing_code
|
1212
1216
|
end
|
1213
|
-
@@Product_details = Field.new('Product_Details')
|
1214
|
-
def self.Product_details
|
1215
|
-
@@Product_details
|
1216
|
-
end
|
1217
1217
|
@@Subject = Field.new('Subject')
|
1218
1218
|
def self.Subject
|
1219
1219
|
@@Subject
|
@@ -1690,6 +1690,10 @@ module Record
|
|
1690
1690
|
def self.Billing_country
|
1691
1691
|
@@Billing_country
|
1692
1692
|
end
|
1693
|
+
@@Purchase_items = Field.new('Purchase_Items')
|
1694
|
+
def self.Purchase_items
|
1695
|
+
@@Purchase_items
|
1696
|
+
end
|
1693
1697
|
@@id = Field.new('id')
|
1694
1698
|
def self.id
|
1695
1699
|
@@id
|
@@ -1746,10 +1750,6 @@ module Record
|
|
1746
1750
|
def self.Billing_code
|
1747
1751
|
@@Billing_code
|
1748
1752
|
end
|
1749
|
-
@@Product_details = Field.new('Product_Details')
|
1750
|
-
def self.Product_details
|
1751
|
-
@@Product_details
|
1752
|
-
end
|
1753
1753
|
@@Subject = Field.new('Subject')
|
1754
1754
|
def self.Subject
|
1755
1755
|
@@Subject
|
@@ -0,0 +1,213 @@
|
|
1
|
+
require_relative '../util/model'
|
2
|
+
|
3
|
+
module Record
|
4
|
+
class ImageUpload
|
5
|
+
include Util::Model
|
6
|
+
|
7
|
+
# Creates an instance of ImageUpload
|
8
|
+
def initialize
|
9
|
+
@description = nil
|
10
|
+
@preview_id = nil
|
11
|
+
@encrypted_id = nil
|
12
|
+
@file_name = nil
|
13
|
+
@state = nil
|
14
|
+
@file_id = nil
|
15
|
+
@size = nil
|
16
|
+
@sequence_number = nil
|
17
|
+
@id = nil
|
18
|
+
@key_modified = Hash.new
|
19
|
+
end
|
20
|
+
|
21
|
+
# The method to get the description
|
22
|
+
# @return A String value
|
23
|
+
|
24
|
+
def description
|
25
|
+
@description
|
26
|
+
end
|
27
|
+
|
28
|
+
# The method to set the value to description
|
29
|
+
# @param description [String] A String
|
30
|
+
|
31
|
+
def description=(description)
|
32
|
+
if description!=nil and !description.is_a? String
|
33
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: description EXPECTED TYPE: String', nil, nil)
|
34
|
+
end
|
35
|
+
@description = description
|
36
|
+
@key_modified['Description'] = 1
|
37
|
+
end
|
38
|
+
|
39
|
+
# The method to get the preview_id
|
40
|
+
# @return A String value
|
41
|
+
|
42
|
+
def preview_id
|
43
|
+
@preview_id
|
44
|
+
end
|
45
|
+
|
46
|
+
# The method to set the value to preview_id
|
47
|
+
# @param preview_id [String] A String
|
48
|
+
|
49
|
+
def preview_id=(preview_id)
|
50
|
+
if preview_id!=nil and !preview_id.is_a? String
|
51
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: preview_id EXPECTED TYPE: String', nil, nil)
|
52
|
+
end
|
53
|
+
@preview_id = preview_id
|
54
|
+
@key_modified['Preview_Id'] = 1
|
55
|
+
end
|
56
|
+
|
57
|
+
# The method to get the encrypted_id
|
58
|
+
# @return A String value
|
59
|
+
|
60
|
+
def encrypted_id
|
61
|
+
@encrypted_id
|
62
|
+
end
|
63
|
+
|
64
|
+
# The method to set the value to encrypted_id
|
65
|
+
# @param encrypted_id [String] A String
|
66
|
+
|
67
|
+
def encrypted_id=(encrypted_id)
|
68
|
+
if encrypted_id!=nil and !encrypted_id.is_a? String
|
69
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: encrypted_id EXPECTED TYPE: String', nil, nil)
|
70
|
+
end
|
71
|
+
@encrypted_id = encrypted_id
|
72
|
+
@key_modified['Encrypted_Id'] = 1
|
73
|
+
end
|
74
|
+
|
75
|
+
# The method to get the file_name
|
76
|
+
# @return A String value
|
77
|
+
|
78
|
+
def file_name
|
79
|
+
@file_name
|
80
|
+
end
|
81
|
+
|
82
|
+
# The method to set the value to file_name
|
83
|
+
# @param file_name [String] A String
|
84
|
+
|
85
|
+
def file_name=(file_name)
|
86
|
+
if file_name!=nil and !file_name.is_a? String
|
87
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: file_name EXPECTED TYPE: String', nil, nil)
|
88
|
+
end
|
89
|
+
@file_name = file_name
|
90
|
+
@key_modified['File_Name'] = 1
|
91
|
+
end
|
92
|
+
|
93
|
+
# The method to get the state
|
94
|
+
# @return A String value
|
95
|
+
|
96
|
+
def state
|
97
|
+
@state
|
98
|
+
end
|
99
|
+
|
100
|
+
# The method to set the value to state
|
101
|
+
# @param state [String] A String
|
102
|
+
|
103
|
+
def state=(state)
|
104
|
+
if state!=nil and !state.is_a? String
|
105
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: state EXPECTED TYPE: String', nil, nil)
|
106
|
+
end
|
107
|
+
@state = state
|
108
|
+
@key_modified['State'] = 1
|
109
|
+
end
|
110
|
+
|
111
|
+
# The method to get the file_id
|
112
|
+
# @return A String value
|
113
|
+
|
114
|
+
def file_id
|
115
|
+
@file_id
|
116
|
+
end
|
117
|
+
|
118
|
+
# The method to set the value to file_id
|
119
|
+
# @param file_id [String] A String
|
120
|
+
|
121
|
+
def file_id=(file_id)
|
122
|
+
if file_id!=nil and !file_id.is_a? String
|
123
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: file_id EXPECTED TYPE: String', nil, nil)
|
124
|
+
end
|
125
|
+
@file_id = file_id
|
126
|
+
@key_modified['File_Id'] = 1
|
127
|
+
end
|
128
|
+
|
129
|
+
# The method to get the size
|
130
|
+
# @return A Integer value
|
131
|
+
|
132
|
+
def size
|
133
|
+
@size
|
134
|
+
end
|
135
|
+
|
136
|
+
# The method to set the value to size
|
137
|
+
# @param size [Integer] A Integer
|
138
|
+
|
139
|
+
def size=(size)
|
140
|
+
if size!=nil and !size.is_a? Integer
|
141
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: size EXPECTED TYPE: Integer', nil, nil)
|
142
|
+
end
|
143
|
+
@size = size
|
144
|
+
@key_modified['Size'] = 1
|
145
|
+
end
|
146
|
+
|
147
|
+
# The method to get the sequence_number
|
148
|
+
# @return A Integer value
|
149
|
+
|
150
|
+
def sequence_number
|
151
|
+
@sequence_number
|
152
|
+
end
|
153
|
+
|
154
|
+
# The method to set the value to sequence_number
|
155
|
+
# @param sequence_number [Integer] A Integer
|
156
|
+
|
157
|
+
def sequence_number=(sequence_number)
|
158
|
+
if sequence_number!=nil and !sequence_number.is_a? Integer
|
159
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: sequence_number EXPECTED TYPE: Integer', nil, nil)
|
160
|
+
end
|
161
|
+
@sequence_number = sequence_number
|
162
|
+
@key_modified['Sequence_Number'] = 1
|
163
|
+
end
|
164
|
+
|
165
|
+
# The method to get the id
|
166
|
+
# @return A Integer value
|
167
|
+
|
168
|
+
def id
|
169
|
+
@id
|
170
|
+
end
|
171
|
+
|
172
|
+
# The method to set the value to id
|
173
|
+
# @param id [Integer] A Integer
|
174
|
+
|
175
|
+
def id=(id)
|
176
|
+
if id!=nil and !id.is_a? Integer
|
177
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: id EXPECTED TYPE: Integer', nil, nil)
|
178
|
+
end
|
179
|
+
@id = id
|
180
|
+
@key_modified['id'] = 1
|
181
|
+
end
|
182
|
+
|
183
|
+
# The method to check if the user has modified the given key
|
184
|
+
# @param key [String] A String
|
185
|
+
# @return A Integer value
|
186
|
+
|
187
|
+
def is_key_modified(key)
|
188
|
+
if key!=nil and !key.is_a? String
|
189
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: key EXPECTED TYPE: String', nil, nil)
|
190
|
+
end
|
191
|
+
if @key_modified.key?(key)
|
192
|
+
return @key_modified[key]
|
193
|
+
end
|
194
|
+
|
195
|
+
nil
|
196
|
+
end
|
197
|
+
|
198
|
+
# The method to mark the given key as modified
|
199
|
+
# @param key [String] A String
|
200
|
+
# @param modification [Integer] A Integer
|
201
|
+
|
202
|
+
def set_key_modified(key, modification)
|
203
|
+
if key!=nil and !key.is_a? String
|
204
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: key EXPECTED TYPE: String', nil, nil)
|
205
|
+
end
|
206
|
+
if modification!=nil and !modification.is_a? Integer
|
207
|
+
raise SDKException.new(Constants::DATA_TYPE_ERROR, 'KEY: modification EXPECTED TYPE: Integer', nil, nil)
|
208
|
+
end
|
209
|
+
@key_modified[key] = modification
|
210
|
+
end
|
211
|
+
|
212
|
+
end
|
213
|
+
end
|