yoomoney 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 +8 -0
- data/README.md +1 -1
- data/lib/yoomoney/models/airline.rb +50 -6
- data/lib/yoomoney/models/receipt_create_params.rb +120 -2
- data/lib/yoomoney/models/receipt_data.rb +123 -3
- data/lib/yoomoney/models.rb +0 -6
- data/lib/yoomoney/version.rb +1 -1
- data/lib/yoomoney.rb +0 -3
- data/rbi/yoomoney/models/airline.rbi +84 -8
- data/rbi/yoomoney/models/receipt_create_params.rbi +159 -1
- data/rbi/yoomoney/models/receipt_data.rbi +185 -3
- data/rbi/yoomoney/models.rbi +0 -6
- data/sig/yoomoney/models/airline.rbs +58 -12
- data/sig/yoomoney/models/receipt_create_params.rbs +119 -7
- data/sig/yoomoney/models/receipt_data.rbs +128 -4
- data/sig/yoomoney/models.rbs +0 -6
- metadata +1 -10
- data/lib/yoomoney/models/airline_leg.rb +0 -33
- data/lib/yoomoney/models/airline_passenger.rb +0 -21
- data/lib/yoomoney/models/receipt_data_item.rb +0 -125
- data/rbi/yoomoney/models/airline_leg.rbi +0 -56
- data/rbi/yoomoney/models/airline_passenger.rbi +0 -28
- data/rbi/yoomoney/models/receipt_data_item.rbi +0 -185
- data/sig/yoomoney/models/airline_leg.rbs +0 -37
- data/sig/yoomoney/models/airline_passenger.rbs +0 -15
- data/sig/yoomoney/models/receipt_data_item.rbs +0 -127
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 7fc7cc115fd073113e5c5ddd6f74a1dc490e0eb17283cdc0ead7e84fff2c8c28
|
|
4
|
+
data.tar.gz: 758d082193bdc8e9927eab64242366e627b9f6ab180041d7805ee0ef0ab9ce5b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 5499ebb0a382b81f5e8ac81aa2c4b926e52745dc9f162418f00939eefb0ca71db17dfcf8d7277f22dec6145224eafc61294b011e7f2443d17290124672ec5731
|
|
7
|
+
data.tar.gz: 43206f99994d0cb058341d71613ba1a935cd62980a5d9004cf0240ae42d065d8df0de61a7cc87e89058748d66b5c2d97ae5b80e2e04b714d4c6ecac2abc8422c
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.4.0 (2026-02-19)
|
|
4
|
+
|
|
5
|
+
Full Changelog: [v0.3.0...v0.4.0](https://github.com/Hexlet/yoomoney-ruby/compare/v0.3.0...v0.4.0)
|
|
6
|
+
|
|
7
|
+
### Features
|
|
8
|
+
|
|
9
|
+
* **api:** api update ([c792fd8](https://github.com/Hexlet/yoomoney-ruby/commit/c792fd813fb0c1937753a2deda1c1d763af4081d))
|
|
10
|
+
|
|
3
11
|
## 0.3.0 (2026-02-19)
|
|
4
12
|
|
|
5
13
|
Full Changelog: [v0.2.0...v0.3.0](https://github.com/Hexlet/yoomoney-ruby/compare/v0.2.0...v0.3.0)
|
data/README.md
CHANGED
|
@@ -10,13 +10,13 @@ module Yoomoney
|
|
|
10
10
|
|
|
11
11
|
# @!attribute legs
|
|
12
12
|
#
|
|
13
|
-
# @return [Array<Yoomoney::Models::
|
|
14
|
-
optional :legs, -> { Yoomoney::Internal::Type::ArrayOf[Yoomoney::
|
|
13
|
+
# @return [Array<Yoomoney::Models::Airline::Leg>, nil]
|
|
14
|
+
optional :legs, -> { Yoomoney::Internal::Type::ArrayOf[Yoomoney::Airline::Leg] }
|
|
15
15
|
|
|
16
16
|
# @!attribute passengers
|
|
17
17
|
#
|
|
18
|
-
# @return [Array<Yoomoney::Models::
|
|
19
|
-
optional :passengers, -> { Yoomoney::Internal::Type::ArrayOf[Yoomoney::
|
|
18
|
+
# @return [Array<Yoomoney::Models::Airline::Passenger>, nil]
|
|
19
|
+
optional :passengers, -> { Yoomoney::Internal::Type::ArrayOf[Yoomoney::Airline::Passenger] }
|
|
20
20
|
|
|
21
21
|
# @!attribute ticket_number
|
|
22
22
|
#
|
|
@@ -25,9 +25,53 @@ module Yoomoney
|
|
|
25
25
|
|
|
26
26
|
# @!method initialize(booking_reference: nil, legs: nil, passengers: nil, ticket_number: nil)
|
|
27
27
|
# @param booking_reference [String]
|
|
28
|
-
# @param legs [Array<Yoomoney::Models::
|
|
29
|
-
# @param passengers [Array<Yoomoney::Models::
|
|
28
|
+
# @param legs [Array<Yoomoney::Models::Airline::Leg>]
|
|
29
|
+
# @param passengers [Array<Yoomoney::Models::Airline::Passenger>]
|
|
30
30
|
# @param ticket_number [String]
|
|
31
|
+
|
|
32
|
+
class Leg < Yoomoney::Internal::Type::BaseModel
|
|
33
|
+
# @!attribute departure_airport
|
|
34
|
+
#
|
|
35
|
+
# @return [String]
|
|
36
|
+
required :departure_airport, String
|
|
37
|
+
|
|
38
|
+
# @!attribute departure_date
|
|
39
|
+
#
|
|
40
|
+
# @return [String]
|
|
41
|
+
required :departure_date, String
|
|
42
|
+
|
|
43
|
+
# @!attribute destination_airport
|
|
44
|
+
#
|
|
45
|
+
# @return [String]
|
|
46
|
+
required :destination_airport, String
|
|
47
|
+
|
|
48
|
+
# @!attribute carrier_code
|
|
49
|
+
#
|
|
50
|
+
# @return [String, nil]
|
|
51
|
+
optional :carrier_code, String
|
|
52
|
+
|
|
53
|
+
# @!method initialize(departure_airport:, departure_date:, destination_airport:, carrier_code: nil)
|
|
54
|
+
# @param departure_airport [String]
|
|
55
|
+
# @param departure_date [String]
|
|
56
|
+
# @param destination_airport [String]
|
|
57
|
+
# @param carrier_code [String]
|
|
58
|
+
end
|
|
59
|
+
|
|
60
|
+
class Passenger < Yoomoney::Internal::Type::BaseModel
|
|
61
|
+
# @!attribute first_name
|
|
62
|
+
#
|
|
63
|
+
# @return [String]
|
|
64
|
+
required :first_name, String
|
|
65
|
+
|
|
66
|
+
# @!attribute last_name
|
|
67
|
+
#
|
|
68
|
+
# @return [String]
|
|
69
|
+
required :last_name, String
|
|
70
|
+
|
|
71
|
+
# @!method initialize(first_name:, last_name:)
|
|
72
|
+
# @param first_name [String]
|
|
73
|
+
# @param last_name [String]
|
|
74
|
+
end
|
|
31
75
|
end
|
|
32
76
|
end
|
|
33
77
|
end
|
|
@@ -129,7 +129,31 @@ module Yoomoney
|
|
|
129
129
|
#
|
|
130
130
|
# @param request_options [Yoomoney::RequestOptions, Hash{Symbol=>Object}]
|
|
131
131
|
|
|
132
|
-
class Item < Yoomoney::
|
|
132
|
+
class Item < Yoomoney::Internal::Type::BaseModel
|
|
133
|
+
# @!attribute amount
|
|
134
|
+
# Сумма.
|
|
135
|
+
#
|
|
136
|
+
# @return [Yoomoney::Models::MonetaryAmount]
|
|
137
|
+
required :amount, -> { Yoomoney::MonetaryAmount }
|
|
138
|
+
|
|
139
|
+
# @!attribute description
|
|
140
|
+
# Название товара.
|
|
141
|
+
#
|
|
142
|
+
# @return [String]
|
|
143
|
+
required :description, String
|
|
144
|
+
|
|
145
|
+
# @!attribute quantity
|
|
146
|
+
# Количество.
|
|
147
|
+
#
|
|
148
|
+
# @return [Float]
|
|
149
|
+
required :quantity, Float
|
|
150
|
+
|
|
151
|
+
# @!attribute vat_code
|
|
152
|
+
# Ставка НДС.
|
|
153
|
+
#
|
|
154
|
+
# @return [Integer]
|
|
155
|
+
required :vat_code, Integer
|
|
156
|
+
|
|
133
157
|
# @!attribute additional_payment_subject_props
|
|
134
158
|
# Дополнительный реквизит предмета расчета.
|
|
135
159
|
#
|
|
@@ -141,18 +165,112 @@ module Yoomoney
|
|
|
141
165
|
# @return [Symbol, Yoomoney::Models::ReceiptItemAgentType, nil]
|
|
142
166
|
optional :agent_type, enum: -> { Yoomoney::ReceiptItemAgentType }
|
|
143
167
|
|
|
168
|
+
# @!attribute country_of_origin_code
|
|
169
|
+
#
|
|
170
|
+
# @return [String, nil]
|
|
171
|
+
optional :country_of_origin_code, String
|
|
172
|
+
|
|
173
|
+
# @!attribute customs_declaration_number
|
|
174
|
+
#
|
|
175
|
+
# @return [String, nil]
|
|
176
|
+
optional :customs_declaration_number, String
|
|
177
|
+
|
|
178
|
+
# @!attribute excise
|
|
179
|
+
#
|
|
180
|
+
# @return [String, nil]
|
|
181
|
+
optional :excise, String
|
|
182
|
+
|
|
183
|
+
# @!attribute mark_code_info
|
|
184
|
+
#
|
|
185
|
+
# @return [Yoomoney::Models::MarkCodeInfo, nil]
|
|
186
|
+
optional :mark_code_info, -> { Yoomoney::MarkCodeInfo }
|
|
187
|
+
|
|
188
|
+
# @!attribute mark_mode
|
|
189
|
+
#
|
|
190
|
+
# @return [String, nil]
|
|
191
|
+
optional :mark_mode, String
|
|
192
|
+
|
|
193
|
+
# @!attribute mark_quantity
|
|
194
|
+
#
|
|
195
|
+
# @return [Yoomoney::Models::MarkQuantity, nil]
|
|
196
|
+
optional :mark_quantity, -> { Yoomoney::MarkQuantity }
|
|
197
|
+
|
|
198
|
+
# @!attribute measure
|
|
199
|
+
#
|
|
200
|
+
# @return [Symbol, Yoomoney::Models::ReceiptItemMeasure, nil]
|
|
201
|
+
optional :measure, enum: -> { Yoomoney::ReceiptItemMeasure }
|
|
202
|
+
|
|
203
|
+
# @!attribute payment_mode
|
|
204
|
+
#
|
|
205
|
+
# @return [Symbol, Yoomoney::Models::ReceiptItemPaymentMode, nil]
|
|
206
|
+
optional :payment_mode, enum: -> { Yoomoney::ReceiptItemPaymentMode }
|
|
207
|
+
|
|
208
|
+
# @!attribute payment_subject
|
|
209
|
+
#
|
|
210
|
+
# @return [Symbol, Yoomoney::Models::ReceiptItemPaymentSubject, nil]
|
|
211
|
+
optional :payment_subject, enum: -> { Yoomoney::ReceiptItemPaymentSubject }
|
|
212
|
+
|
|
213
|
+
# @!attribute payment_subject_industry_details
|
|
214
|
+
#
|
|
215
|
+
# @return [Array<Yoomoney::Models::IndustryDetails>, nil]
|
|
216
|
+
optional :payment_subject_industry_details,
|
|
217
|
+
-> { Yoomoney::Internal::Type::ArrayOf[Yoomoney::IndustryDetails] }
|
|
218
|
+
|
|
219
|
+
# @!attribute planned_status
|
|
220
|
+
#
|
|
221
|
+
# @return [Integer, nil]
|
|
222
|
+
optional :planned_status, Integer
|
|
223
|
+
|
|
224
|
+
# @!attribute product_code
|
|
225
|
+
#
|
|
226
|
+
# @return [String, nil]
|
|
227
|
+
optional :product_code, String
|
|
228
|
+
|
|
144
229
|
# @!attribute supplier
|
|
145
230
|
#
|
|
146
231
|
# @return [Yoomoney::Models::ReceiptCreateParams::Item::Supplier, nil]
|
|
147
232
|
optional :supplier, -> { Yoomoney::ReceiptCreateParams::Item::Supplier }
|
|
148
233
|
|
|
149
|
-
# @!method initialize(additional_payment_subject_props: nil, agent_type: nil, supplier: nil)
|
|
234
|
+
# @!method initialize(amount:, description:, quantity:, vat_code:, additional_payment_subject_props: nil, agent_type: nil, country_of_origin_code: nil, customs_declaration_number: nil, excise: nil, mark_code_info: nil, mark_mode: nil, mark_quantity: nil, measure: nil, payment_mode: nil, payment_subject: nil, payment_subject_industry_details: nil, planned_status: nil, product_code: nil, supplier: nil)
|
|
235
|
+
# @param amount [Yoomoney::Models::MonetaryAmount] Сумма.
|
|
236
|
+
#
|
|
237
|
+
# @param description [String] Название товара.
|
|
238
|
+
#
|
|
239
|
+
# @param quantity [Float] Количество.
|
|
240
|
+
#
|
|
241
|
+
# @param vat_code [Integer] Ставка НДС.
|
|
242
|
+
#
|
|
150
243
|
# @param additional_payment_subject_props [String] Дополнительный реквизит предмета расчета.
|
|
151
244
|
#
|
|
152
245
|
# @param agent_type [Symbol, Yoomoney::Models::ReceiptItemAgentType]
|
|
153
246
|
#
|
|
247
|
+
# @param country_of_origin_code [String]
|
|
248
|
+
#
|
|
249
|
+
# @param customs_declaration_number [String]
|
|
250
|
+
#
|
|
251
|
+
# @param excise [String]
|
|
252
|
+
#
|
|
253
|
+
# @param mark_code_info [Yoomoney::Models::MarkCodeInfo]
|
|
254
|
+
#
|
|
255
|
+
# @param mark_mode [String]
|
|
256
|
+
#
|
|
257
|
+
# @param mark_quantity [Yoomoney::Models::MarkQuantity]
|
|
258
|
+
#
|
|
259
|
+
# @param measure [Symbol, Yoomoney::Models::ReceiptItemMeasure]
|
|
260
|
+
#
|
|
261
|
+
# @param payment_mode [Symbol, Yoomoney::Models::ReceiptItemPaymentMode]
|
|
262
|
+
#
|
|
263
|
+
# @param payment_subject [Symbol, Yoomoney::Models::ReceiptItemPaymentSubject]
|
|
264
|
+
#
|
|
265
|
+
# @param payment_subject_industry_details [Array<Yoomoney::Models::IndustryDetails>]
|
|
266
|
+
#
|
|
267
|
+
# @param planned_status [Integer]
|
|
268
|
+
#
|
|
269
|
+
# @param product_code [String]
|
|
270
|
+
#
|
|
154
271
|
# @param supplier [Yoomoney::Models::ReceiptCreateParams::Item::Supplier]
|
|
155
272
|
|
|
273
|
+
# @see Yoomoney::Models::ReceiptCreateParams::Item#supplier
|
|
156
274
|
class Supplier < Yoomoney::Models::ReceiptItemSupplier
|
|
157
275
|
# @!attribute inn
|
|
158
276
|
#
|
|
@@ -5,8 +5,8 @@ module Yoomoney
|
|
|
5
5
|
class ReceiptData < Yoomoney::Internal::Type::BaseModel
|
|
6
6
|
# @!attribute items
|
|
7
7
|
#
|
|
8
|
-
# @return [Array<Yoomoney::Models::
|
|
9
|
-
required :items, -> { Yoomoney::Internal::Type::ArrayOf[Yoomoney::
|
|
8
|
+
# @return [Array<Yoomoney::Models::ReceiptData::Item>]
|
|
9
|
+
required :items, -> { Yoomoney::Internal::Type::ArrayOf[Yoomoney::ReceiptData::Item] }
|
|
10
10
|
|
|
11
11
|
# @!attribute customer
|
|
12
12
|
#
|
|
@@ -39,13 +39,133 @@ module Yoomoney
|
|
|
39
39
|
optional :timezone, String
|
|
40
40
|
|
|
41
41
|
# @!method initialize(items:, customer: nil, internet: nil, receipt_industry_details: nil, receipt_operational_details: nil, tax_system_code: nil, timezone: nil)
|
|
42
|
-
# @param items [Array<Yoomoney::Models::
|
|
42
|
+
# @param items [Array<Yoomoney::Models::ReceiptData::Item>]
|
|
43
43
|
# @param customer [Yoomoney::Models::ReceiptDataCustomer]
|
|
44
44
|
# @param internet [Boolean]
|
|
45
45
|
# @param receipt_industry_details [Array<Yoomoney::Models::IndustryDetails>]
|
|
46
46
|
# @param receipt_operational_details [Yoomoney::Models::OperationalDetails]
|
|
47
47
|
# @param tax_system_code [Integer]
|
|
48
48
|
# @param timezone [String]
|
|
49
|
+
|
|
50
|
+
class Item < Yoomoney::Internal::Type::BaseModel
|
|
51
|
+
# @!attribute amount
|
|
52
|
+
# Сумма.
|
|
53
|
+
#
|
|
54
|
+
# @return [Yoomoney::Models::MonetaryAmount]
|
|
55
|
+
required :amount, -> { Yoomoney::MonetaryAmount }
|
|
56
|
+
|
|
57
|
+
# @!attribute description
|
|
58
|
+
# Название товара.
|
|
59
|
+
#
|
|
60
|
+
# @return [String]
|
|
61
|
+
required :description, String
|
|
62
|
+
|
|
63
|
+
# @!attribute quantity
|
|
64
|
+
# Количество.
|
|
65
|
+
#
|
|
66
|
+
# @return [Float]
|
|
67
|
+
required :quantity, Float
|
|
68
|
+
|
|
69
|
+
# @!attribute vat_code
|
|
70
|
+
# Ставка НДС.
|
|
71
|
+
#
|
|
72
|
+
# @return [Integer]
|
|
73
|
+
required :vat_code, Integer
|
|
74
|
+
|
|
75
|
+
# @!attribute country_of_origin_code
|
|
76
|
+
#
|
|
77
|
+
# @return [String, nil]
|
|
78
|
+
optional :country_of_origin_code, String
|
|
79
|
+
|
|
80
|
+
# @!attribute customs_declaration_number
|
|
81
|
+
#
|
|
82
|
+
# @return [String, nil]
|
|
83
|
+
optional :customs_declaration_number, String
|
|
84
|
+
|
|
85
|
+
# @!attribute excise
|
|
86
|
+
#
|
|
87
|
+
# @return [String, nil]
|
|
88
|
+
optional :excise, String
|
|
89
|
+
|
|
90
|
+
# @!attribute mark_code_info
|
|
91
|
+
#
|
|
92
|
+
# @return [Yoomoney::Models::MarkCodeInfo, nil]
|
|
93
|
+
optional :mark_code_info, -> { Yoomoney::MarkCodeInfo }
|
|
94
|
+
|
|
95
|
+
# @!attribute mark_mode
|
|
96
|
+
#
|
|
97
|
+
# @return [String, nil]
|
|
98
|
+
optional :mark_mode, String
|
|
99
|
+
|
|
100
|
+
# @!attribute mark_quantity
|
|
101
|
+
#
|
|
102
|
+
# @return [Yoomoney::Models::MarkQuantity, nil]
|
|
103
|
+
optional :mark_quantity, -> { Yoomoney::MarkQuantity }
|
|
104
|
+
|
|
105
|
+
# @!attribute measure
|
|
106
|
+
#
|
|
107
|
+
# @return [Symbol, Yoomoney::Models::ReceiptItemMeasure, nil]
|
|
108
|
+
optional :measure, enum: -> { Yoomoney::ReceiptItemMeasure }
|
|
109
|
+
|
|
110
|
+
# @!attribute payment_mode
|
|
111
|
+
#
|
|
112
|
+
# @return [Symbol, Yoomoney::Models::ReceiptItemPaymentMode, nil]
|
|
113
|
+
optional :payment_mode, enum: -> { Yoomoney::ReceiptItemPaymentMode }
|
|
114
|
+
|
|
115
|
+
# @!attribute payment_subject
|
|
116
|
+
#
|
|
117
|
+
# @return [Symbol, Yoomoney::Models::ReceiptItemPaymentSubject, nil]
|
|
118
|
+
optional :payment_subject, enum: -> { Yoomoney::ReceiptItemPaymentSubject }
|
|
119
|
+
|
|
120
|
+
# @!attribute payment_subject_industry_details
|
|
121
|
+
#
|
|
122
|
+
# @return [Array<Yoomoney::Models::IndustryDetails>, nil]
|
|
123
|
+
optional :payment_subject_industry_details,
|
|
124
|
+
-> { Yoomoney::Internal::Type::ArrayOf[Yoomoney::IndustryDetails] }
|
|
125
|
+
|
|
126
|
+
# @!attribute planned_status
|
|
127
|
+
#
|
|
128
|
+
# @return [Integer, nil]
|
|
129
|
+
optional :planned_status, Integer
|
|
130
|
+
|
|
131
|
+
# @!attribute product_code
|
|
132
|
+
#
|
|
133
|
+
# @return [String, nil]
|
|
134
|
+
optional :product_code, String
|
|
135
|
+
|
|
136
|
+
# @!method initialize(amount:, description:, quantity:, vat_code:, country_of_origin_code: nil, customs_declaration_number: nil, excise: nil, mark_code_info: nil, mark_mode: nil, mark_quantity: nil, measure: nil, payment_mode: nil, payment_subject: nil, payment_subject_industry_details: nil, planned_status: nil, product_code: nil)
|
|
137
|
+
# @param amount [Yoomoney::Models::MonetaryAmount] Сумма.
|
|
138
|
+
#
|
|
139
|
+
# @param description [String] Название товара.
|
|
140
|
+
#
|
|
141
|
+
# @param quantity [Float] Количество.
|
|
142
|
+
#
|
|
143
|
+
# @param vat_code [Integer] Ставка НДС.
|
|
144
|
+
#
|
|
145
|
+
# @param country_of_origin_code [String]
|
|
146
|
+
#
|
|
147
|
+
# @param customs_declaration_number [String]
|
|
148
|
+
#
|
|
149
|
+
# @param excise [String]
|
|
150
|
+
#
|
|
151
|
+
# @param mark_code_info [Yoomoney::Models::MarkCodeInfo]
|
|
152
|
+
#
|
|
153
|
+
# @param mark_mode [String]
|
|
154
|
+
#
|
|
155
|
+
# @param mark_quantity [Yoomoney::Models::MarkQuantity]
|
|
156
|
+
#
|
|
157
|
+
# @param measure [Symbol, Yoomoney::Models::ReceiptItemMeasure]
|
|
158
|
+
#
|
|
159
|
+
# @param payment_mode [Symbol, Yoomoney::Models::ReceiptItemPaymentMode]
|
|
160
|
+
#
|
|
161
|
+
# @param payment_subject [Symbol, Yoomoney::Models::ReceiptItemPaymentSubject]
|
|
162
|
+
#
|
|
163
|
+
# @param payment_subject_industry_details [Array<Yoomoney::Models::IndustryDetails>]
|
|
164
|
+
#
|
|
165
|
+
# @param planned_status [Integer]
|
|
166
|
+
#
|
|
167
|
+
# @param product_code [String]
|
|
168
|
+
end
|
|
49
169
|
end
|
|
50
170
|
end
|
|
51
171
|
end
|
data/lib/yoomoney/models.rb
CHANGED
|
@@ -41,10 +41,6 @@ module Yoomoney
|
|
|
41
41
|
|
|
42
42
|
Airline = Yoomoney::Models::Airline
|
|
43
43
|
|
|
44
|
-
AirlineLeg = Yoomoney::Models::AirlineLeg
|
|
45
|
-
|
|
46
|
-
AirlinePassenger = Yoomoney::Models::AirlinePassenger
|
|
47
|
-
|
|
48
44
|
B2bSberbankCalculatedVatData = Yoomoney::Models::B2bSberbankCalculatedVatData
|
|
49
45
|
|
|
50
46
|
B2bSberbankMixedVatData = Yoomoney::Models::B2bSberbankMixedVatData
|
|
@@ -175,8 +171,6 @@ module Yoomoney
|
|
|
175
171
|
|
|
176
172
|
ReceiptDataCustomer = Yoomoney::Models::ReceiptDataCustomer
|
|
177
173
|
|
|
178
|
-
ReceiptDataItem = Yoomoney::Models::ReceiptDataItem
|
|
179
|
-
|
|
180
174
|
ReceiptItemAgentType = Yoomoney::Models::ReceiptItemAgentType
|
|
181
175
|
|
|
182
176
|
ReceiptItemMeasure = Yoomoney::Models::ReceiptItemMeasure
|
data/lib/yoomoney/version.rb
CHANGED
data/lib/yoomoney.rb
CHANGED
|
@@ -64,11 +64,8 @@ require_relative "yoomoney/models/confirmation_data"
|
|
|
64
64
|
require_relative "yoomoney/models/payout_destination"
|
|
65
65
|
require_relative "yoomoney/models/payout_destination_data"
|
|
66
66
|
require_relative "yoomoney/models/receipt_item_supplier"
|
|
67
|
-
require_relative "yoomoney/models/receipt_data_item"
|
|
68
67
|
require_relative "yoomoney/models/refund_method"
|
|
69
68
|
require_relative "yoomoney/models/airline"
|
|
70
|
-
require_relative "yoomoney/models/airline_leg"
|
|
71
|
-
require_relative "yoomoney/models/airline_passenger"
|
|
72
69
|
require_relative "yoomoney/models/b2b_sberbank_calculated_vat_data"
|
|
73
70
|
require_relative "yoomoney/models/b2b_sberbank_mixed_vat_data"
|
|
74
71
|
require_relative "yoomoney/models/b2b_sberbank_untaxed_vat_data"
|
|
@@ -12,17 +12,17 @@ module Yoomoney
|
|
|
12
12
|
sig { params(booking_reference: String).void }
|
|
13
13
|
attr_writer :booking_reference
|
|
14
14
|
|
|
15
|
-
sig { returns(T.nilable(T::Array[Yoomoney::
|
|
15
|
+
sig { returns(T.nilable(T::Array[Yoomoney::Airline::Leg])) }
|
|
16
16
|
attr_reader :legs
|
|
17
17
|
|
|
18
|
-
sig { params(legs: T::Array[Yoomoney::
|
|
18
|
+
sig { params(legs: T::Array[Yoomoney::Airline::Leg::OrHash]).void }
|
|
19
19
|
attr_writer :legs
|
|
20
20
|
|
|
21
|
-
sig { returns(T.nilable(T::Array[Yoomoney::
|
|
21
|
+
sig { returns(T.nilable(T::Array[Yoomoney::Airline::Passenger])) }
|
|
22
22
|
attr_reader :passengers
|
|
23
23
|
|
|
24
24
|
sig do
|
|
25
|
-
params(passengers: T::Array[Yoomoney::
|
|
25
|
+
params(passengers: T::Array[Yoomoney::Airline::Passenger::OrHash]).void
|
|
26
26
|
end
|
|
27
27
|
attr_writer :passengers
|
|
28
28
|
|
|
@@ -35,8 +35,8 @@ module Yoomoney
|
|
|
35
35
|
sig do
|
|
36
36
|
params(
|
|
37
37
|
booking_reference: String,
|
|
38
|
-
legs: T::Array[Yoomoney::
|
|
39
|
-
passengers: T::Array[Yoomoney::
|
|
38
|
+
legs: T::Array[Yoomoney::Airline::Leg::OrHash],
|
|
39
|
+
passengers: T::Array[Yoomoney::Airline::Passenger::OrHash],
|
|
40
40
|
ticket_number: String
|
|
41
41
|
).returns(T.attached_class)
|
|
42
42
|
end
|
|
@@ -52,14 +52,90 @@ module Yoomoney
|
|
|
52
52
|
override.returns(
|
|
53
53
|
{
|
|
54
54
|
booking_reference: String,
|
|
55
|
-
legs: T::Array[Yoomoney::
|
|
56
|
-
passengers: T::Array[Yoomoney::
|
|
55
|
+
legs: T::Array[Yoomoney::Airline::Leg],
|
|
56
|
+
passengers: T::Array[Yoomoney::Airline::Passenger],
|
|
57
57
|
ticket_number: String
|
|
58
58
|
}
|
|
59
59
|
)
|
|
60
60
|
end
|
|
61
61
|
def to_hash
|
|
62
62
|
end
|
|
63
|
+
|
|
64
|
+
class Leg < Yoomoney::Internal::Type::BaseModel
|
|
65
|
+
OrHash =
|
|
66
|
+
T.type_alias do
|
|
67
|
+
T.any(Yoomoney::Airline::Leg, Yoomoney::Internal::AnyHash)
|
|
68
|
+
end
|
|
69
|
+
|
|
70
|
+
sig { returns(String) }
|
|
71
|
+
attr_accessor :departure_airport
|
|
72
|
+
|
|
73
|
+
sig { returns(String) }
|
|
74
|
+
attr_accessor :departure_date
|
|
75
|
+
|
|
76
|
+
sig { returns(String) }
|
|
77
|
+
attr_accessor :destination_airport
|
|
78
|
+
|
|
79
|
+
sig { returns(T.nilable(String)) }
|
|
80
|
+
attr_reader :carrier_code
|
|
81
|
+
|
|
82
|
+
sig { params(carrier_code: String).void }
|
|
83
|
+
attr_writer :carrier_code
|
|
84
|
+
|
|
85
|
+
sig do
|
|
86
|
+
params(
|
|
87
|
+
departure_airport: String,
|
|
88
|
+
departure_date: String,
|
|
89
|
+
destination_airport: String,
|
|
90
|
+
carrier_code: String
|
|
91
|
+
).returns(T.attached_class)
|
|
92
|
+
end
|
|
93
|
+
def self.new(
|
|
94
|
+
departure_airport:,
|
|
95
|
+
departure_date:,
|
|
96
|
+
destination_airport:,
|
|
97
|
+
carrier_code: nil
|
|
98
|
+
)
|
|
99
|
+
end
|
|
100
|
+
|
|
101
|
+
sig do
|
|
102
|
+
override.returns(
|
|
103
|
+
{
|
|
104
|
+
departure_airport: String,
|
|
105
|
+
departure_date: String,
|
|
106
|
+
destination_airport: String,
|
|
107
|
+
carrier_code: String
|
|
108
|
+
}
|
|
109
|
+
)
|
|
110
|
+
end
|
|
111
|
+
def to_hash
|
|
112
|
+
end
|
|
113
|
+
end
|
|
114
|
+
|
|
115
|
+
class Passenger < Yoomoney::Internal::Type::BaseModel
|
|
116
|
+
OrHash =
|
|
117
|
+
T.type_alias do
|
|
118
|
+
T.any(Yoomoney::Airline::Passenger, Yoomoney::Internal::AnyHash)
|
|
119
|
+
end
|
|
120
|
+
|
|
121
|
+
sig { returns(String) }
|
|
122
|
+
attr_accessor :first_name
|
|
123
|
+
|
|
124
|
+
sig { returns(String) }
|
|
125
|
+
attr_accessor :last_name
|
|
126
|
+
|
|
127
|
+
sig do
|
|
128
|
+
params(first_name: String, last_name: String).returns(
|
|
129
|
+
T.attached_class
|
|
130
|
+
)
|
|
131
|
+
end
|
|
132
|
+
def self.new(first_name:, last_name:)
|
|
133
|
+
end
|
|
134
|
+
|
|
135
|
+
sig { override.returns({ first_name: String, last_name: String }) }
|
|
136
|
+
def to_hash
|
|
137
|
+
end
|
|
138
|
+
end
|
|
63
139
|
end
|
|
64
140
|
end
|
|
65
141
|
end
|