e-invoice-api 0.16.1 → 0.17.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 +28 -0
- data/README.md +10 -1
- data/lib/e_invoice_api/internal/util.rb +7 -2
- data/lib/e_invoice_api/models/document_type.rb +2 -0
- data/lib/e_invoice_api/models/inbox_list_credit_notes_params.rb +44 -1
- data/lib/e_invoice_api/models/inbox_list_invoices_params.rb +44 -1
- data/lib/e_invoice_api/models/inbox_list_params.rb +46 -3
- data/lib/e_invoice_api/models/outbox_list_draft_documents_params.rb +68 -1
- data/lib/e_invoice_api/models/outbox_list_received_documents_params.rb +60 -3
- data/lib/e_invoice_api/models/paginated_document_response.rb +7 -1
- data/lib/e_invoice_api/resources/documents.rb +3 -3
- data/lib/e_invoice_api/resources/inbox.rb +16 -4
- data/lib/e_invoice_api/resources/outbox.rb +24 -4
- data/lib/e_invoice_api/version.rb +1 -1
- data/rbi/e_invoice_api/models/document_type.rbi +4 -0
- data/rbi/e_invoice_api/models/inbox_list_credit_notes_params.rbi +132 -0
- data/rbi/e_invoice_api/models/inbox_list_invoices_params.rbi +126 -0
- data/rbi/e_invoice_api/models/inbox_list_params.rbi +99 -2
- data/rbi/e_invoice_api/models/outbox_list_draft_documents_params.rbi +163 -0
- data/rbi/e_invoice_api/models/outbox_list_received_documents_params.rbi +155 -2
- data/rbi/e_invoice_api/models/paginated_document_response.rbi +6 -1
- data/rbi/e_invoice_api/resources/documents.rbi +3 -3
- data/rbi/e_invoice_api/resources/inbox.rbi +20 -1
- data/rbi/e_invoice_api/resources/outbox.rbi +32 -2
- data/sig/e_invoice_api/models/document_type.rbs +8 -1
- data/sig/e_invoice_api/models/inbox_list_credit_notes_params.rbs +56 -1
- data/sig/e_invoice_api/models/inbox_list_invoices_params.rbs +56 -1
- data/sig/e_invoice_api/models/inbox_list_params.rbs +52 -0
- data/sig/e_invoice_api/models/outbox_list_draft_documents_params.rbs +71 -1
- data/sig/e_invoice_api/models/outbox_list_received_documents_params.rbs +57 -0
- data/sig/e_invoice_api/models/paginated_document_response.rbs +5 -0
- data/sig/e_invoice_api/resources/inbox.rbs +6 -0
- data/sig/e_invoice_api/resources/outbox.rbs +8 -0
- metadata +16 -2
|
@@ -28,10 +28,46 @@ module EInvoiceAPI
|
|
|
28
28
|
sig { params(page_size: Integer).void }
|
|
29
29
|
attr_writer :page_size
|
|
30
30
|
|
|
31
|
+
# Field to sort by
|
|
32
|
+
sig do
|
|
33
|
+
returns(
|
|
34
|
+
T.nilable(EInvoiceAPI::InboxListCreditNotesParams::SortBy::OrSymbol)
|
|
35
|
+
)
|
|
36
|
+
end
|
|
37
|
+
attr_reader :sort_by
|
|
38
|
+
|
|
39
|
+
sig do
|
|
40
|
+
params(
|
|
41
|
+
sort_by: EInvoiceAPI::InboxListCreditNotesParams::SortBy::OrSymbol
|
|
42
|
+
).void
|
|
43
|
+
end
|
|
44
|
+
attr_writer :sort_by
|
|
45
|
+
|
|
46
|
+
# Sort direction (asc/desc)
|
|
47
|
+
sig do
|
|
48
|
+
returns(
|
|
49
|
+
T.nilable(
|
|
50
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortOrder::OrSymbol
|
|
51
|
+
)
|
|
52
|
+
)
|
|
53
|
+
end
|
|
54
|
+
attr_reader :sort_order
|
|
55
|
+
|
|
56
|
+
sig do
|
|
57
|
+
params(
|
|
58
|
+
sort_order:
|
|
59
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortOrder::OrSymbol
|
|
60
|
+
).void
|
|
61
|
+
end
|
|
62
|
+
attr_writer :sort_order
|
|
63
|
+
|
|
31
64
|
sig do
|
|
32
65
|
params(
|
|
33
66
|
page: Integer,
|
|
34
67
|
page_size: Integer,
|
|
68
|
+
sort_by: EInvoiceAPI::InboxListCreditNotesParams::SortBy::OrSymbol,
|
|
69
|
+
sort_order:
|
|
70
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortOrder::OrSymbol,
|
|
35
71
|
request_options: EInvoiceAPI::RequestOptions::OrHash
|
|
36
72
|
).returns(T.attached_class)
|
|
37
73
|
end
|
|
@@ -40,6 +76,10 @@ module EInvoiceAPI
|
|
|
40
76
|
page: nil,
|
|
41
77
|
# Number of items per page
|
|
42
78
|
page_size: nil,
|
|
79
|
+
# Field to sort by
|
|
80
|
+
sort_by: nil,
|
|
81
|
+
# Sort direction (asc/desc)
|
|
82
|
+
sort_order: nil,
|
|
43
83
|
request_options: {}
|
|
44
84
|
)
|
|
45
85
|
end
|
|
@@ -49,12 +89,104 @@ module EInvoiceAPI
|
|
|
49
89
|
{
|
|
50
90
|
page: Integer,
|
|
51
91
|
page_size: Integer,
|
|
92
|
+
sort_by: EInvoiceAPI::InboxListCreditNotesParams::SortBy::OrSymbol,
|
|
93
|
+
sort_order:
|
|
94
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortOrder::OrSymbol,
|
|
52
95
|
request_options: EInvoiceAPI::RequestOptions
|
|
53
96
|
}
|
|
54
97
|
)
|
|
55
98
|
end
|
|
56
99
|
def to_hash
|
|
57
100
|
end
|
|
101
|
+
|
|
102
|
+
# Field to sort by
|
|
103
|
+
module SortBy
|
|
104
|
+
extend EInvoiceAPI::Internal::Type::Enum
|
|
105
|
+
|
|
106
|
+
TaggedSymbol =
|
|
107
|
+
T.type_alias do
|
|
108
|
+
T.all(Symbol, EInvoiceAPI::InboxListCreditNotesParams::SortBy)
|
|
109
|
+
end
|
|
110
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
111
|
+
|
|
112
|
+
CREATED_AT =
|
|
113
|
+
T.let(
|
|
114
|
+
:created_at,
|
|
115
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortBy::TaggedSymbol
|
|
116
|
+
)
|
|
117
|
+
INVOICE_DATE =
|
|
118
|
+
T.let(
|
|
119
|
+
:invoice_date,
|
|
120
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortBy::TaggedSymbol
|
|
121
|
+
)
|
|
122
|
+
DUE_DATE =
|
|
123
|
+
T.let(
|
|
124
|
+
:due_date,
|
|
125
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortBy::TaggedSymbol
|
|
126
|
+
)
|
|
127
|
+
INVOICE_TOTAL =
|
|
128
|
+
T.let(
|
|
129
|
+
:invoice_total,
|
|
130
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortBy::TaggedSymbol
|
|
131
|
+
)
|
|
132
|
+
CUSTOMER_NAME =
|
|
133
|
+
T.let(
|
|
134
|
+
:customer_name,
|
|
135
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortBy::TaggedSymbol
|
|
136
|
+
)
|
|
137
|
+
VENDOR_NAME =
|
|
138
|
+
T.let(
|
|
139
|
+
:vendor_name,
|
|
140
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortBy::TaggedSymbol
|
|
141
|
+
)
|
|
142
|
+
INVOICE_ID =
|
|
143
|
+
T.let(
|
|
144
|
+
:invoice_id,
|
|
145
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortBy::TaggedSymbol
|
|
146
|
+
)
|
|
147
|
+
|
|
148
|
+
sig do
|
|
149
|
+
override.returns(
|
|
150
|
+
T::Array[
|
|
151
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortBy::TaggedSymbol
|
|
152
|
+
]
|
|
153
|
+
)
|
|
154
|
+
end
|
|
155
|
+
def self.values
|
|
156
|
+
end
|
|
157
|
+
end
|
|
158
|
+
|
|
159
|
+
# Sort direction (asc/desc)
|
|
160
|
+
module SortOrder
|
|
161
|
+
extend EInvoiceAPI::Internal::Type::Enum
|
|
162
|
+
|
|
163
|
+
TaggedSymbol =
|
|
164
|
+
T.type_alias do
|
|
165
|
+
T.all(Symbol, EInvoiceAPI::InboxListCreditNotesParams::SortOrder)
|
|
166
|
+
end
|
|
167
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
168
|
+
|
|
169
|
+
ASC =
|
|
170
|
+
T.let(
|
|
171
|
+
:asc,
|
|
172
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortOrder::TaggedSymbol
|
|
173
|
+
)
|
|
174
|
+
DESC =
|
|
175
|
+
T.let(
|
|
176
|
+
:desc,
|
|
177
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortOrder::TaggedSymbol
|
|
178
|
+
)
|
|
179
|
+
|
|
180
|
+
sig do
|
|
181
|
+
override.returns(
|
|
182
|
+
T::Array[
|
|
183
|
+
EInvoiceAPI::InboxListCreditNotesParams::SortOrder::TaggedSymbol
|
|
184
|
+
]
|
|
185
|
+
)
|
|
186
|
+
end
|
|
187
|
+
def self.values
|
|
188
|
+
end
|
|
189
|
+
end
|
|
58
190
|
end
|
|
59
191
|
end
|
|
60
192
|
end
|
|
@@ -28,10 +28,42 @@ module EInvoiceAPI
|
|
|
28
28
|
sig { params(page_size: Integer).void }
|
|
29
29
|
attr_writer :page_size
|
|
30
30
|
|
|
31
|
+
# Field to sort by
|
|
32
|
+
sig do
|
|
33
|
+
returns(
|
|
34
|
+
T.nilable(EInvoiceAPI::InboxListInvoicesParams::SortBy::OrSymbol)
|
|
35
|
+
)
|
|
36
|
+
end
|
|
37
|
+
attr_reader :sort_by
|
|
38
|
+
|
|
39
|
+
sig do
|
|
40
|
+
params(
|
|
41
|
+
sort_by: EInvoiceAPI::InboxListInvoicesParams::SortBy::OrSymbol
|
|
42
|
+
).void
|
|
43
|
+
end
|
|
44
|
+
attr_writer :sort_by
|
|
45
|
+
|
|
46
|
+
# Sort direction (asc/desc)
|
|
47
|
+
sig do
|
|
48
|
+
returns(
|
|
49
|
+
T.nilable(EInvoiceAPI::InboxListInvoicesParams::SortOrder::OrSymbol)
|
|
50
|
+
)
|
|
51
|
+
end
|
|
52
|
+
attr_reader :sort_order
|
|
53
|
+
|
|
54
|
+
sig do
|
|
55
|
+
params(
|
|
56
|
+
sort_order: EInvoiceAPI::InboxListInvoicesParams::SortOrder::OrSymbol
|
|
57
|
+
).void
|
|
58
|
+
end
|
|
59
|
+
attr_writer :sort_order
|
|
60
|
+
|
|
31
61
|
sig do
|
|
32
62
|
params(
|
|
33
63
|
page: Integer,
|
|
34
64
|
page_size: Integer,
|
|
65
|
+
sort_by: EInvoiceAPI::InboxListInvoicesParams::SortBy::OrSymbol,
|
|
66
|
+
sort_order: EInvoiceAPI::InboxListInvoicesParams::SortOrder::OrSymbol,
|
|
35
67
|
request_options: EInvoiceAPI::RequestOptions::OrHash
|
|
36
68
|
).returns(T.attached_class)
|
|
37
69
|
end
|
|
@@ -40,6 +72,10 @@ module EInvoiceAPI
|
|
|
40
72
|
page: nil,
|
|
41
73
|
# Number of items per page
|
|
42
74
|
page_size: nil,
|
|
75
|
+
# Field to sort by
|
|
76
|
+
sort_by: nil,
|
|
77
|
+
# Sort direction (asc/desc)
|
|
78
|
+
sort_order: nil,
|
|
43
79
|
request_options: {}
|
|
44
80
|
)
|
|
45
81
|
end
|
|
@@ -49,12 +85,102 @@ module EInvoiceAPI
|
|
|
49
85
|
{
|
|
50
86
|
page: Integer,
|
|
51
87
|
page_size: Integer,
|
|
88
|
+
sort_by: EInvoiceAPI::InboxListInvoicesParams::SortBy::OrSymbol,
|
|
89
|
+
sort_order:
|
|
90
|
+
EInvoiceAPI::InboxListInvoicesParams::SortOrder::OrSymbol,
|
|
52
91
|
request_options: EInvoiceAPI::RequestOptions
|
|
53
92
|
}
|
|
54
93
|
)
|
|
55
94
|
end
|
|
56
95
|
def to_hash
|
|
57
96
|
end
|
|
97
|
+
|
|
98
|
+
# Field to sort by
|
|
99
|
+
module SortBy
|
|
100
|
+
extend EInvoiceAPI::Internal::Type::Enum
|
|
101
|
+
|
|
102
|
+
TaggedSymbol =
|
|
103
|
+
T.type_alias do
|
|
104
|
+
T.all(Symbol, EInvoiceAPI::InboxListInvoicesParams::SortBy)
|
|
105
|
+
end
|
|
106
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
107
|
+
|
|
108
|
+
CREATED_AT =
|
|
109
|
+
T.let(
|
|
110
|
+
:created_at,
|
|
111
|
+
EInvoiceAPI::InboxListInvoicesParams::SortBy::TaggedSymbol
|
|
112
|
+
)
|
|
113
|
+
INVOICE_DATE =
|
|
114
|
+
T.let(
|
|
115
|
+
:invoice_date,
|
|
116
|
+
EInvoiceAPI::InboxListInvoicesParams::SortBy::TaggedSymbol
|
|
117
|
+
)
|
|
118
|
+
DUE_DATE =
|
|
119
|
+
T.let(
|
|
120
|
+
:due_date,
|
|
121
|
+
EInvoiceAPI::InboxListInvoicesParams::SortBy::TaggedSymbol
|
|
122
|
+
)
|
|
123
|
+
INVOICE_TOTAL =
|
|
124
|
+
T.let(
|
|
125
|
+
:invoice_total,
|
|
126
|
+
EInvoiceAPI::InboxListInvoicesParams::SortBy::TaggedSymbol
|
|
127
|
+
)
|
|
128
|
+
CUSTOMER_NAME =
|
|
129
|
+
T.let(
|
|
130
|
+
:customer_name,
|
|
131
|
+
EInvoiceAPI::InboxListInvoicesParams::SortBy::TaggedSymbol
|
|
132
|
+
)
|
|
133
|
+
VENDOR_NAME =
|
|
134
|
+
T.let(
|
|
135
|
+
:vendor_name,
|
|
136
|
+
EInvoiceAPI::InboxListInvoicesParams::SortBy::TaggedSymbol
|
|
137
|
+
)
|
|
138
|
+
INVOICE_ID =
|
|
139
|
+
T.let(
|
|
140
|
+
:invoice_id,
|
|
141
|
+
EInvoiceAPI::InboxListInvoicesParams::SortBy::TaggedSymbol
|
|
142
|
+
)
|
|
143
|
+
|
|
144
|
+
sig do
|
|
145
|
+
override.returns(
|
|
146
|
+
T::Array[EInvoiceAPI::InboxListInvoicesParams::SortBy::TaggedSymbol]
|
|
147
|
+
)
|
|
148
|
+
end
|
|
149
|
+
def self.values
|
|
150
|
+
end
|
|
151
|
+
end
|
|
152
|
+
|
|
153
|
+
# Sort direction (asc/desc)
|
|
154
|
+
module SortOrder
|
|
155
|
+
extend EInvoiceAPI::Internal::Type::Enum
|
|
156
|
+
|
|
157
|
+
TaggedSymbol =
|
|
158
|
+
T.type_alias do
|
|
159
|
+
T.all(Symbol, EInvoiceAPI::InboxListInvoicesParams::SortOrder)
|
|
160
|
+
end
|
|
161
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
162
|
+
|
|
163
|
+
ASC =
|
|
164
|
+
T.let(
|
|
165
|
+
:asc,
|
|
166
|
+
EInvoiceAPI::InboxListInvoicesParams::SortOrder::TaggedSymbol
|
|
167
|
+
)
|
|
168
|
+
DESC =
|
|
169
|
+
T.let(
|
|
170
|
+
:desc,
|
|
171
|
+
EInvoiceAPI::InboxListInvoicesParams::SortOrder::TaggedSymbol
|
|
172
|
+
)
|
|
173
|
+
|
|
174
|
+
sig do
|
|
175
|
+
override.returns(
|
|
176
|
+
T::Array[
|
|
177
|
+
EInvoiceAPI::InboxListInvoicesParams::SortOrder::TaggedSymbol
|
|
178
|
+
]
|
|
179
|
+
)
|
|
180
|
+
end
|
|
181
|
+
def self.values
|
|
182
|
+
end
|
|
183
|
+
end
|
|
58
184
|
end
|
|
59
185
|
end
|
|
60
186
|
end
|
|
@@ -37,10 +37,32 @@ module EInvoiceAPI
|
|
|
37
37
|
sig { returns(T.nilable(String)) }
|
|
38
38
|
attr_accessor :search
|
|
39
39
|
|
|
40
|
-
# Filter by sender
|
|
40
|
+
# Filter by sender (vendor_name, vendor_email, vendor_tax_id, vendor_company_id)
|
|
41
41
|
sig { returns(T.nilable(String)) }
|
|
42
42
|
attr_accessor :sender
|
|
43
43
|
|
|
44
|
+
# Field to sort by
|
|
45
|
+
sig { returns(T.nilable(EInvoiceAPI::InboxListParams::SortBy::OrSymbol)) }
|
|
46
|
+
attr_reader :sort_by
|
|
47
|
+
|
|
48
|
+
sig do
|
|
49
|
+
params(sort_by: EInvoiceAPI::InboxListParams::SortBy::OrSymbol).void
|
|
50
|
+
end
|
|
51
|
+
attr_writer :sort_by
|
|
52
|
+
|
|
53
|
+
# Sort direction (asc/desc)
|
|
54
|
+
sig do
|
|
55
|
+
returns(T.nilable(EInvoiceAPI::InboxListParams::SortOrder::OrSymbol))
|
|
56
|
+
end
|
|
57
|
+
attr_reader :sort_order
|
|
58
|
+
|
|
59
|
+
sig do
|
|
60
|
+
params(
|
|
61
|
+
sort_order: EInvoiceAPI::InboxListParams::SortOrder::OrSymbol
|
|
62
|
+
).void
|
|
63
|
+
end
|
|
64
|
+
attr_writer :sort_order
|
|
65
|
+
|
|
44
66
|
# Filter by document state
|
|
45
67
|
sig { returns(T.nilable(EInvoiceAPI::DocumentState::OrSymbol)) }
|
|
46
68
|
attr_accessor :state
|
|
@@ -57,6 +79,8 @@ module EInvoiceAPI
|
|
|
57
79
|
page_size: Integer,
|
|
58
80
|
search: T.nilable(String),
|
|
59
81
|
sender: T.nilable(String),
|
|
82
|
+
sort_by: EInvoiceAPI::InboxListParams::SortBy::OrSymbol,
|
|
83
|
+
sort_order: EInvoiceAPI::InboxListParams::SortOrder::OrSymbol,
|
|
60
84
|
state: T.nilable(EInvoiceAPI::DocumentState::OrSymbol),
|
|
61
85
|
type: T.nilable(EInvoiceAPI::DocumentType::OrSymbol),
|
|
62
86
|
request_options: EInvoiceAPI::RequestOptions::OrHash
|
|
@@ -73,8 +97,12 @@ module EInvoiceAPI
|
|
|
73
97
|
page_size: nil,
|
|
74
98
|
# Search in invoice number, seller/buyer names
|
|
75
99
|
search: nil,
|
|
76
|
-
# Filter by sender
|
|
100
|
+
# Filter by sender (vendor_name, vendor_email, vendor_tax_id, vendor_company_id)
|
|
77
101
|
sender: nil,
|
|
102
|
+
# Field to sort by
|
|
103
|
+
sort_by: nil,
|
|
104
|
+
# Sort direction (asc/desc)
|
|
105
|
+
sort_order: nil,
|
|
78
106
|
# Filter by document state
|
|
79
107
|
state: nil,
|
|
80
108
|
# Filter by document type
|
|
@@ -92,6 +120,8 @@ module EInvoiceAPI
|
|
|
92
120
|
page_size: Integer,
|
|
93
121
|
search: T.nilable(String),
|
|
94
122
|
sender: T.nilable(String),
|
|
123
|
+
sort_by: EInvoiceAPI::InboxListParams::SortBy::OrSymbol,
|
|
124
|
+
sort_order: EInvoiceAPI::InboxListParams::SortOrder::OrSymbol,
|
|
95
125
|
state: T.nilable(EInvoiceAPI::DocumentState::OrSymbol),
|
|
96
126
|
type: T.nilable(EInvoiceAPI::DocumentType::OrSymbol),
|
|
97
127
|
request_options: EInvoiceAPI::RequestOptions
|
|
@@ -100,6 +130,73 @@ module EInvoiceAPI
|
|
|
100
130
|
end
|
|
101
131
|
def to_hash
|
|
102
132
|
end
|
|
133
|
+
|
|
134
|
+
# Field to sort by
|
|
135
|
+
module SortBy
|
|
136
|
+
extend EInvoiceAPI::Internal::Type::Enum
|
|
137
|
+
|
|
138
|
+
TaggedSymbol =
|
|
139
|
+
T.type_alias { T.all(Symbol, EInvoiceAPI::InboxListParams::SortBy) }
|
|
140
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
141
|
+
|
|
142
|
+
CREATED_AT =
|
|
143
|
+
T.let(:created_at, EInvoiceAPI::InboxListParams::SortBy::TaggedSymbol)
|
|
144
|
+
INVOICE_DATE =
|
|
145
|
+
T.let(
|
|
146
|
+
:invoice_date,
|
|
147
|
+
EInvoiceAPI::InboxListParams::SortBy::TaggedSymbol
|
|
148
|
+
)
|
|
149
|
+
DUE_DATE =
|
|
150
|
+
T.let(:due_date, EInvoiceAPI::InboxListParams::SortBy::TaggedSymbol)
|
|
151
|
+
INVOICE_TOTAL =
|
|
152
|
+
T.let(
|
|
153
|
+
:invoice_total,
|
|
154
|
+
EInvoiceAPI::InboxListParams::SortBy::TaggedSymbol
|
|
155
|
+
)
|
|
156
|
+
CUSTOMER_NAME =
|
|
157
|
+
T.let(
|
|
158
|
+
:customer_name,
|
|
159
|
+
EInvoiceAPI::InboxListParams::SortBy::TaggedSymbol
|
|
160
|
+
)
|
|
161
|
+
VENDOR_NAME =
|
|
162
|
+
T.let(
|
|
163
|
+
:vendor_name,
|
|
164
|
+
EInvoiceAPI::InboxListParams::SortBy::TaggedSymbol
|
|
165
|
+
)
|
|
166
|
+
INVOICE_ID =
|
|
167
|
+
T.let(:invoice_id, EInvoiceAPI::InboxListParams::SortBy::TaggedSymbol)
|
|
168
|
+
|
|
169
|
+
sig do
|
|
170
|
+
override.returns(
|
|
171
|
+
T::Array[EInvoiceAPI::InboxListParams::SortBy::TaggedSymbol]
|
|
172
|
+
)
|
|
173
|
+
end
|
|
174
|
+
def self.values
|
|
175
|
+
end
|
|
176
|
+
end
|
|
177
|
+
|
|
178
|
+
# Sort direction (asc/desc)
|
|
179
|
+
module SortOrder
|
|
180
|
+
extend EInvoiceAPI::Internal::Type::Enum
|
|
181
|
+
|
|
182
|
+
TaggedSymbol =
|
|
183
|
+
T.type_alias do
|
|
184
|
+
T.all(Symbol, EInvoiceAPI::InboxListParams::SortOrder)
|
|
185
|
+
end
|
|
186
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
187
|
+
|
|
188
|
+
ASC = T.let(:asc, EInvoiceAPI::InboxListParams::SortOrder::TaggedSymbol)
|
|
189
|
+
DESC =
|
|
190
|
+
T.let(:desc, EInvoiceAPI::InboxListParams::SortOrder::TaggedSymbol)
|
|
191
|
+
|
|
192
|
+
sig do
|
|
193
|
+
override.returns(
|
|
194
|
+
T::Array[EInvoiceAPI::InboxListParams::SortOrder::TaggedSymbol]
|
|
195
|
+
)
|
|
196
|
+
end
|
|
197
|
+
def self.values
|
|
198
|
+
end
|
|
199
|
+
end
|
|
103
200
|
end
|
|
104
201
|
end
|
|
105
202
|
end
|
|
@@ -28,10 +28,64 @@ module EInvoiceAPI
|
|
|
28
28
|
sig { params(page_size: Integer).void }
|
|
29
29
|
attr_writer :page_size
|
|
30
30
|
|
|
31
|
+
# Search in invoice number, seller/buyer names
|
|
32
|
+
sig { returns(T.nilable(String)) }
|
|
33
|
+
attr_accessor :search
|
|
34
|
+
|
|
35
|
+
# Field to sort by
|
|
36
|
+
sig do
|
|
37
|
+
returns(
|
|
38
|
+
T.nilable(
|
|
39
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortBy::OrSymbol
|
|
40
|
+
)
|
|
41
|
+
)
|
|
42
|
+
end
|
|
43
|
+
attr_reader :sort_by
|
|
44
|
+
|
|
45
|
+
sig do
|
|
46
|
+
params(
|
|
47
|
+
sort_by: EInvoiceAPI::OutboxListDraftDocumentsParams::SortBy::OrSymbol
|
|
48
|
+
).void
|
|
49
|
+
end
|
|
50
|
+
attr_writer :sort_by
|
|
51
|
+
|
|
52
|
+
# Sort direction (asc/desc)
|
|
53
|
+
sig do
|
|
54
|
+
returns(
|
|
55
|
+
T.nilable(
|
|
56
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortOrder::OrSymbol
|
|
57
|
+
)
|
|
58
|
+
)
|
|
59
|
+
end
|
|
60
|
+
attr_reader :sort_order
|
|
61
|
+
|
|
62
|
+
sig do
|
|
63
|
+
params(
|
|
64
|
+
sort_order:
|
|
65
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortOrder::OrSymbol
|
|
66
|
+
).void
|
|
67
|
+
end
|
|
68
|
+
attr_writer :sort_order
|
|
69
|
+
|
|
70
|
+
# Filter by document state
|
|
71
|
+
sig { returns(T.nilable(EInvoiceAPI::DocumentState::OrSymbol)) }
|
|
72
|
+
attr_accessor :state
|
|
73
|
+
|
|
74
|
+
# Filter by document type
|
|
75
|
+
sig { returns(T.nilable(EInvoiceAPI::DocumentType::OrSymbol)) }
|
|
76
|
+
attr_accessor :type
|
|
77
|
+
|
|
31
78
|
sig do
|
|
32
79
|
params(
|
|
33
80
|
page: Integer,
|
|
34
81
|
page_size: Integer,
|
|
82
|
+
search: T.nilable(String),
|
|
83
|
+
sort_by:
|
|
84
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortBy::OrSymbol,
|
|
85
|
+
sort_order:
|
|
86
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortOrder::OrSymbol,
|
|
87
|
+
state: T.nilable(EInvoiceAPI::DocumentState::OrSymbol),
|
|
88
|
+
type: T.nilable(EInvoiceAPI::DocumentType::OrSymbol),
|
|
35
89
|
request_options: EInvoiceAPI::RequestOptions::OrHash
|
|
36
90
|
).returns(T.attached_class)
|
|
37
91
|
end
|
|
@@ -40,6 +94,16 @@ module EInvoiceAPI
|
|
|
40
94
|
page: nil,
|
|
41
95
|
# Number of items per page
|
|
42
96
|
page_size: nil,
|
|
97
|
+
# Search in invoice number, seller/buyer names
|
|
98
|
+
search: nil,
|
|
99
|
+
# Field to sort by
|
|
100
|
+
sort_by: nil,
|
|
101
|
+
# Sort direction (asc/desc)
|
|
102
|
+
sort_order: nil,
|
|
103
|
+
# Filter by document state
|
|
104
|
+
state: nil,
|
|
105
|
+
# Filter by document type
|
|
106
|
+
type: nil,
|
|
43
107
|
request_options: {}
|
|
44
108
|
)
|
|
45
109
|
end
|
|
@@ -49,12 +113,111 @@ module EInvoiceAPI
|
|
|
49
113
|
{
|
|
50
114
|
page: Integer,
|
|
51
115
|
page_size: Integer,
|
|
116
|
+
search: T.nilable(String),
|
|
117
|
+
sort_by:
|
|
118
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortBy::OrSymbol,
|
|
119
|
+
sort_order:
|
|
120
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortOrder::OrSymbol,
|
|
121
|
+
state: T.nilable(EInvoiceAPI::DocumentState::OrSymbol),
|
|
122
|
+
type: T.nilable(EInvoiceAPI::DocumentType::OrSymbol),
|
|
52
123
|
request_options: EInvoiceAPI::RequestOptions
|
|
53
124
|
}
|
|
54
125
|
)
|
|
55
126
|
end
|
|
56
127
|
def to_hash
|
|
57
128
|
end
|
|
129
|
+
|
|
130
|
+
# Field to sort by
|
|
131
|
+
module SortBy
|
|
132
|
+
extend EInvoiceAPI::Internal::Type::Enum
|
|
133
|
+
|
|
134
|
+
TaggedSymbol =
|
|
135
|
+
T.type_alias do
|
|
136
|
+
T.all(Symbol, EInvoiceAPI::OutboxListDraftDocumentsParams::SortBy)
|
|
137
|
+
end
|
|
138
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
139
|
+
|
|
140
|
+
CREATED_AT =
|
|
141
|
+
T.let(
|
|
142
|
+
:created_at,
|
|
143
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortBy::TaggedSymbol
|
|
144
|
+
)
|
|
145
|
+
INVOICE_DATE =
|
|
146
|
+
T.let(
|
|
147
|
+
:invoice_date,
|
|
148
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortBy::TaggedSymbol
|
|
149
|
+
)
|
|
150
|
+
DUE_DATE =
|
|
151
|
+
T.let(
|
|
152
|
+
:due_date,
|
|
153
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortBy::TaggedSymbol
|
|
154
|
+
)
|
|
155
|
+
INVOICE_TOTAL =
|
|
156
|
+
T.let(
|
|
157
|
+
:invoice_total,
|
|
158
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortBy::TaggedSymbol
|
|
159
|
+
)
|
|
160
|
+
CUSTOMER_NAME =
|
|
161
|
+
T.let(
|
|
162
|
+
:customer_name,
|
|
163
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortBy::TaggedSymbol
|
|
164
|
+
)
|
|
165
|
+
VENDOR_NAME =
|
|
166
|
+
T.let(
|
|
167
|
+
:vendor_name,
|
|
168
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortBy::TaggedSymbol
|
|
169
|
+
)
|
|
170
|
+
INVOICE_ID =
|
|
171
|
+
T.let(
|
|
172
|
+
:invoice_id,
|
|
173
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortBy::TaggedSymbol
|
|
174
|
+
)
|
|
175
|
+
|
|
176
|
+
sig do
|
|
177
|
+
override.returns(
|
|
178
|
+
T::Array[
|
|
179
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortBy::TaggedSymbol
|
|
180
|
+
]
|
|
181
|
+
)
|
|
182
|
+
end
|
|
183
|
+
def self.values
|
|
184
|
+
end
|
|
185
|
+
end
|
|
186
|
+
|
|
187
|
+
# Sort direction (asc/desc)
|
|
188
|
+
module SortOrder
|
|
189
|
+
extend EInvoiceAPI::Internal::Type::Enum
|
|
190
|
+
|
|
191
|
+
TaggedSymbol =
|
|
192
|
+
T.type_alias do
|
|
193
|
+
T.all(
|
|
194
|
+
Symbol,
|
|
195
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortOrder
|
|
196
|
+
)
|
|
197
|
+
end
|
|
198
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
199
|
+
|
|
200
|
+
ASC =
|
|
201
|
+
T.let(
|
|
202
|
+
:asc,
|
|
203
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortOrder::TaggedSymbol
|
|
204
|
+
)
|
|
205
|
+
DESC =
|
|
206
|
+
T.let(
|
|
207
|
+
:desc,
|
|
208
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortOrder::TaggedSymbol
|
|
209
|
+
)
|
|
210
|
+
|
|
211
|
+
sig do
|
|
212
|
+
override.returns(
|
|
213
|
+
T::Array[
|
|
214
|
+
EInvoiceAPI::OutboxListDraftDocumentsParams::SortOrder::TaggedSymbol
|
|
215
|
+
]
|
|
216
|
+
)
|
|
217
|
+
end
|
|
218
|
+
def self.values
|
|
219
|
+
end
|
|
220
|
+
end
|
|
58
221
|
end
|
|
59
222
|
end
|
|
60
223
|
end
|