trevol 0.3.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +34 -0
- data/GENERADO.md +1 -1
- data/README.md +1 -1
- data/lib/trevol/client.rb +6 -1
- data/lib/trevol/transporte.rb +1 -0
- data/lib/trevol_generado/api/account_api.rb +2 -2
- data/lib/trevol_generado/api/balance_api.rb +2 -2
- data/lib/trevol_generado/api/catalogs_api.rb +164 -0
- data/lib/trevol_generado/api/company_settings_api.rb +384 -0
- data/lib/trevol_generado/api/credit_notes_api.rb +79 -0
- data/lib/trevol_generado/api/debit_notes_api.rb +79 -0
- data/lib/trevol_generado/api/dian_documents_api.rb +8 -2
- data/lib/trevol_generado/api/dian_syncs_api.rb +2 -2
- data/lib/trevol_generado/api/equivalent_document_adjustments_api.rb +79 -0
- data/lib/trevol_generado/api/equivalent_documents_api.rb +79 -0
- data/lib/trevol_generado/api/invoices_api.rb +79 -0
- data/lib/trevol_generado/api/payroll_adjustments_api.rb +6 -0
- data/lib/trevol_generado/api/payrolls_api.rb +6 -0
- data/lib/trevol_generado/api/pdf_designs_api.rb +357 -0
- data/lib/trevol_generado/api/pdf_templates_api.rb +79 -0
- data/lib/trevol_generado/api/radian_events_api.rb +6 -0
- data/lib/trevol_generado/api/support_document_adjustments_api.rb +6 -0
- data/lib/trevol_generado/api/support_documents_api.rb +6 -0
- data/lib/trevol_generado/models/account_api_key_input.rb +1 -1
- data/lib/trevol_generado/models/account_company.rb +11 -1
- data/lib/trevol_generado/models/account_company_onboarding.rb +1 -1
- data/lib/trevol_generado/models/balance.rb +2 -2
- data/lib/trevol_generado/models/balance_operation_prices.rb +1 -1
- data/lib/trevol_generado/models/code_list.rb +245 -0
- data/lib/trevol_generado/models/code_list_entry.rb +353 -0
- data/lib/trevol_generado/models/code_list_entry_list.rb +191 -0
- data/lib/trevol_generado/models/code_list_list.rb +191 -0
- data/lib/trevol_generado/models/code_list_rates.rb +174 -0
- data/lib/trevol_generado/models/company.rb +11 -1
- data/lib/trevol_generado/models/company_logo.rb +217 -0
- data/lib/trevol_generado/models/company_logo_deleted.rb +170 -0
- data/lib/trevol_generado/models/company_logo_input.rb +178 -0
- data/lib/trevol_generado/models/delivery.rb +16 -5
- data/lib/trevol_generado/models/delivery_email_resends.rb +171 -0
- data/lib/trevol_generado/models/document.rb +37 -5
- data/lib/trevol_generado/models/document_totals_item.rb +1 -0
- data/lib/trevol_generado/models/email_resend.rb +256 -0
- data/lib/trevol_generado/models/email_resend_delivery.rb +183 -0
- data/lib/trevol_generado/models/email_resend_request.rb +163 -0
- data/lib/trevol_generado/models/email_resend_summary.rb +256 -0
- data/lib/trevol_generado/models/equivalent_document.rb +27 -5
- data/lib/trevol_generado/models/equivalent_document_adjustment.rb +26 -4
- data/lib/trevol_generado/models/equivalent_document_adjustment_input.rb +15 -4
- data/lib/trevol_generado/models/equivalent_document_input.rb +15 -4
- data/lib/trevol_generado/models/event.rb +12 -2
- data/lib/trevol_generado/models/invoice_batch.rb +11 -1
- data/lib/trevol_generado/models/invoice_batch_invoice_input.rb +24 -5
- data/lib/trevol_generado/models/invoice_input.rb +24 -4
- data/lib/trevol_generado/models/note_input.rb +15 -4
- data/lib/trevol_generado/models/numbering.rb +1 -1
- data/lib/trevol_generado/models/pdf_design.rb +297 -0
- data/lib/trevol_generado/models/pdf_design_applied.rb +193 -0
- data/lib/trevol_generado/models/pdf_design_input.rb +277 -0
- data/lib/trevol_generado/models/pdf_design_list.rb +191 -0
- data/lib/trevol_generado/models/pdf_design_update.rb +246 -0
- data/lib/trevol_generado/models/pdf_settings.rb +202 -0
- data/lib/trevol_generado/models/pdf_settings_update.rb +170 -0
- data/lib/trevol_generado/models/pdf_template.rb +210 -0
- data/lib/trevol_generado/models/pdf_template_list.rb +191 -0
- data/lib/trevol_generado/models/preview.rb +11 -1
- data/lib/trevol_generado/models/preview_numbering.rb +161 -0
- data/lib/trevol_generado/models/problem.rb +26 -4
- data/lib/trevol_generado/models/problem_finding.rb +172 -0
- data/lib/trevol_generado/models/support_document.rb +11 -1
- data/lib/trevol_generado/models/support_document_adjustment.rb +11 -1
- data/lib/trevol_generado/models/webhook_endpoint.rb +13 -3
- data/lib/trevol_generado/models/webhook_endpoint_input.rb +15 -5
- data/lib/trevol_generado/models/webhook_endpoint_update.rb +12 -2
- data/lib/trevol_generado/tablas.rb +30 -1
- data/lib/trevol_generado/version.rb +1 -1
- data/lib/trevol_generado.rb +28 -0
- metadata +29 -1
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#API de Trevol
|
|
3
|
+
|
|
4
|
+
#Trevol API. Documentación: https://platform.trevol.si/docs
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 2026-11-18
|
|
7
|
+
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.26.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
require 'time'
|
|
15
|
+
|
|
16
|
+
module TrevolGenerado
|
|
17
|
+
class EmailResendDelivery < ApiModelBase
|
|
18
|
+
# La dirección enmascarada; null sin `customers:read`.
|
|
19
|
+
attr_accessor :to
|
|
20
|
+
|
|
21
|
+
# `bounced` / `complained`: rebotó o se quejó después (a esa dirección no le volvemos a escribir). Valores conocidos: `sending`, `sent`, `failed`, `unconfirmed`, `bounced`, `complained`.
|
|
22
|
+
attr_accessor :status
|
|
23
|
+
|
|
24
|
+
# Un código si falló.
|
|
25
|
+
attr_accessor :detail
|
|
26
|
+
|
|
27
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
28
|
+
def self.attribute_map
|
|
29
|
+
{
|
|
30
|
+
:'to' => :'to',
|
|
31
|
+
:'status' => :'status',
|
|
32
|
+
:'detail' => :'detail'
|
|
33
|
+
}
|
|
34
|
+
end
|
|
35
|
+
|
|
36
|
+
# Returns attribute mapping this model knows about
|
|
37
|
+
def self.acceptable_attribute_map
|
|
38
|
+
attribute_map
|
|
39
|
+
end
|
|
40
|
+
|
|
41
|
+
# Returns all the JSON keys this model knows about
|
|
42
|
+
def self.acceptable_attributes
|
|
43
|
+
acceptable_attribute_map.values
|
|
44
|
+
end
|
|
45
|
+
|
|
46
|
+
# Attribute type mapping.
|
|
47
|
+
def self.openapi_types
|
|
48
|
+
{
|
|
49
|
+
:'to' => :'String',
|
|
50
|
+
:'status' => :'String',
|
|
51
|
+
:'detail' => :'String'
|
|
52
|
+
}
|
|
53
|
+
end
|
|
54
|
+
|
|
55
|
+
# List of attributes with nullable: true
|
|
56
|
+
def self.openapi_nullable
|
|
57
|
+
Set.new([
|
|
58
|
+
:'to',
|
|
59
|
+
:'detail'
|
|
60
|
+
])
|
|
61
|
+
end
|
|
62
|
+
|
|
63
|
+
# Returns attribute type mapping
|
|
64
|
+
def self.acceptable_openapi_types
|
|
65
|
+
openapi_types
|
|
66
|
+
end
|
|
67
|
+
|
|
68
|
+
# Returns the nullable attributes
|
|
69
|
+
def self.acceptable_openapi_nullable
|
|
70
|
+
openapi_nullable
|
|
71
|
+
end
|
|
72
|
+
|
|
73
|
+
# Initializes the object
|
|
74
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
75
|
+
def initialize(attributes = {})
|
|
76
|
+
if (!attributes.is_a?(Hash))
|
|
77
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `TrevolGenerado::EmailResendDelivery` initialize method"
|
|
78
|
+
end
|
|
79
|
+
|
|
80
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
81
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
82
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
83
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
84
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `TrevolGenerado::EmailResendDelivery`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
85
|
+
end
|
|
86
|
+
h[k.to_sym] = v
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
if attributes.key?(:'to')
|
|
90
|
+
self.to = attributes[:'to']
|
|
91
|
+
end
|
|
92
|
+
|
|
93
|
+
if attributes.key?(:'status')
|
|
94
|
+
self.status = attributes[:'status']
|
|
95
|
+
end
|
|
96
|
+
|
|
97
|
+
if attributes.key?(:'detail')
|
|
98
|
+
self.detail = attributes[:'detail']
|
|
99
|
+
end
|
|
100
|
+
end
|
|
101
|
+
|
|
102
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
103
|
+
# @return Array for valid properties with the reasons
|
|
104
|
+
def list_invalid_properties
|
|
105
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
106
|
+
invalid_properties = Array.new
|
|
107
|
+
invalid_properties
|
|
108
|
+
end
|
|
109
|
+
|
|
110
|
+
# Check to see if the all the properties in the model are valid
|
|
111
|
+
# @return true if the model is valid
|
|
112
|
+
def valid?
|
|
113
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
114
|
+
true
|
|
115
|
+
end
|
|
116
|
+
|
|
117
|
+
# Checks equality by comparing each attribute.
|
|
118
|
+
# @param [Object] Object to be compared
|
|
119
|
+
def ==(o)
|
|
120
|
+
return true if self.equal?(o)
|
|
121
|
+
self.class == o.class &&
|
|
122
|
+
to == o.to &&
|
|
123
|
+
status == o.status &&
|
|
124
|
+
detail == o.detail
|
|
125
|
+
end
|
|
126
|
+
|
|
127
|
+
# @see the `==` method
|
|
128
|
+
# @param [Object] Object to be compared
|
|
129
|
+
def eql?(o)
|
|
130
|
+
self == o
|
|
131
|
+
end
|
|
132
|
+
|
|
133
|
+
# Calculates hash code according to all attributes.
|
|
134
|
+
# @return [Integer] Hash code
|
|
135
|
+
def hash
|
|
136
|
+
[to, status, detail].hash
|
|
137
|
+
end
|
|
138
|
+
|
|
139
|
+
# Builds the object from hash
|
|
140
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
141
|
+
# @return [Object] Returns the model itself
|
|
142
|
+
def self.build_from_hash(attributes)
|
|
143
|
+
return nil unless attributes.is_a?(Hash)
|
|
144
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
145
|
+
# include attributes inherited from allOf parents (the nearest declaration wins)
|
|
146
|
+
map = acceptable_attribute_map
|
|
147
|
+
transformed_hash = {}
|
|
148
|
+
acceptable_openapi_types.each_pair do |key, type|
|
|
149
|
+
if attributes.key?(map[key]) && attributes[map[key]].nil?
|
|
150
|
+
transformed_hash["#{key}"] = nil
|
|
151
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
152
|
+
# check to ensure the input is an array given that the attribute
|
|
153
|
+
# is documented as an array but the input is not
|
|
154
|
+
if attributes[map[key]].is_a?(Array)
|
|
155
|
+
transformed_hash["#{key}"] = attributes[map[key]].map { |v| _deserialize($1, v) }
|
|
156
|
+
end
|
|
157
|
+
elsif !attributes[map[key]].nil?
|
|
158
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[map[key]])
|
|
159
|
+
end
|
|
160
|
+
end
|
|
161
|
+
new(transformed_hash)
|
|
162
|
+
end
|
|
163
|
+
|
|
164
|
+
# Returns the object in the form of hash
|
|
165
|
+
# @return [Hash] Returns the object in the form of hash
|
|
166
|
+
def to_hash
|
|
167
|
+
hash = {}
|
|
168
|
+
# include attributes inherited from allOf parents (the nearest declaration wins)
|
|
169
|
+
self.class.acceptable_attribute_map.each_pair do |attr, param|
|
|
170
|
+
value = self.send(attr)
|
|
171
|
+
if value.nil?
|
|
172
|
+
is_nullable = self.class.acceptable_openapi_nullable.include?(attr)
|
|
173
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
174
|
+
end
|
|
175
|
+
|
|
176
|
+
hash[param] = _to_hash(value)
|
|
177
|
+
end
|
|
178
|
+
hash
|
|
179
|
+
end
|
|
180
|
+
|
|
181
|
+
end
|
|
182
|
+
|
|
183
|
+
end
|
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#API de Trevol
|
|
3
|
+
|
|
4
|
+
#Trevol API. Documentación: https://platform.trevol.si/docs
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 2026-11-18
|
|
7
|
+
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.26.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
require 'time'
|
|
15
|
+
|
|
16
|
+
module TrevolGenerado
|
|
17
|
+
class EmailResendRequest < ApiModelBase
|
|
18
|
+
# Opcional. A quién reenviarlo en vez del comprador (1 a 3 direcciones en ASCII; un correo por destinatario; las repetidas, también si solo cambian mayúsculas, se juntan). Solo en producción y con el permiso `customers:read`.
|
|
19
|
+
attr_accessor :to
|
|
20
|
+
|
|
21
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
22
|
+
def self.attribute_map
|
|
23
|
+
{
|
|
24
|
+
:'to' => :'to'
|
|
25
|
+
}
|
|
26
|
+
end
|
|
27
|
+
|
|
28
|
+
# Returns attribute mapping this model knows about
|
|
29
|
+
def self.acceptable_attribute_map
|
|
30
|
+
attribute_map
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
# Returns all the JSON keys this model knows about
|
|
34
|
+
def self.acceptable_attributes
|
|
35
|
+
acceptable_attribute_map.values
|
|
36
|
+
end
|
|
37
|
+
|
|
38
|
+
# Attribute type mapping.
|
|
39
|
+
def self.openapi_types
|
|
40
|
+
{
|
|
41
|
+
:'to' => :'Array<String>'
|
|
42
|
+
}
|
|
43
|
+
end
|
|
44
|
+
|
|
45
|
+
# List of attributes with nullable: true
|
|
46
|
+
def self.openapi_nullable
|
|
47
|
+
Set.new([
|
|
48
|
+
])
|
|
49
|
+
end
|
|
50
|
+
|
|
51
|
+
# Returns attribute type mapping
|
|
52
|
+
def self.acceptable_openapi_types
|
|
53
|
+
openapi_types
|
|
54
|
+
end
|
|
55
|
+
|
|
56
|
+
# Returns the nullable attributes
|
|
57
|
+
def self.acceptable_openapi_nullable
|
|
58
|
+
openapi_nullable
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
# Initializes the object
|
|
62
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
63
|
+
def initialize(attributes = {})
|
|
64
|
+
if (!attributes.is_a?(Hash))
|
|
65
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `TrevolGenerado::EmailResendRequest` initialize method"
|
|
66
|
+
end
|
|
67
|
+
|
|
68
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
69
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
70
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
71
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
72
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `TrevolGenerado::EmailResendRequest`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
73
|
+
end
|
|
74
|
+
h[k.to_sym] = v
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
if attributes.key?(:'to')
|
|
78
|
+
if (value = attributes[:'to']).is_a?(Array)
|
|
79
|
+
self.to = value
|
|
80
|
+
end
|
|
81
|
+
end
|
|
82
|
+
end
|
|
83
|
+
|
|
84
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
85
|
+
# @return Array for valid properties with the reasons
|
|
86
|
+
def list_invalid_properties
|
|
87
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
88
|
+
invalid_properties = Array.new
|
|
89
|
+
invalid_properties
|
|
90
|
+
end
|
|
91
|
+
|
|
92
|
+
# Check to see if the all the properties in the model are valid
|
|
93
|
+
# @return true if the model is valid
|
|
94
|
+
def valid?
|
|
95
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
96
|
+
true
|
|
97
|
+
end
|
|
98
|
+
|
|
99
|
+
# Checks equality by comparing each attribute.
|
|
100
|
+
# @param [Object] Object to be compared
|
|
101
|
+
def ==(o)
|
|
102
|
+
return true if self.equal?(o)
|
|
103
|
+
self.class == o.class &&
|
|
104
|
+
to == o.to
|
|
105
|
+
end
|
|
106
|
+
|
|
107
|
+
# @see the `==` method
|
|
108
|
+
# @param [Object] Object to be compared
|
|
109
|
+
def eql?(o)
|
|
110
|
+
self == o
|
|
111
|
+
end
|
|
112
|
+
|
|
113
|
+
# Calculates hash code according to all attributes.
|
|
114
|
+
# @return [Integer] Hash code
|
|
115
|
+
def hash
|
|
116
|
+
[to].hash
|
|
117
|
+
end
|
|
118
|
+
|
|
119
|
+
# Builds the object from hash
|
|
120
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
121
|
+
# @return [Object] Returns the model itself
|
|
122
|
+
def self.build_from_hash(attributes)
|
|
123
|
+
return nil unless attributes.is_a?(Hash)
|
|
124
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
125
|
+
# include attributes inherited from allOf parents (the nearest declaration wins)
|
|
126
|
+
map = acceptable_attribute_map
|
|
127
|
+
transformed_hash = {}
|
|
128
|
+
acceptable_openapi_types.each_pair do |key, type|
|
|
129
|
+
if attributes.key?(map[key]) && attributes[map[key]].nil?
|
|
130
|
+
transformed_hash["#{key}"] = nil
|
|
131
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
132
|
+
# check to ensure the input is an array given that the attribute
|
|
133
|
+
# is documented as an array but the input is not
|
|
134
|
+
if attributes[map[key]].is_a?(Array)
|
|
135
|
+
transformed_hash["#{key}"] = attributes[map[key]].map { |v| _deserialize($1, v) }
|
|
136
|
+
end
|
|
137
|
+
elsif !attributes[map[key]].nil?
|
|
138
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[map[key]])
|
|
139
|
+
end
|
|
140
|
+
end
|
|
141
|
+
new(transformed_hash)
|
|
142
|
+
end
|
|
143
|
+
|
|
144
|
+
# Returns the object in the form of hash
|
|
145
|
+
# @return [Hash] Returns the object in the form of hash
|
|
146
|
+
def to_hash
|
|
147
|
+
hash = {}
|
|
148
|
+
# include attributes inherited from allOf parents (the nearest declaration wins)
|
|
149
|
+
self.class.acceptable_attribute_map.each_pair do |attr, param|
|
|
150
|
+
value = self.send(attr)
|
|
151
|
+
if value.nil?
|
|
152
|
+
is_nullable = self.class.acceptable_openapi_nullable.include?(attr)
|
|
153
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
154
|
+
end
|
|
155
|
+
|
|
156
|
+
hash[param] = _to_hash(value)
|
|
157
|
+
end
|
|
158
|
+
hash
|
|
159
|
+
end
|
|
160
|
+
|
|
161
|
+
end
|
|
162
|
+
|
|
163
|
+
end
|
|
@@ -0,0 +1,256 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#API de Trevol
|
|
3
|
+
|
|
4
|
+
#Trevol API. Documentación: https://platform.trevol.si/docs
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 2026-11-18
|
|
7
|
+
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.26.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
require 'time'
|
|
15
|
+
|
|
16
|
+
module TrevolGenerado
|
|
17
|
+
# El último reenvío, con el estado de cada destinatario al día: un rebote o una queja que llega después se ve aquí, en `deliveries[].status` (`bounced` / `complained`).
|
|
18
|
+
class EmailResendSummary < ApiModelBase
|
|
19
|
+
attr_accessor :id
|
|
20
|
+
|
|
21
|
+
# Valores conocidos: `email_resend`.
|
|
22
|
+
attr_accessor :object
|
|
23
|
+
|
|
24
|
+
# El documento (inv_…, cn_…, dn_…, pos_…, posa_…).
|
|
25
|
+
attr_accessor :document_id
|
|
26
|
+
|
|
27
|
+
# Valores conocidos: `credit_note`, `debit_note`, `equivalent_document`, `equivalent_document_adjustment`, `invoice`.
|
|
28
|
+
attr_accessor :document_object
|
|
29
|
+
|
|
30
|
+
# `customer`: el correo del comprador; `custom`: las direcciones de `to`; `issuer`: quien emitió (habilitación). Valores conocidos: `custom`, `customer`, `issuer`.
|
|
31
|
+
attr_accessor :recipient
|
|
32
|
+
|
|
33
|
+
# Las direcciones, enmascaradas (`c***@dominio.co`). null sin el permiso `customers:read`.
|
|
34
|
+
attr_accessor :to
|
|
35
|
+
|
|
36
|
+
# `sent`: salió a todos; `partially_sent`: a algunos; `failed`: a ninguno; `unconfirmed`: el envío se interrumpió y no sabemos si salió (no se repite solo); `sending`: todavía se está enviando. Valores conocidos: `sending`, `sent`, `partially_sent`, `failed`, `unconfirmed`.
|
|
37
|
+
attr_accessor :status
|
|
38
|
+
|
|
39
|
+
attr_accessor :created_at
|
|
40
|
+
|
|
41
|
+
attr_accessor :completed_at
|
|
42
|
+
|
|
43
|
+
# Una por destinatario, en el orden de `to`.
|
|
44
|
+
attr_accessor :deliveries
|
|
45
|
+
|
|
46
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
47
|
+
def self.attribute_map
|
|
48
|
+
{
|
|
49
|
+
:'id' => :'id',
|
|
50
|
+
:'object' => :'object',
|
|
51
|
+
:'document_id' => :'document_id',
|
|
52
|
+
:'document_object' => :'document_object',
|
|
53
|
+
:'recipient' => :'recipient',
|
|
54
|
+
:'to' => :'to',
|
|
55
|
+
:'status' => :'status',
|
|
56
|
+
:'created_at' => :'created_at',
|
|
57
|
+
:'completed_at' => :'completed_at',
|
|
58
|
+
:'deliveries' => :'deliveries'
|
|
59
|
+
}
|
|
60
|
+
end
|
|
61
|
+
|
|
62
|
+
# Returns attribute mapping this model knows about
|
|
63
|
+
def self.acceptable_attribute_map
|
|
64
|
+
attribute_map
|
|
65
|
+
end
|
|
66
|
+
|
|
67
|
+
# Returns all the JSON keys this model knows about
|
|
68
|
+
def self.acceptable_attributes
|
|
69
|
+
acceptable_attribute_map.values
|
|
70
|
+
end
|
|
71
|
+
|
|
72
|
+
# Attribute type mapping.
|
|
73
|
+
def self.openapi_types
|
|
74
|
+
{
|
|
75
|
+
:'id' => :'String',
|
|
76
|
+
:'object' => :'String',
|
|
77
|
+
:'document_id' => :'String',
|
|
78
|
+
:'document_object' => :'String',
|
|
79
|
+
:'recipient' => :'String',
|
|
80
|
+
:'to' => :'Array<String>',
|
|
81
|
+
:'status' => :'String',
|
|
82
|
+
:'created_at' => :'Time',
|
|
83
|
+
:'completed_at' => :'Time',
|
|
84
|
+
:'deliveries' => :'Array<EmailResendDelivery>'
|
|
85
|
+
}
|
|
86
|
+
end
|
|
87
|
+
|
|
88
|
+
# List of attributes with nullable: true
|
|
89
|
+
def self.openapi_nullable
|
|
90
|
+
Set.new([
|
|
91
|
+
:'to',
|
|
92
|
+
:'created_at',
|
|
93
|
+
:'completed_at',
|
|
94
|
+
])
|
|
95
|
+
end
|
|
96
|
+
|
|
97
|
+
# Returns attribute type mapping
|
|
98
|
+
def self.acceptable_openapi_types
|
|
99
|
+
openapi_types
|
|
100
|
+
end
|
|
101
|
+
|
|
102
|
+
# Returns the nullable attributes
|
|
103
|
+
def self.acceptable_openapi_nullable
|
|
104
|
+
openapi_nullable
|
|
105
|
+
end
|
|
106
|
+
|
|
107
|
+
# Initializes the object
|
|
108
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
109
|
+
def initialize(attributes = {})
|
|
110
|
+
if (!attributes.is_a?(Hash))
|
|
111
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `TrevolGenerado::EmailResendSummary` initialize method"
|
|
112
|
+
end
|
|
113
|
+
|
|
114
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
115
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
116
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
117
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
118
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `TrevolGenerado::EmailResendSummary`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
119
|
+
end
|
|
120
|
+
h[k.to_sym] = v
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
if attributes.key?(:'id')
|
|
124
|
+
self.id = attributes[:'id']
|
|
125
|
+
end
|
|
126
|
+
|
|
127
|
+
if attributes.key?(:'object')
|
|
128
|
+
self.object = attributes[:'object']
|
|
129
|
+
end
|
|
130
|
+
|
|
131
|
+
if attributes.key?(:'document_id')
|
|
132
|
+
self.document_id = attributes[:'document_id']
|
|
133
|
+
end
|
|
134
|
+
|
|
135
|
+
if attributes.key?(:'document_object')
|
|
136
|
+
self.document_object = attributes[:'document_object']
|
|
137
|
+
end
|
|
138
|
+
|
|
139
|
+
if attributes.key?(:'recipient')
|
|
140
|
+
self.recipient = attributes[:'recipient']
|
|
141
|
+
end
|
|
142
|
+
|
|
143
|
+
if attributes.key?(:'to')
|
|
144
|
+
if (value = attributes[:'to']).is_a?(Array)
|
|
145
|
+
self.to = value
|
|
146
|
+
end
|
|
147
|
+
end
|
|
148
|
+
|
|
149
|
+
if attributes.key?(:'status')
|
|
150
|
+
self.status = attributes[:'status']
|
|
151
|
+
end
|
|
152
|
+
|
|
153
|
+
if attributes.key?(:'created_at')
|
|
154
|
+
self.created_at = attributes[:'created_at']
|
|
155
|
+
end
|
|
156
|
+
|
|
157
|
+
if attributes.key?(:'completed_at')
|
|
158
|
+
self.completed_at = attributes[:'completed_at']
|
|
159
|
+
end
|
|
160
|
+
|
|
161
|
+
if attributes.key?(:'deliveries')
|
|
162
|
+
if (value = attributes[:'deliveries']).is_a?(Array)
|
|
163
|
+
self.deliveries = value
|
|
164
|
+
end
|
|
165
|
+
end
|
|
166
|
+
end
|
|
167
|
+
|
|
168
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
169
|
+
# @return Array for valid properties with the reasons
|
|
170
|
+
def list_invalid_properties
|
|
171
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
172
|
+
invalid_properties = Array.new
|
|
173
|
+
invalid_properties
|
|
174
|
+
end
|
|
175
|
+
|
|
176
|
+
# Check to see if the all the properties in the model are valid
|
|
177
|
+
# @return true if the model is valid
|
|
178
|
+
def valid?
|
|
179
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
180
|
+
true
|
|
181
|
+
end
|
|
182
|
+
|
|
183
|
+
# Checks equality by comparing each attribute.
|
|
184
|
+
# @param [Object] Object to be compared
|
|
185
|
+
def ==(o)
|
|
186
|
+
return true if self.equal?(o)
|
|
187
|
+
self.class == o.class &&
|
|
188
|
+
id == o.id &&
|
|
189
|
+
object == o.object &&
|
|
190
|
+
document_id == o.document_id &&
|
|
191
|
+
document_object == o.document_object &&
|
|
192
|
+
recipient == o.recipient &&
|
|
193
|
+
to == o.to &&
|
|
194
|
+
status == o.status &&
|
|
195
|
+
created_at == o.created_at &&
|
|
196
|
+
completed_at == o.completed_at &&
|
|
197
|
+
deliveries == o.deliveries
|
|
198
|
+
end
|
|
199
|
+
|
|
200
|
+
# @see the `==` method
|
|
201
|
+
# @param [Object] Object to be compared
|
|
202
|
+
def eql?(o)
|
|
203
|
+
self == o
|
|
204
|
+
end
|
|
205
|
+
|
|
206
|
+
# Calculates hash code according to all attributes.
|
|
207
|
+
# @return [Integer] Hash code
|
|
208
|
+
def hash
|
|
209
|
+
[id, object, document_id, document_object, recipient, to, status, created_at, completed_at, deliveries].hash
|
|
210
|
+
end
|
|
211
|
+
|
|
212
|
+
# Builds the object from hash
|
|
213
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
214
|
+
# @return [Object] Returns the model itself
|
|
215
|
+
def self.build_from_hash(attributes)
|
|
216
|
+
return nil unless attributes.is_a?(Hash)
|
|
217
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
218
|
+
# include attributes inherited from allOf parents (the nearest declaration wins)
|
|
219
|
+
map = acceptable_attribute_map
|
|
220
|
+
transformed_hash = {}
|
|
221
|
+
acceptable_openapi_types.each_pair do |key, type|
|
|
222
|
+
if attributes.key?(map[key]) && attributes[map[key]].nil?
|
|
223
|
+
transformed_hash["#{key}"] = nil
|
|
224
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
225
|
+
# check to ensure the input is an array given that the attribute
|
|
226
|
+
# is documented as an array but the input is not
|
|
227
|
+
if attributes[map[key]].is_a?(Array)
|
|
228
|
+
transformed_hash["#{key}"] = attributes[map[key]].map { |v| _deserialize($1, v) }
|
|
229
|
+
end
|
|
230
|
+
elsif !attributes[map[key]].nil?
|
|
231
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[map[key]])
|
|
232
|
+
end
|
|
233
|
+
end
|
|
234
|
+
new(transformed_hash)
|
|
235
|
+
end
|
|
236
|
+
|
|
237
|
+
# Returns the object in the form of hash
|
|
238
|
+
# @return [Hash] Returns the object in the form of hash
|
|
239
|
+
def to_hash
|
|
240
|
+
hash = {}
|
|
241
|
+
# include attributes inherited from allOf parents (the nearest declaration wins)
|
|
242
|
+
self.class.acceptable_attribute_map.each_pair do |attr, param|
|
|
243
|
+
value = self.send(attr)
|
|
244
|
+
if value.nil?
|
|
245
|
+
is_nullable = self.class.acceptable_openapi_nullable.include?(attr)
|
|
246
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
247
|
+
end
|
|
248
|
+
|
|
249
|
+
hash[param] = _to_hash(value)
|
|
250
|
+
end
|
|
251
|
+
hash
|
|
252
|
+
end
|
|
253
|
+
|
|
254
|
+
end
|
|
255
|
+
|
|
256
|
+
end
|
|
@@ -90,6 +90,12 @@ module TrevolGenerado
|
|
|
90
90
|
|
|
91
91
|
attr_accessor :contingency
|
|
92
92
|
|
|
93
|
+
# El que pidió el documento, o null.
|
|
94
|
+
attr_accessor :pdf_design_id
|
|
95
|
+
|
|
96
|
+
# El diseño fijado al emitir; null mientras está pendiente.
|
|
97
|
+
attr_accessor :pdf_design
|
|
98
|
+
|
|
93
99
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
94
100
|
def self.attribute_map
|
|
95
101
|
{
|
|
@@ -124,7 +130,9 @@ module TrevolGenerado
|
|
|
124
130
|
:'pos' => :'pos',
|
|
125
131
|
:'extension' => :'extension',
|
|
126
132
|
:'origin_note' => :'origin_note',
|
|
127
|
-
:'contingency' => :'contingency'
|
|
133
|
+
:'contingency' => :'contingency',
|
|
134
|
+
:'pdf_design_id' => :'pdf_design_id',
|
|
135
|
+
:'pdf_design' => :'pdf_design'
|
|
128
136
|
}
|
|
129
137
|
end
|
|
130
138
|
|
|
@@ -172,7 +180,9 @@ module TrevolGenerado
|
|
|
172
180
|
:'pos' => :'Pos',
|
|
173
181
|
:'extension' => :'Extension',
|
|
174
182
|
:'origin_note' => :'OriginNote',
|
|
175
|
-
:'contingency' => :'EquivalentDocumentContingency'
|
|
183
|
+
:'contingency' => :'EquivalentDocumentContingency',
|
|
184
|
+
:'pdf_design_id' => :'String',
|
|
185
|
+
:'pdf_design' => :'PdfDesignApplied'
|
|
176
186
|
}
|
|
177
187
|
end
|
|
178
188
|
|
|
@@ -188,7 +198,9 @@ module TrevolGenerado
|
|
|
188
198
|
:'totals',
|
|
189
199
|
:'updated_at',
|
|
190
200
|
:'rounding',
|
|
191
|
-
:'contingency'
|
|
201
|
+
:'contingency',
|
|
202
|
+
:'pdf_design_id',
|
|
203
|
+
:'pdf_design'
|
|
192
204
|
])
|
|
193
205
|
end
|
|
194
206
|
|
|
@@ -355,6 +367,14 @@ module TrevolGenerado
|
|
|
355
367
|
if attributes.key?(:'contingency')
|
|
356
368
|
self.contingency = attributes[:'contingency']
|
|
357
369
|
end
|
|
370
|
+
|
|
371
|
+
if attributes.key?(:'pdf_design_id')
|
|
372
|
+
self.pdf_design_id = attributes[:'pdf_design_id']
|
|
373
|
+
end
|
|
374
|
+
|
|
375
|
+
if attributes.key?(:'pdf_design')
|
|
376
|
+
self.pdf_design = attributes[:'pdf_design']
|
|
377
|
+
end
|
|
358
378
|
end
|
|
359
379
|
|
|
360
380
|
# Show invalid properties with the reasons. Usually used together with valid?
|
|
@@ -408,7 +428,9 @@ module TrevolGenerado
|
|
|
408
428
|
pos == o.pos &&
|
|
409
429
|
extension == o.extension &&
|
|
410
430
|
origin_note == o.origin_note &&
|
|
411
|
-
contingency == o.contingency
|
|
431
|
+
contingency == o.contingency &&
|
|
432
|
+
pdf_design_id == o.pdf_design_id &&
|
|
433
|
+
pdf_design == o.pdf_design
|
|
412
434
|
end
|
|
413
435
|
|
|
414
436
|
# @see the `==` method
|
|
@@ -420,7 +442,7 @@ module TrevolGenerado
|
|
|
420
442
|
# Calculates hash code according to all attributes.
|
|
421
443
|
# @return [Integer] Hash code
|
|
422
444
|
def hash
|
|
423
|
-
[id, object, environment, status, number, prefix, external_id, origin, cude, qr, issued_at, customer, items, payment, document_type, operation_type, totals, dian, delivery, created_at, updated_at, notes, period, references, allowance_charges, prepayments, rounding, withholdings, pos, extension, origin_note, contingency].hash
|
|
445
|
+
[id, object, environment, status, number, prefix, external_id, origin, cude, qr, issued_at, customer, items, payment, document_type, operation_type, totals, dian, delivery, created_at, updated_at, notes, period, references, allowance_charges, prepayments, rounding, withholdings, pos, extension, origin_note, contingency, pdf_design_id, pdf_design].hash
|
|
424
446
|
end
|
|
425
447
|
|
|
426
448
|
# Builds the object from hash
|