@mivis/petmart-api 1.2.291 → 1.2.293
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.
- package/package.json +11 -11
- package/type.d.ts +2549 -2523
package/type.d.ts
CHANGED
|
@@ -1,2523 +1,2549 @@
|
|
|
1
|
-
declare namespace Components {
|
|
2
|
-
namespace Schemas {
|
|
3
|
-
export interface FilterBaseQuery {
|
|
4
|
-
skip: string;
|
|
5
|
-
limit: string;
|
|
6
|
-
}
|
|
7
|
-
export interface ITokensResponse {
|
|
8
|
-
access_token: string;
|
|
9
|
-
refresh_token: string;
|
|
10
|
-
}
|
|
11
|
-
export interface ILoginRequest {
|
|
12
|
-
email: string;
|
|
13
|
-
password: string;
|
|
14
|
-
type: ELoginTypes;
|
|
15
|
-
}
|
|
16
|
-
export interface ISignUpRequest {
|
|
17
|
-
email: string;
|
|
18
|
-
password: string;
|
|
19
|
-
}
|
|
20
|
-
export interface ILoginResponse extends ITokensResponse {
|
|
21
|
-
isSeller: boolean;
|
|
22
|
-
user_id: string;
|
|
23
|
-
isActivated: boolean;
|
|
24
|
-
isExistPassword: boolean;
|
|
25
|
-
role: ERoles;
|
|
26
|
-
isNewUser: boolean;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
export type ISignUpResponse = ITokensResponse;
|
|
30
|
-
|
|
31
|
-
export interface IRecoveryRequest {
|
|
32
|
-
email: string;
|
|
33
|
-
password: string;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
export interface IRecoveryResponse {
|
|
37
|
-
message: string;
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
export interface IActivationRequest {
|
|
41
|
-
email: string;
|
|
42
|
-
activation_code: number;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
export interface IActivationResponse {
|
|
46
|
-
message: string;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
export interface IRefreshRequest {
|
|
50
|
-
refreshToken: string;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
export type IRefreshResponse = ITokensResponse & { is_activated: boolean };
|
|
54
|
-
|
|
55
|
-
export enum ELoginTypes {
|
|
56
|
-
SELLER = 'SELLER',
|
|
57
|
-
USER = 'USER',
|
|
58
|
-
WEB = 'WEB',
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
export interface ISendEmailRequest {
|
|
62
|
-
email: string;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
export interface ISendEmailResponse {
|
|
66
|
-
message: string;
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
export interface ISignUpGoogleRequest {
|
|
70
|
-
access_token: string;
|
|
71
|
-
auth_type: ELoginTypes;
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
export type ISignUpGoogleResponse = ILoginResponse;
|
|
75
|
-
|
|
76
|
-
export interface ISignUpAppleRequest {
|
|
77
|
-
code: string;
|
|
78
|
-
auth_type: ELoginTypes;
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
export type ISignUpAppleResponse = ILoginResponse;
|
|
82
|
-
|
|
83
|
-
export interface ISignUpVkRequest {
|
|
84
|
-
silent_token: string;
|
|
85
|
-
uuid: string;
|
|
86
|
-
auth_type: ELoginTypes;
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
export type ISignUpVkResponse = ILoginResponse;
|
|
90
|
-
|
|
91
|
-
export enum ERoles {
|
|
92
|
-
ADMIN = 'ADMIN',
|
|
93
|
-
USER = 'USER',
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
export interface IActionsProductRequest {
|
|
97
|
-
toDelete: string;
|
|
98
|
-
toPublish: string;
|
|
99
|
-
toCopy: string;
|
|
100
|
-
toDraft: string;
|
|
101
|
-
toReject: string;
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
export enum EActions {
|
|
105
|
-
DELETE = 'toDelete',
|
|
106
|
-
PUBLISH = 'toPublish',
|
|
107
|
-
COPY = 'toCopy',
|
|
108
|
-
DRAFT = 'toDraft',
|
|
109
|
-
REJECT = 'toReject',
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
export interface IActionsProductResponse {
|
|
113
|
-
message: string;
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
export interface IUser {
|
|
117
|
-
_id: string;
|
|
118
|
-
tel?: number;
|
|
119
|
-
name?: string;
|
|
120
|
-
surname?: string;
|
|
121
|
-
patronymic?: string;
|
|
122
|
-
full_name?: string;
|
|
123
|
-
birthday?: Date;
|
|
124
|
-
email?: string;
|
|
125
|
-
role: ERoles;
|
|
126
|
-
vk_id?: number;
|
|
127
|
-
expo_push_token?: string;
|
|
128
|
-
number: number;
|
|
129
|
-
is_activated: boolean;
|
|
130
|
-
createdAt: Date;
|
|
131
|
-
updatedAt: Date;
|
|
132
|
-
}
|
|
133
|
-
|
|
134
|
-
export interface IShortUser {
|
|
135
|
-
_id: string;
|
|
136
|
-
tel?: number;
|
|
137
|
-
name?: string;
|
|
138
|
-
surname?: string;
|
|
139
|
-
patronymic?: string;
|
|
140
|
-
full_name?: string;
|
|
141
|
-
birthday?: Date;
|
|
142
|
-
email?: string;
|
|
143
|
-
number: number;
|
|
144
|
-
}
|
|
145
|
-
|
|
146
|
-
export interface IAdminUserQueryResponse {
|
|
147
|
-
users: IShortUser[];
|
|
148
|
-
count: number;
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
export interface IAdminUsersQueryRequest extends FilterBaseQuery {
|
|
152
|
-
tel?: string;
|
|
153
|
-
full_name?: string;
|
|
154
|
-
email?: string;
|
|
155
|
-
number?: string;
|
|
156
|
-
all_fields?: string;
|
|
157
|
-
}
|
|
158
|
-
|
|
159
|
-
export interface IAdminCreateUser {
|
|
160
|
-
name: string;
|
|
161
|
-
surname: string;
|
|
162
|
-
patronymic?: string;
|
|
163
|
-
email: string;
|
|
164
|
-
tel: number;
|
|
165
|
-
password: string;
|
|
166
|
-
}
|
|
167
|
-
|
|
168
|
-
export interface IAdminUpdateUser {
|
|
169
|
-
_id: string;
|
|
170
|
-
name: string;
|
|
171
|
-
surname: string;
|
|
172
|
-
patronymic?: string;
|
|
173
|
-
tel: number;
|
|
174
|
-
email: string;
|
|
175
|
-
}
|
|
176
|
-
|
|
177
|
-
export interface IActionsUsersRequest {
|
|
178
|
-
toDelete: string;
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
export interface IAddress {
|
|
182
|
-
_id: string;
|
|
183
|
-
address: string;
|
|
184
|
-
floor: number;
|
|
185
|
-
intercom?: string;
|
|
186
|
-
entrance: number;
|
|
187
|
-
index?: number;
|
|
188
|
-
flat: number;
|
|
189
|
-
createdAt: Date;
|
|
190
|
-
updatedAt: Date;
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
export interface IUserAddress extends IAddress {
|
|
194
|
-
user_id: string;
|
|
195
|
-
}
|
|
196
|
-
|
|
197
|
-
export interface IUpdateUser {
|
|
198
|
-
name: string;
|
|
199
|
-
surname: string;
|
|
200
|
-
patronymic?: string;
|
|
201
|
-
tel: number;
|
|
202
|
-
email: string;
|
|
203
|
-
birthday?: Date;
|
|
204
|
-
password?: string;
|
|
205
|
-
expo_push_token?: string;
|
|
206
|
-
}
|
|
207
|
-
|
|
208
|
-
export enum EUserTransactionsType {
|
|
209
|
-
PURCHASE = 'PURCHASE',
|
|
210
|
-
REFUND = 'REFUND',
|
|
211
|
-
}
|
|
212
|
-
|
|
213
|
-
export interface ICreateAddress {
|
|
214
|
-
user_id: string;
|
|
215
|
-
floor: number;
|
|
216
|
-
intercom: string;
|
|
217
|
-
entrance: number;
|
|
218
|
-
index: number;
|
|
219
|
-
flat: number;
|
|
220
|
-
address: string;
|
|
221
|
-
}
|
|
222
|
-
|
|
223
|
-
export interface IUpdateAddress {
|
|
224
|
-
id: string;
|
|
225
|
-
floor: number;
|
|
226
|
-
intercom: string;
|
|
227
|
-
entrance: number;
|
|
228
|
-
index: number;
|
|
229
|
-
flat: number;
|
|
230
|
-
address: string;
|
|
231
|
-
}
|
|
232
|
-
|
|
233
|
-
export enum EUnit {
|
|
234
|
-
KG = 'KG',
|
|
235
|
-
GR = 'GR',
|
|
236
|
-
}
|
|
237
|
-
|
|
238
|
-
export interface IDimension {
|
|
239
|
-
width: number;
|
|
240
|
-
height: number;
|
|
241
|
-
length: number;
|
|
242
|
-
weight: number;
|
|
243
|
-
in_stock: number;
|
|
244
|
-
unit: EUnit;
|
|
245
|
-
}
|
|
246
|
-
|
|
247
|
-
export interface ICharacteristic {
|
|
248
|
-
name: string;
|
|
249
|
-
value: string;
|
|
250
|
-
}
|
|
251
|
-
|
|
252
|
-
export enum EProductType {
|
|
253
|
-
PRODUCT = 'PRODUCT',
|
|
254
|
-
VARIATION = 'VARIATION',
|
|
255
|
-
}
|
|
256
|
-
|
|
257
|
-
export interface IProduct {
|
|
258
|
-
_id: string;
|
|
259
|
-
type: EProductType;
|
|
260
|
-
parent_id?: string | null; // Ссылка на родителя (исключительно для вариаций)
|
|
261
|
-
name: string;
|
|
262
|
-
status: EProductStatus; // Для вариаций статус всегда PUBLISHED
|
|
263
|
-
subCategory_id: string;
|
|
264
|
-
category_id: string;
|
|
265
|
-
seller_id: string;
|
|
266
|
-
vendor_code: string;
|
|
267
|
-
price: number;
|
|
268
|
-
discount?: number;
|
|
269
|
-
tax: number;
|
|
270
|
-
dimension: IDimension;
|
|
271
|
-
photo: string[];
|
|
272
|
-
desc: string;
|
|
273
|
-
old_desc: string;
|
|
274
|
-
characteristic: ICharacteristic[];
|
|
275
|
-
external_item_id: string | null;
|
|
276
|
-
variations?: IProduct[];
|
|
277
|
-
purchases_count: number;
|
|
278
|
-
number: number;
|
|
279
|
-
article: string; // example: 002281
|
|
280
|
-
slug: string;
|
|
281
|
-
published_at?: Date;
|
|
282
|
-
entityAnalytics?: IEntityAnalytics;
|
|
283
|
-
low_stock_flag: boolean;
|
|
284
|
-
f_price: number | null;
|
|
285
|
-
createdAt: Date;
|
|
286
|
-
updatedAt: Date;
|
|
287
|
-
}
|
|
288
|
-
|
|
289
|
-
export interface IProductQueryRequest extends FilterBaseQuery {
|
|
290
|
-
category_id?: string;
|
|
291
|
-
subCategory_id?: string;
|
|
292
|
-
seller_id?: string;
|
|
293
|
-
name?: string;
|
|
294
|
-
status?: EProductStatus;
|
|
295
|
-
all_fields?: string;
|
|
296
|
-
type?: EProductType;
|
|
297
|
-
isHaveParent?: boolean;
|
|
298
|
-
excludeProductId?: string;
|
|
299
|
-
}
|
|
300
|
-
|
|
301
|
-
export interface IUserProductQueryRequest extends FilterBaseQuery {
|
|
302
|
-
user_id?: string;
|
|
303
|
-
category_id?: string;
|
|
304
|
-
subCategory_id?: string;
|
|
305
|
-
seller_id?: string;
|
|
306
|
-
name?: string;
|
|
307
|
-
priceMin?: string;
|
|
308
|
-
priceMax?: string;
|
|
309
|
-
colors?: string;
|
|
310
|
-
brands?: string;
|
|
311
|
-
sizes?: string;
|
|
312
|
-
materials?: string;
|
|
313
|
-
sortBy?: EProductsSortOptions;
|
|
314
|
-
}
|
|
315
|
-
|
|
316
|
-
export interface IProductQueryResponse {
|
|
317
|
-
products: IProductDraftResponse[];
|
|
318
|
-
count: number;
|
|
319
|
-
}
|
|
320
|
-
|
|
321
|
-
export interface IUserProductQueryResponse {
|
|
322
|
-
products: IProductResponse[];
|
|
323
|
-
subCategories: ISubCategory[];
|
|
324
|
-
}
|
|
325
|
-
|
|
326
|
-
export enum EProductStatus {
|
|
327
|
-
DRAFT = 'DRAFT',
|
|
328
|
-
MODERATION = 'MODERATION',
|
|
329
|
-
PUBLISHED = 'PUBLISHED',
|
|
330
|
-
REJECTED = 'REJECTED',
|
|
331
|
-
ARCHIVED = 'ARCHIVED',
|
|
332
|
-
}
|
|
333
|
-
|
|
334
|
-
export interface IProductResponse {
|
|
335
|
-
_id: string;
|
|
336
|
-
name: string;
|
|
337
|
-
type: EProductType;
|
|
338
|
-
parent_id?: string | null;
|
|
339
|
-
status: EProductStatus;
|
|
340
|
-
subCategory_id: {
|
|
341
|
-
_id: string;
|
|
342
|
-
name: string;
|
|
343
|
-
category_id: string;
|
|
344
|
-
slug: string;
|
|
345
|
-
};
|
|
346
|
-
category_id: {
|
|
347
|
-
_id: string;
|
|
348
|
-
photo: string;
|
|
349
|
-
name: string;
|
|
350
|
-
slug: string;
|
|
351
|
-
};
|
|
352
|
-
seller_id?: {
|
|
353
|
-
_id: string;
|
|
354
|
-
shop_details: IShopDetails;
|
|
355
|
-
delivery_ways: IDeliveryWays;
|
|
356
|
-
slug: string;
|
|
357
|
-
};
|
|
358
|
-
vendor_code: string;
|
|
359
|
-
price: number;
|
|
360
|
-
discount?: number;
|
|
361
|
-
tax: number;
|
|
362
|
-
dimension: IDimension;
|
|
363
|
-
photo: string[];
|
|
364
|
-
desc: string;
|
|
365
|
-
old_desc: string;
|
|
366
|
-
characteristic: ICharacteristic[];
|
|
367
|
-
variations?: IProduct[];
|
|
368
|
-
purchases_count: number;
|
|
369
|
-
number: number;
|
|
370
|
-
article: string; // example: 002281
|
|
371
|
-
slug: string;
|
|
372
|
-
createdAt: Date;
|
|
373
|
-
updatedAt: Date;
|
|
374
|
-
is_favorite?: boolean;
|
|
375
|
-
reviewsData?: IReviewsData;
|
|
376
|
-
published_at?: Date;
|
|
377
|
-
entityAnalytics?: IEntityAnalytics;
|
|
378
|
-
low_stock_flag: boolean;
|
|
379
|
-
f_price: number | null;
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
| '
|
|
395
|
-
| '
|
|
396
|
-
| '
|
|
397
|
-
| '
|
|
398
|
-
| '
|
|
399
|
-
| '
|
|
400
|
-
| '
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
| EProductStatus.
|
|
429
|
-
| EProductStatus.
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
| '
|
|
447
|
-
| '
|
|
448
|
-
| '
|
|
449
|
-
| '
|
|
450
|
-
| '
|
|
451
|
-
| '
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
export
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
export
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
| '
|
|
890
|
-
| '
|
|
891
|
-
| '
|
|
892
|
-
| '
|
|
893
|
-
| '
|
|
894
|
-
|
|
895
|
-
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
seller_id
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
|
|
1034
|
-
|
|
1035
|
-
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
| '
|
|
1059
|
-
| '
|
|
1060
|
-
| '
|
|
1061
|
-
| '
|
|
1062
|
-
| '
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
user_id
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1317
|
-
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
export interface
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1343
|
-
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1358
|
-
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
|
|
1363
|
-
|
|
1364
|
-
|
|
1365
|
-
|
|
1366
|
-
|
|
1367
|
-
|
|
1368
|
-
|
|
1369
|
-
|
|
1370
|
-
|
|
1371
|
-
|
|
1372
|
-
|
|
1373
|
-
|
|
1374
|
-
|
|
1375
|
-
|
|
1376
|
-
|
|
1377
|
-
|
|
1378
|
-
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1382
|
-
|
|
1383
|
-
|
|
1384
|
-
|
|
1385
|
-
|
|
1386
|
-
|
|
1387
|
-
|
|
1388
|
-
|
|
1389
|
-
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1393
|
-
|
|
1394
|
-
|
|
1395
|
-
|
|
1396
|
-
|
|
1397
|
-
|
|
1398
|
-
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1404
|
-
|
|
1405
|
-
|
|
1406
|
-
|
|
1407
|
-
|
|
1408
|
-
|
|
1409
|
-
|
|
1410
|
-
|
|
1411
|
-
|
|
1412
|
-
|
|
1413
|
-
|
|
1414
|
-
|
|
1415
|
-
|
|
1416
|
-
|
|
1417
|
-
|
|
1418
|
-
|
|
1419
|
-
|
|
1420
|
-
|
|
1421
|
-
|
|
1422
|
-
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
|
|
1428
|
-
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
|
|
1432
|
-
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
'
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
'
|
|
1507
|
-
'
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
|
|
1524
|
-
|
|
1525
|
-
|
|
1526
|
-
|
|
1527
|
-
|
|
1528
|
-
|
|
1529
|
-
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
|
|
1533
|
-
|
|
1534
|
-
|
|
1535
|
-
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1580
|
-
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1610
|
-
|
|
1611
|
-
|
|
1612
|
-
|
|
1613
|
-
|
|
1614
|
-
|
|
1615
|
-
|
|
1616
|
-
|
|
1617
|
-
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
|
|
1621
|
-
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
|
|
1658
|
-
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1673
|
-
|
|
1674
|
-
|
|
1675
|
-
|
|
1676
|
-
|
|
1677
|
-
|
|
1678
|
-
|
|
1679
|
-
|
|
1680
|
-
|
|
1681
|
-
|
|
1682
|
-
|
|
1683
|
-
|
|
1684
|
-
|
|
1685
|
-
|
|
1686
|
-
|
|
1687
|
-
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1700
|
-
|
|
1701
|
-
|
|
1702
|
-
|
|
1703
|
-
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
|
|
1708
|
-
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
|
|
1718
|
-
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
|
|
1727
|
-
|
|
1728
|
-
|
|
1729
|
-
|
|
1730
|
-
|
|
1731
|
-
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1735
|
-
|
|
1736
|
-
|
|
1737
|
-
|
|
1738
|
-
|
|
1739
|
-
|
|
1740
|
-
|
|
1741
|
-
|
|
1742
|
-
|
|
1743
|
-
|
|
1744
|
-
|
|
1745
|
-
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
|
|
1753
|
-
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
|
-
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
1787
|
-
|
|
1788
|
-
|
|
1789
|
-
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
suit
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
|
|
1894
|
-
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
|
|
1915
|
-
|
|
1916
|
-
|
|
1917
|
-
|
|
1918
|
-
|
|
1919
|
-
|
|
1920
|
-
|
|
1921
|
-
|
|
1922
|
-
|
|
1923
|
-
|
|
1924
|
-
|
|
1925
|
-
|
|
1926
|
-
|
|
1927
|
-
|
|
1928
|
-
|
|
1929
|
-
|
|
1930
|
-
|
|
1931
|
-
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
|
|
1935
|
-
|
|
1936
|
-
|
|
1937
|
-
|
|
1938
|
-
|
|
1939
|
-
|
|
1940
|
-
|
|
1941
|
-
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
1945
|
-
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
|
|
1952
|
-
|
|
1953
|
-
|
|
1954
|
-
|
|
1955
|
-
|
|
1956
|
-
|
|
1957
|
-
|
|
1958
|
-
|
|
1959
|
-
|
|
1960
|
-
|
|
1961
|
-
|
|
1962
|
-
|
|
1963
|
-
|
|
1964
|
-
|
|
1965
|
-
|
|
1966
|
-
|
|
1967
|
-
|
|
1968
|
-
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
|
|
1982
|
-
|
|
1983
|
-
|
|
1984
|
-
|
|
1985
|
-
|
|
1986
|
-
|
|
1987
|
-
|
|
1988
|
-
|
|
1989
|
-
|
|
1990
|
-
|
|
1991
|
-
|
|
1992
|
-
|
|
1993
|
-
|
|
1994
|
-
|
|
1995
|
-
|
|
1996
|
-
|
|
1997
|
-
|
|
1998
|
-
|
|
1999
|
-
|
|
2000
|
-
|
|
2001
|
-
|
|
2002
|
-
|
|
2003
|
-
|
|
2004
|
-
|
|
2005
|
-
|
|
2006
|
-
|
|
2007
|
-
|
|
2008
|
-
|
|
2009
|
-
|
|
2010
|
-
|
|
2011
|
-
|
|
2012
|
-
|
|
2013
|
-
|
|
2014
|
-
|
|
2015
|
-
|
|
2016
|
-
|
|
2017
|
-
|
|
2018
|
-
|
|
2019
|
-
|
|
2020
|
-
|
|
2021
|
-
|
|
2022
|
-
|
|
2023
|
-
|
|
2024
|
-
|
|
2025
|
-
|
|
2026
|
-
|
|
2027
|
-
|
|
2028
|
-
|
|
2029
|
-
|
|
2030
|
-
|
|
2031
|
-
|
|
2032
|
-
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
2039
|
-
|
|
2040
|
-
|
|
2041
|
-
|
|
2042
|
-
|
|
2043
|
-
|
|
2044
|
-
|
|
2045
|
-
|
|
2046
|
-
|
|
2047
|
-
|
|
2048
|
-
|
|
2049
|
-
|
|
2050
|
-
|
|
2051
|
-
|
|
2052
|
-
|
|
2053
|
-
|
|
2054
|
-
|
|
2055
|
-
|
|
2056
|
-
|
|
2057
|
-
|
|
2058
|
-
|
|
2059
|
-
|
|
2060
|
-
}
|
|
2061
|
-
export interface
|
|
2062
|
-
|
|
2063
|
-
|
|
2064
|
-
|
|
2065
|
-
|
|
2066
|
-
|
|
2067
|
-
|
|
2068
|
-
|
|
2069
|
-
|
|
2070
|
-
|
|
2071
|
-
|
|
2072
|
-
|
|
2073
|
-
|
|
2074
|
-
|
|
2075
|
-
|
|
2076
|
-
|
|
2077
|
-
|
|
2078
|
-
|
|
2079
|
-
|
|
2080
|
-
|
|
2081
|
-
|
|
2082
|
-
|
|
2083
|
-
|
|
2084
|
-
|
|
2085
|
-
|
|
2086
|
-
|
|
2087
|
-
|
|
2088
|
-
|
|
2089
|
-
|
|
2090
|
-
|
|
2091
|
-
|
|
2092
|
-
|
|
2093
|
-
|
|
2094
|
-
|
|
2095
|
-
|
|
2096
|
-
|
|
2097
|
-
|
|
2098
|
-
|
|
2099
|
-
|
|
2100
|
-
|
|
2101
|
-
|
|
2102
|
-
|
|
2103
|
-
|
|
2104
|
-
|
|
2105
|
-
|
|
2106
|
-
|
|
2107
|
-
|
|
2108
|
-
|
|
2109
|
-
|
|
2110
|
-
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
2117
|
-
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
|
|
2148
|
-
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2154
|
-
|
|
2155
|
-
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
|
|
2161
|
-
|
|
2162
|
-
|
|
2163
|
-
|
|
2164
|
-
|
|
2165
|
-
|
|
2166
|
-
|
|
2167
|
-
export interface
|
|
2168
|
-
extends Omit<IFavorite, '
|
|
2169
|
-
|
|
2170
|
-
export interface
|
|
2171
|
-
|
|
2172
|
-
|
|
2173
|
-
|
|
2174
|
-
|
|
2175
|
-
|
|
2176
|
-
|
|
2177
|
-
|
|
2178
|
-
|
|
2179
|
-
|
|
2180
|
-
|
|
2181
|
-
|
|
2182
|
-
|
|
2183
|
-
|
|
2184
|
-
|
|
2185
|
-
|
|
2186
|
-
|
|
2187
|
-
|
|
2188
|
-
|
|
2189
|
-
|
|
2190
|
-
|
|
2191
|
-
|
|
2192
|
-
|
|
2193
|
-
|
|
2194
|
-
|
|
2195
|
-
|
|
2196
|
-
|
|
2197
|
-
|
|
2198
|
-
|
|
2199
|
-
|
|
2200
|
-
|
|
2201
|
-
|
|
2202
|
-
|
|
2203
|
-
|
|
2204
|
-
|
|
2205
|
-
|
|
2206
|
-
|
|
2207
|
-
|
|
2208
|
-
|
|
2209
|
-
|
|
2210
|
-
|
|
2211
|
-
|
|
2212
|
-
|
|
2213
|
-
|
|
2214
|
-
|
|
2215
|
-
|
|
2216
|
-
|
|
2217
|
-
|
|
2218
|
-
|
|
2219
|
-
|
|
2220
|
-
|
|
2221
|
-
|
|
2222
|
-
|
|
2223
|
-
|
|
2224
|
-
|
|
2225
|
-
|
|
2226
|
-
|
|
2227
|
-
|
|
2228
|
-
|
|
2229
|
-
|
|
2230
|
-
|
|
2231
|
-
|
|
2232
|
-
|
|
2233
|
-
|
|
2234
|
-
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
|
|
2238
|
-
|
|
2239
|
-
|
|
2240
|
-
|
|
2241
|
-
|
|
2242
|
-
|
|
2243
|
-
|
|
2244
|
-
|
|
2245
|
-
user_id
|
|
2246
|
-
|
|
2247
|
-
|
|
2248
|
-
|
|
2249
|
-
|
|
2250
|
-
|
|
2251
|
-
|
|
2252
|
-
|
|
2253
|
-
|
|
2254
|
-
|
|
2255
|
-
|
|
2256
|
-
|
|
2257
|
-
|
|
2258
|
-
|
|
2259
|
-
|
|
2260
|
-
|
|
2261
|
-
|
|
2262
|
-
|
|
2263
|
-
|
|
2264
|
-
|
|
2265
|
-
|
|
2266
|
-
|
|
2267
|
-
|
|
2268
|
-
|
|
2269
|
-
|
|
2270
|
-
|
|
2271
|
-
|
|
2272
|
-
|
|
2273
|
-
|
|
2274
|
-
|
|
2275
|
-
|
|
2276
|
-
|
|
2277
|
-
|
|
2278
|
-
|
|
2279
|
-
|
|
2280
|
-
|
|
2281
|
-
|
|
2282
|
-
|
|
2283
|
-
|
|
2284
|
-
|
|
2285
|
-
|
|
2286
|
-
|
|
2287
|
-
|
|
2288
|
-
|
|
2289
|
-
|
|
2290
|
-
|
|
2291
|
-
|
|
2292
|
-
|
|
2293
|
-
|
|
2294
|
-
|
|
2295
|
-
|
|
2296
|
-
|
|
2297
|
-
|
|
2298
|
-
|
|
2299
|
-
|
|
2300
|
-
|
|
2301
|
-
|
|
2302
|
-
|
|
2303
|
-
|
|
2304
|
-
|
|
2305
|
-
|
|
2306
|
-
|
|
2307
|
-
|
|
2308
|
-
|
|
2309
|
-
|
|
2310
|
-
|
|
2311
|
-
|
|
2312
|
-
|
|
2313
|
-
|
|
2314
|
-
|
|
2315
|
-
|
|
2316
|
-
|
|
2317
|
-
|
|
2318
|
-
|
|
2319
|
-
|
|
2320
|
-
|
|
2321
|
-
|
|
2322
|
-
|
|
2323
|
-
|
|
2324
|
-
|
|
2325
|
-
|
|
2326
|
-
|
|
2327
|
-
|
|
2328
|
-
|
|
2329
|
-
|
|
2330
|
-
|
|
2331
|
-
|
|
2332
|
-
|
|
2333
|
-
|
|
2334
|
-
|
|
2335
|
-
|
|
2336
|
-
|
|
2337
|
-
|
|
2338
|
-
|
|
2339
|
-
|
|
2340
|
-
|
|
2341
|
-
|
|
2342
|
-
|
|
2343
|
-
|
|
2344
|
-
|
|
2345
|
-
|
|
2346
|
-
|
|
2347
|
-
|
|
2348
|
-
|
|
2349
|
-
|
|
2350
|
-
|
|
2351
|
-
|
|
2352
|
-
|
|
2353
|
-
|
|
2354
|
-
|
|
2355
|
-
|
|
2356
|
-
|
|
2357
|
-
|
|
2358
|
-
|
|
2359
|
-
|
|
2360
|
-
|
|
2361
|
-
|
|
2362
|
-
|
|
2363
|
-
|
|
2364
|
-
|
|
2365
|
-
|
|
2366
|
-
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
|
|
2370
|
-
|
|
2371
|
-
|
|
2372
|
-
|
|
2373
|
-
|
|
2374
|
-
|
|
2375
|
-
|
|
2376
|
-
|
|
2377
|
-
|
|
2378
|
-
|
|
2379
|
-
|
|
2380
|
-
|
|
2381
|
-
|
|
2382
|
-
|
|
2383
|
-
|
|
2384
|
-
|
|
2385
|
-
|
|
2386
|
-
|
|
2387
|
-
|
|
2388
|
-
|
|
2389
|
-
|
|
2390
|
-
|
|
2391
|
-
|
|
2392
|
-
|
|
2393
|
-
|
|
2394
|
-
|
|
2395
|
-
|
|
2396
|
-
|
|
2397
|
-
|
|
2398
|
-
|
|
2399
|
-
|
|
2400
|
-
|
|
2401
|
-
|
|
2402
|
-
|
|
2403
|
-
|
|
2404
|
-
|
|
2405
|
-
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
|
|
2409
|
-
|
|
2410
|
-
|
|
2411
|
-
|
|
2412
|
-
|
|
2413
|
-
|
|
2414
|
-
|
|
2415
|
-
|
|
2416
|
-
|
|
2417
|
-
|
|
2418
|
-
|
|
2419
|
-
|
|
2420
|
-
|
|
2421
|
-
|
|
2422
|
-
|
|
2423
|
-
|
|
2424
|
-
|
|
2425
|
-
|
|
2426
|
-
|
|
2427
|
-
|
|
2428
|
-
|
|
2429
|
-
|
|
2430
|
-
|
|
2431
|
-
|
|
2432
|
-
|
|
2433
|
-
|
|
2434
|
-
|
|
2435
|
-
|
|
2436
|
-
|
|
2437
|
-
|
|
2438
|
-
|
|
2439
|
-
|
|
2440
|
-
|
|
2441
|
-
|
|
2442
|
-
|
|
2443
|
-
|
|
2444
|
-
|
|
2445
|
-
|
|
2446
|
-
|
|
2447
|
-
|
|
2448
|
-
|
|
2449
|
-
|
|
2450
|
-
|
|
2451
|
-
|
|
2452
|
-
|
|
2453
|
-
|
|
2454
|
-
|
|
2455
|
-
|
|
2456
|
-
|
|
2457
|
-
|
|
2458
|
-
|
|
2459
|
-
|
|
2460
|
-
|
|
2461
|
-
|
|
2462
|
-
|
|
2463
|
-
|
|
2464
|
-
|
|
2465
|
-
|
|
2466
|
-
|
|
2467
|
-
|
|
2468
|
-
|
|
2469
|
-
|
|
2470
|
-
|
|
2471
|
-
|
|
2472
|
-
|
|
2473
|
-
|
|
2474
|
-
|
|
2475
|
-
|
|
2476
|
-
|
|
2477
|
-
|
|
2478
|
-
|
|
2479
|
-
|
|
2480
|
-
|
|
2481
|
-
|
|
2482
|
-
|
|
2483
|
-
|
|
2484
|
-
|
|
2485
|
-
|
|
2486
|
-
|
|
2487
|
-
|
|
2488
|
-
|
|
2489
|
-
|
|
2490
|
-
|
|
2491
|
-
|
|
2492
|
-
|
|
2493
|
-
|
|
2494
|
-
|
|
2495
|
-
|
|
2496
|
-
|
|
2497
|
-
|
|
2498
|
-
|
|
2499
|
-
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2503
|
-
|
|
2504
|
-
|
|
2505
|
-
|
|
2506
|
-
|
|
2507
|
-
|
|
2508
|
-
|
|
2509
|
-
|
|
2510
|
-
|
|
2511
|
-
|
|
2512
|
-
|
|
2513
|
-
|
|
2514
|
-
|
|
2515
|
-
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2523
|
-
|
|
1
|
+
declare namespace Components {
|
|
2
|
+
namespace Schemas {
|
|
3
|
+
export interface FilterBaseQuery {
|
|
4
|
+
skip: string;
|
|
5
|
+
limit: string;
|
|
6
|
+
}
|
|
7
|
+
export interface ITokensResponse {
|
|
8
|
+
access_token: string;
|
|
9
|
+
refresh_token: string;
|
|
10
|
+
}
|
|
11
|
+
export interface ILoginRequest {
|
|
12
|
+
email: string;
|
|
13
|
+
password: string;
|
|
14
|
+
type: ELoginTypes;
|
|
15
|
+
}
|
|
16
|
+
export interface ISignUpRequest {
|
|
17
|
+
email: string;
|
|
18
|
+
password: string;
|
|
19
|
+
}
|
|
20
|
+
export interface ILoginResponse extends ITokensResponse {
|
|
21
|
+
isSeller: boolean;
|
|
22
|
+
user_id: string;
|
|
23
|
+
isActivated: boolean;
|
|
24
|
+
isExistPassword: boolean;
|
|
25
|
+
role: ERoles;
|
|
26
|
+
isNewUser: boolean;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export type ISignUpResponse = ITokensResponse;
|
|
30
|
+
|
|
31
|
+
export interface IRecoveryRequest {
|
|
32
|
+
email: string;
|
|
33
|
+
password: string;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
export interface IRecoveryResponse {
|
|
37
|
+
message: string;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export interface IActivationRequest {
|
|
41
|
+
email: string;
|
|
42
|
+
activation_code: number;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export interface IActivationResponse {
|
|
46
|
+
message: string;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export interface IRefreshRequest {
|
|
50
|
+
refreshToken: string;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export type IRefreshResponse = ITokensResponse & { is_activated: boolean };
|
|
54
|
+
|
|
55
|
+
export enum ELoginTypes {
|
|
56
|
+
SELLER = 'SELLER',
|
|
57
|
+
USER = 'USER',
|
|
58
|
+
WEB = 'WEB',
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export interface ISendEmailRequest {
|
|
62
|
+
email: string;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
export interface ISendEmailResponse {
|
|
66
|
+
message: string;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
export interface ISignUpGoogleRequest {
|
|
70
|
+
access_token: string;
|
|
71
|
+
auth_type: ELoginTypes;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
export type ISignUpGoogleResponse = ILoginResponse;
|
|
75
|
+
|
|
76
|
+
export interface ISignUpAppleRequest {
|
|
77
|
+
code: string;
|
|
78
|
+
auth_type: ELoginTypes;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
export type ISignUpAppleResponse = ILoginResponse;
|
|
82
|
+
|
|
83
|
+
export interface ISignUpVkRequest {
|
|
84
|
+
silent_token: string;
|
|
85
|
+
uuid: string;
|
|
86
|
+
auth_type: ELoginTypes;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
export type ISignUpVkResponse = ILoginResponse;
|
|
90
|
+
|
|
91
|
+
export enum ERoles {
|
|
92
|
+
ADMIN = 'ADMIN',
|
|
93
|
+
USER = 'USER',
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
export interface IActionsProductRequest {
|
|
97
|
+
toDelete: string;
|
|
98
|
+
toPublish: string;
|
|
99
|
+
toCopy: string;
|
|
100
|
+
toDraft: string;
|
|
101
|
+
toReject: string;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
export enum EActions {
|
|
105
|
+
DELETE = 'toDelete',
|
|
106
|
+
PUBLISH = 'toPublish',
|
|
107
|
+
COPY = 'toCopy',
|
|
108
|
+
DRAFT = 'toDraft',
|
|
109
|
+
REJECT = 'toReject',
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
export interface IActionsProductResponse {
|
|
113
|
+
message: string;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
export interface IUser {
|
|
117
|
+
_id: string;
|
|
118
|
+
tel?: number;
|
|
119
|
+
name?: string;
|
|
120
|
+
surname?: string;
|
|
121
|
+
patronymic?: string;
|
|
122
|
+
full_name?: string;
|
|
123
|
+
birthday?: Date;
|
|
124
|
+
email?: string;
|
|
125
|
+
role: ERoles;
|
|
126
|
+
vk_id?: number;
|
|
127
|
+
expo_push_token?: string;
|
|
128
|
+
number: number;
|
|
129
|
+
is_activated: boolean;
|
|
130
|
+
createdAt: Date;
|
|
131
|
+
updatedAt: Date;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
export interface IShortUser {
|
|
135
|
+
_id: string;
|
|
136
|
+
tel?: number;
|
|
137
|
+
name?: string;
|
|
138
|
+
surname?: string;
|
|
139
|
+
patronymic?: string;
|
|
140
|
+
full_name?: string;
|
|
141
|
+
birthday?: Date;
|
|
142
|
+
email?: string;
|
|
143
|
+
number: number;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
export interface IAdminUserQueryResponse {
|
|
147
|
+
users: IShortUser[];
|
|
148
|
+
count: number;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
export interface IAdminUsersQueryRequest extends FilterBaseQuery {
|
|
152
|
+
tel?: string;
|
|
153
|
+
full_name?: string;
|
|
154
|
+
email?: string;
|
|
155
|
+
number?: string;
|
|
156
|
+
all_fields?: string;
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
export interface IAdminCreateUser {
|
|
160
|
+
name: string;
|
|
161
|
+
surname: string;
|
|
162
|
+
patronymic?: string;
|
|
163
|
+
email: string;
|
|
164
|
+
tel: number;
|
|
165
|
+
password: string;
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
export interface IAdminUpdateUser {
|
|
169
|
+
_id: string;
|
|
170
|
+
name: string;
|
|
171
|
+
surname: string;
|
|
172
|
+
patronymic?: string;
|
|
173
|
+
tel: number;
|
|
174
|
+
email: string;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
export interface IActionsUsersRequest {
|
|
178
|
+
toDelete: string;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
export interface IAddress {
|
|
182
|
+
_id: string;
|
|
183
|
+
address: string;
|
|
184
|
+
floor: number;
|
|
185
|
+
intercom?: string;
|
|
186
|
+
entrance: number;
|
|
187
|
+
index?: number;
|
|
188
|
+
flat: number;
|
|
189
|
+
createdAt: Date;
|
|
190
|
+
updatedAt: Date;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
export interface IUserAddress extends IAddress {
|
|
194
|
+
user_id: string;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
export interface IUpdateUser {
|
|
198
|
+
name: string;
|
|
199
|
+
surname: string;
|
|
200
|
+
patronymic?: string;
|
|
201
|
+
tel: number;
|
|
202
|
+
email: string;
|
|
203
|
+
birthday?: Date;
|
|
204
|
+
password?: string;
|
|
205
|
+
expo_push_token?: string;
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
export enum EUserTransactionsType {
|
|
209
|
+
PURCHASE = 'PURCHASE',
|
|
210
|
+
REFUND = 'REFUND',
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
export interface ICreateAddress {
|
|
214
|
+
user_id: string;
|
|
215
|
+
floor: number;
|
|
216
|
+
intercom: string;
|
|
217
|
+
entrance: number;
|
|
218
|
+
index: number;
|
|
219
|
+
flat: number;
|
|
220
|
+
address: string;
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
export interface IUpdateAddress {
|
|
224
|
+
id: string;
|
|
225
|
+
floor: number;
|
|
226
|
+
intercom: string;
|
|
227
|
+
entrance: number;
|
|
228
|
+
index: number;
|
|
229
|
+
flat: number;
|
|
230
|
+
address: string;
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
export enum EUnit {
|
|
234
|
+
KG = 'KG',
|
|
235
|
+
GR = 'GR',
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
export interface IDimension {
|
|
239
|
+
width: number;
|
|
240
|
+
height: number;
|
|
241
|
+
length: number;
|
|
242
|
+
weight: number;
|
|
243
|
+
in_stock: number;
|
|
244
|
+
unit: EUnit;
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
export interface ICharacteristic {
|
|
248
|
+
name: string;
|
|
249
|
+
value: string;
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
export enum EProductType {
|
|
253
|
+
PRODUCT = 'PRODUCT',
|
|
254
|
+
VARIATION = 'VARIATION',
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
export interface IProduct {
|
|
258
|
+
_id: string;
|
|
259
|
+
type: EProductType;
|
|
260
|
+
parent_id?: string | null; // Ссылка на родителя (исключительно для вариаций)
|
|
261
|
+
name: string;
|
|
262
|
+
status: EProductStatus; // Для вариаций статус всегда PUBLISHED
|
|
263
|
+
subCategory_id: string;
|
|
264
|
+
category_id: string;
|
|
265
|
+
seller_id: string;
|
|
266
|
+
vendor_code: string;
|
|
267
|
+
price: number;
|
|
268
|
+
discount?: number;
|
|
269
|
+
tax: number;
|
|
270
|
+
dimension: IDimension;
|
|
271
|
+
photo: string[];
|
|
272
|
+
desc: string;
|
|
273
|
+
old_desc: string;
|
|
274
|
+
characteristic: ICharacteristic[];
|
|
275
|
+
external_item_id: string | null;
|
|
276
|
+
variations?: IProduct[];
|
|
277
|
+
purchases_count: number;
|
|
278
|
+
number: number;
|
|
279
|
+
article: string; // example: 002281
|
|
280
|
+
slug: string;
|
|
281
|
+
published_at?: Date;
|
|
282
|
+
entityAnalytics?: IEntityAnalytics;
|
|
283
|
+
low_stock_flag: boolean;
|
|
284
|
+
f_price: number | null;
|
|
285
|
+
createdAt: Date;
|
|
286
|
+
updatedAt: Date;
|
|
287
|
+
}
|
|
288
|
+
|
|
289
|
+
export interface IProductQueryRequest extends FilterBaseQuery {
|
|
290
|
+
category_id?: string;
|
|
291
|
+
subCategory_id?: string;
|
|
292
|
+
seller_id?: string;
|
|
293
|
+
name?: string;
|
|
294
|
+
status?: EProductStatus;
|
|
295
|
+
all_fields?: string;
|
|
296
|
+
type?: EProductType;
|
|
297
|
+
isHaveParent?: boolean;
|
|
298
|
+
excludeProductId?: string;
|
|
299
|
+
}
|
|
300
|
+
|
|
301
|
+
export interface IUserProductQueryRequest extends FilterBaseQuery {
|
|
302
|
+
user_id?: string;
|
|
303
|
+
category_id?: string;
|
|
304
|
+
subCategory_id?: string;
|
|
305
|
+
seller_id?: string;
|
|
306
|
+
name?: string;
|
|
307
|
+
priceMin?: string;
|
|
308
|
+
priceMax?: string;
|
|
309
|
+
colors?: string;
|
|
310
|
+
brands?: string;
|
|
311
|
+
sizes?: string;
|
|
312
|
+
materials?: string;
|
|
313
|
+
sortBy?: EProductsSortOptions;
|
|
314
|
+
}
|
|
315
|
+
|
|
316
|
+
export interface IProductQueryResponse {
|
|
317
|
+
products: IProductDraftResponse[];
|
|
318
|
+
count: number;
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
export interface IUserProductQueryResponse {
|
|
322
|
+
products: IProductResponse[];
|
|
323
|
+
subCategories: ISubCategory[];
|
|
324
|
+
}
|
|
325
|
+
|
|
326
|
+
export enum EProductStatus {
|
|
327
|
+
DRAFT = 'DRAFT',
|
|
328
|
+
MODERATION = 'MODERATION',
|
|
329
|
+
PUBLISHED = 'PUBLISHED',
|
|
330
|
+
REJECTED = 'REJECTED',
|
|
331
|
+
ARCHIVED = 'ARCHIVED',
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
export interface IProductResponse {
|
|
335
|
+
_id: string;
|
|
336
|
+
name: string;
|
|
337
|
+
type: EProductType;
|
|
338
|
+
parent_id?: string | null;
|
|
339
|
+
status: EProductStatus;
|
|
340
|
+
subCategory_id: {
|
|
341
|
+
_id: string;
|
|
342
|
+
name: string;
|
|
343
|
+
category_id: string;
|
|
344
|
+
slug: string;
|
|
345
|
+
};
|
|
346
|
+
category_id: {
|
|
347
|
+
_id: string;
|
|
348
|
+
photo: string;
|
|
349
|
+
name: string;
|
|
350
|
+
slug: string;
|
|
351
|
+
};
|
|
352
|
+
seller_id?: {
|
|
353
|
+
_id: string;
|
|
354
|
+
shop_details: IShopDetails;
|
|
355
|
+
delivery_ways: IDeliveryWays;
|
|
356
|
+
slug: string;
|
|
357
|
+
};
|
|
358
|
+
vendor_code: string;
|
|
359
|
+
price: number;
|
|
360
|
+
discount?: number;
|
|
361
|
+
tax: number;
|
|
362
|
+
dimension: IDimension;
|
|
363
|
+
photo: string[];
|
|
364
|
+
desc: string;
|
|
365
|
+
old_desc: string;
|
|
366
|
+
characteristic: ICharacteristic[];
|
|
367
|
+
variations?: IProduct[];
|
|
368
|
+
purchases_count: number;
|
|
369
|
+
number: number;
|
|
370
|
+
article: string; // example: 002281
|
|
371
|
+
slug: string;
|
|
372
|
+
createdAt: Date;
|
|
373
|
+
updatedAt: Date;
|
|
374
|
+
is_favorite?: boolean;
|
|
375
|
+
reviewsData?: IReviewsData;
|
|
376
|
+
published_at?: Date;
|
|
377
|
+
entityAnalytics?: IEntityAnalytics;
|
|
378
|
+
low_stock_flag: boolean;
|
|
379
|
+
f_price: number | null;
|
|
380
|
+
ratingScore: number;
|
|
381
|
+
}
|
|
382
|
+
|
|
383
|
+
type OptionalDimension = {
|
|
384
|
+
width?: number;
|
|
385
|
+
height?: number;
|
|
386
|
+
length?: number;
|
|
387
|
+
weight?: number;
|
|
388
|
+
in_stock: number;
|
|
389
|
+
unit?: EUnit;
|
|
390
|
+
};
|
|
391
|
+
|
|
392
|
+
type TOptionalProperties = Pick<
|
|
393
|
+
IProductResponse,
|
|
394
|
+
| 'category_id'
|
|
395
|
+
| 'subCategory_id'
|
|
396
|
+
| 'vendor_code'
|
|
397
|
+
| 'desc'
|
|
398
|
+
| 'characteristic'
|
|
399
|
+
| 'tax'
|
|
400
|
+
| 'photo'
|
|
401
|
+
| 'price'
|
|
402
|
+
> & {
|
|
403
|
+
dimension?: OptionalDimension;
|
|
404
|
+
};
|
|
405
|
+
|
|
406
|
+
type TRemainingProductResponseProperties = Omit<
|
|
407
|
+
IProductResponse,
|
|
408
|
+
keyof TOptionalProperties
|
|
409
|
+
>;
|
|
410
|
+
|
|
411
|
+
export interface IProductDraftResponse
|
|
412
|
+
extends TRemainingProductResponseProperties,
|
|
413
|
+
Partial<TOptionalProperties> {}
|
|
414
|
+
|
|
415
|
+
export interface IProductWithReviewResponse {
|
|
416
|
+
product: IProductResponse;
|
|
417
|
+
reviewsData: IReviewsData;
|
|
418
|
+
}
|
|
419
|
+
|
|
420
|
+
export interface IAddVariation {
|
|
421
|
+
_id: string;
|
|
422
|
+
characteristic: ICharacteristic[];
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
export interface ICreateProduct {
|
|
426
|
+
name: string;
|
|
427
|
+
status?:
|
|
428
|
+
| EProductStatus.DRAFT
|
|
429
|
+
| EProductStatus.PUBLISHED
|
|
430
|
+
| EProductStatus.REJECTED;
|
|
431
|
+
category_id: string;
|
|
432
|
+
subCategory_id: string;
|
|
433
|
+
vendor_code: string;
|
|
434
|
+
price: number;
|
|
435
|
+
tax: number;
|
|
436
|
+
dimension: IDimension;
|
|
437
|
+
photo: File[];
|
|
438
|
+
desc: string;
|
|
439
|
+
characteristic?: ICharacteristic[];
|
|
440
|
+
variations?: IAddVariation[];
|
|
441
|
+
}
|
|
442
|
+
|
|
443
|
+
export interface ICreateVariation
|
|
444
|
+
extends Omit<
|
|
445
|
+
ICreateProduct,
|
|
446
|
+
| 'status'
|
|
447
|
+
| 'category_id'
|
|
448
|
+
| 'subCategory_id'
|
|
449
|
+
| 'variations'
|
|
450
|
+
| 'photo'
|
|
451
|
+
| 'desc'
|
|
452
|
+
| 'characteristic'
|
|
453
|
+
> {
|
|
454
|
+
photo?: File[];
|
|
455
|
+
desc?: string;
|
|
456
|
+
seller_id: string;
|
|
457
|
+
}
|
|
458
|
+
|
|
459
|
+
export interface IUpdateProduct extends ICreateProduct {
|
|
460
|
+
id: string;
|
|
461
|
+
type?: EProductType;
|
|
462
|
+
toDeletePhotos?: string[];
|
|
463
|
+
toDeleteVariations?: string[];
|
|
464
|
+
generatedImage?: string;
|
|
465
|
+
}
|
|
466
|
+
|
|
467
|
+
export interface ICreateCart {
|
|
468
|
+
product_id: string;
|
|
469
|
+
count: number;
|
|
470
|
+
price: number;
|
|
471
|
+
}
|
|
472
|
+
|
|
473
|
+
export interface IDeleteCartRequest {
|
|
474
|
+
toDelete?: string;
|
|
475
|
+
}
|
|
476
|
+
|
|
477
|
+
export interface ICart {
|
|
478
|
+
_id: string;
|
|
479
|
+
user_id?: string | null;
|
|
480
|
+
session_id?: string | null;
|
|
481
|
+
product_id: {
|
|
482
|
+
_id: string;
|
|
483
|
+
name: string;
|
|
484
|
+
photo: string[];
|
|
485
|
+
dimension: IDimension;
|
|
486
|
+
price: number;
|
|
487
|
+
slug: string;
|
|
488
|
+
category_id: {
|
|
489
|
+
_id: string;
|
|
490
|
+
name: string;
|
|
491
|
+
slug: string;
|
|
492
|
+
};
|
|
493
|
+
subCategory_id: {
|
|
494
|
+
_id: string;
|
|
495
|
+
name: string;
|
|
496
|
+
slug: string;
|
|
497
|
+
};
|
|
498
|
+
seller_id: {
|
|
499
|
+
_id: string;
|
|
500
|
+
shop_details: IShopDetails;
|
|
501
|
+
delivery_ways: IDeliveryWays;
|
|
502
|
+
shops_info: IShop[];
|
|
503
|
+
slug: string;
|
|
504
|
+
};
|
|
505
|
+
f_price: number | null;
|
|
506
|
+
low_stock_flag: boolean;
|
|
507
|
+
};
|
|
508
|
+
count: number;
|
|
509
|
+
price: number;
|
|
510
|
+
discounted_price: number | null;
|
|
511
|
+
createdAt: Date;
|
|
512
|
+
updatedAt: Date;
|
|
513
|
+
}
|
|
514
|
+
|
|
515
|
+
export interface ICreateCartResponse {
|
|
516
|
+
message?: string;
|
|
517
|
+
cartItem: ICart;
|
|
518
|
+
}
|
|
519
|
+
|
|
520
|
+
export interface ISetCartItemCountRequest {
|
|
521
|
+
count: number;
|
|
522
|
+
}
|
|
523
|
+
|
|
524
|
+
export interface ICategory {
|
|
525
|
+
_id: string;
|
|
526
|
+
name: string;
|
|
527
|
+
seoInfo?: ISeoInfo;
|
|
528
|
+
photo: string;
|
|
529
|
+
number: number;
|
|
530
|
+
slug: string;
|
|
531
|
+
createdAt: Date;
|
|
532
|
+
updatedAt: Date;
|
|
533
|
+
}
|
|
534
|
+
|
|
535
|
+
export interface ISeoInfo {
|
|
536
|
+
title?: string;
|
|
537
|
+
desc?: string;
|
|
538
|
+
h1?: string;
|
|
539
|
+
seoText?: string;
|
|
540
|
+
}
|
|
541
|
+
|
|
542
|
+
export interface IAdminCategoryQueryRequest {
|
|
543
|
+
name?: string;
|
|
544
|
+
parsed: string;
|
|
545
|
+
}
|
|
546
|
+
|
|
547
|
+
export interface IGetCategoryQuery extends FilterBaseQuery {
|
|
548
|
+
parsed?: string;
|
|
549
|
+
}
|
|
550
|
+
|
|
551
|
+
export interface IParsedCategory {
|
|
552
|
+
value: string;
|
|
553
|
+
title: string;
|
|
554
|
+
type: string;
|
|
555
|
+
photo: string;
|
|
556
|
+
seoInfo?: ISeoInfo;
|
|
557
|
+
slug: string;
|
|
558
|
+
updatedAt: Date;
|
|
559
|
+
children: IParsedSubCategory[];
|
|
560
|
+
}
|
|
561
|
+
|
|
562
|
+
export interface IParsedSubCategory {
|
|
563
|
+
value: string;
|
|
564
|
+
title: string;
|
|
565
|
+
type: string;
|
|
566
|
+
seoInfo?: ISeoInfo;
|
|
567
|
+
slug: string;
|
|
568
|
+
updatedAt: Date;
|
|
569
|
+
status: ESubCategoryStatus;
|
|
570
|
+
}
|
|
571
|
+
|
|
572
|
+
export type ICategoryQueryResponse = ICategory[] | IParsedCategory[];
|
|
573
|
+
|
|
574
|
+
export interface ICreateCategoryRequest {
|
|
575
|
+
name: string;
|
|
576
|
+
title?: string;
|
|
577
|
+
desc?: string;
|
|
578
|
+
h1?: string;
|
|
579
|
+
seoText?: string;
|
|
580
|
+
photo: File;
|
|
581
|
+
}
|
|
582
|
+
|
|
583
|
+
export interface IUpdateCategoryRequest
|
|
584
|
+
extends Partial<ICreateCategoryRequest> {
|
|
585
|
+
toDeletePhoto?: string;
|
|
586
|
+
}
|
|
587
|
+
|
|
588
|
+
export interface ISubCategory {
|
|
589
|
+
_id: string;
|
|
590
|
+
name: string;
|
|
591
|
+
category_id: ICategory;
|
|
592
|
+
status: ESubCategoryStatus;
|
|
593
|
+
seoInfo?: ISeoInfo;
|
|
594
|
+
suggested_characteristics?: ISuggestedCharacteristic[];
|
|
595
|
+
slug: string;
|
|
596
|
+
number: number;
|
|
597
|
+
createdAt: Date;
|
|
598
|
+
updatedAt: Date;
|
|
599
|
+
}
|
|
600
|
+
|
|
601
|
+
export interface IUserSubCategoryResponse {
|
|
602
|
+
subCategories: ISubCategory[];
|
|
603
|
+
productsCount: number;
|
|
604
|
+
}
|
|
605
|
+
|
|
606
|
+
export interface ICreateSubCategoryRequest {
|
|
607
|
+
name: string;
|
|
608
|
+
category_id: string;
|
|
609
|
+
title?: string;
|
|
610
|
+
desc?: string;
|
|
611
|
+
h1?: string;
|
|
612
|
+
seoText?: string;
|
|
613
|
+
suggested_characteristics?: ISuggestedCharacteristic[];
|
|
614
|
+
}
|
|
615
|
+
|
|
616
|
+
export interface ISuggestedCharacteristic {
|
|
617
|
+
name: string;
|
|
618
|
+
values: string[];
|
|
619
|
+
}
|
|
620
|
+
|
|
621
|
+
export interface IUpdateSubCategoryRequest
|
|
622
|
+
extends Partial<ICreateSubCategoryRequest> {}
|
|
623
|
+
|
|
624
|
+
export enum ESubCategoryStatus {
|
|
625
|
+
MODERATION = 'MODERATION',
|
|
626
|
+
ACTIVE = 'ACTIVE',
|
|
627
|
+
ARCHIVED = 'ARCHIVED',
|
|
628
|
+
}
|
|
629
|
+
|
|
630
|
+
export interface IBankingDetails {
|
|
631
|
+
name: string;
|
|
632
|
+
INN: string;
|
|
633
|
+
BIK: string;
|
|
634
|
+
KPP: string;
|
|
635
|
+
PC: string;
|
|
636
|
+
KC: string;
|
|
637
|
+
legal_address: string;
|
|
638
|
+
}
|
|
639
|
+
|
|
640
|
+
export type ILegalBankingDetails = Omit<
|
|
641
|
+
IBankingDetails,
|
|
642
|
+
'KPP' | 'legal_address'
|
|
643
|
+
>;
|
|
644
|
+
export type IPhysicalBankingDetails = Partial<
|
|
645
|
+
Omit<IBankingDetails, 'legal_address'>
|
|
646
|
+
> & { INN: string };
|
|
647
|
+
|
|
648
|
+
export interface IShopDetails {
|
|
649
|
+
shop_name: string;
|
|
650
|
+
logo: string;
|
|
651
|
+
banner: string;
|
|
652
|
+
desc: string;
|
|
653
|
+
}
|
|
654
|
+
|
|
655
|
+
export interface IDeliveryWays {
|
|
656
|
+
pickup: boolean;
|
|
657
|
+
// own_delivery: boolean; // Появится в ближайшем будущем
|
|
658
|
+
delivery_to_point: boolean;
|
|
659
|
+
courier: boolean;
|
|
660
|
+
yandex_express: boolean;
|
|
661
|
+
}
|
|
662
|
+
|
|
663
|
+
export enum ESellerStatus {
|
|
664
|
+
WAITING_APPROVE = 'WAITING_APPROVE',
|
|
665
|
+
APPROVED = 'APPROVED',
|
|
666
|
+
DECLINED = 'DECLINED',
|
|
667
|
+
ARCHIVED = 'ARCHIVED',
|
|
668
|
+
}
|
|
669
|
+
|
|
670
|
+
export interface IUserSellerStatusResponse {
|
|
671
|
+
status: ESellerStatus | 'NOT_CREATED';
|
|
672
|
+
}
|
|
673
|
+
|
|
674
|
+
export interface IBalanceInfo {
|
|
675
|
+
balance: number;
|
|
676
|
+
total_turnover: number;
|
|
677
|
+
withdrawn: number;
|
|
678
|
+
}
|
|
679
|
+
|
|
680
|
+
export interface IShopAddress {
|
|
681
|
+
name: string;
|
|
682
|
+
lat: number;
|
|
683
|
+
lng: number;
|
|
684
|
+
}
|
|
685
|
+
|
|
686
|
+
export interface IShopWorkTime {
|
|
687
|
+
time: string;
|
|
688
|
+
}
|
|
689
|
+
|
|
690
|
+
export interface IShop {
|
|
691
|
+
_id: string;
|
|
692
|
+
name: string;
|
|
693
|
+
address: IShopAddress;
|
|
694
|
+
nearest_metro_station: string;
|
|
695
|
+
work_time?: IShopWorkTime[];
|
|
696
|
+
createdAt: Date;
|
|
697
|
+
updatedAt: Date;
|
|
698
|
+
}
|
|
699
|
+
|
|
700
|
+
export interface INearestPointOfCdek {
|
|
701
|
+
code: string;
|
|
702
|
+
name: string;
|
|
703
|
+
location: {
|
|
704
|
+
country_code: string;
|
|
705
|
+
region_code: number;
|
|
706
|
+
region: string;
|
|
707
|
+
city_code: number;
|
|
708
|
+
city: string;
|
|
709
|
+
postal_code: string;
|
|
710
|
+
longitude: number;
|
|
711
|
+
latitude: number;
|
|
712
|
+
address: string;
|
|
713
|
+
address_full: string;
|
|
714
|
+
};
|
|
715
|
+
}
|
|
716
|
+
|
|
717
|
+
export interface IMoySklad {
|
|
718
|
+
account_id: string | null;
|
|
719
|
+
api_token: string | null;
|
|
720
|
+
}
|
|
721
|
+
|
|
722
|
+
export interface ISeller {
|
|
723
|
+
_id: string;
|
|
724
|
+
type: ESellerTypes;
|
|
725
|
+
user_id: {
|
|
726
|
+
_id: string;
|
|
727
|
+
tel: number;
|
|
728
|
+
name: string;
|
|
729
|
+
surname: string;
|
|
730
|
+
full_name: string;
|
|
731
|
+
patronymic?: string;
|
|
732
|
+
email: string;
|
|
733
|
+
birthday: Date;
|
|
734
|
+
};
|
|
735
|
+
shops_info: IShop[];
|
|
736
|
+
nearest_point_of_cdek: INearestPointOfCdek;
|
|
737
|
+
banking_details: IBankingDetails;
|
|
738
|
+
additional_info?: ISellerAdditionalInfo;
|
|
739
|
+
company_info?: ISellerCompanyInfo;
|
|
740
|
+
shop_details: IShopDetails;
|
|
741
|
+
delivery_ways: IDeliveryWays;
|
|
742
|
+
balance_info: IBalanceInfo;
|
|
743
|
+
moy_sklad?: IMoySklad;
|
|
744
|
+
commission: number;
|
|
745
|
+
status: ESellerStatus;
|
|
746
|
+
telegram_message_id: number | null;
|
|
747
|
+
api_token: string | null;
|
|
748
|
+
slug: string;
|
|
749
|
+
telegram_chat_id: number | null;
|
|
750
|
+
telegram_api_token: string;
|
|
751
|
+
number: number;
|
|
752
|
+
createdAt: Date;
|
|
753
|
+
updatedAt: Date;
|
|
754
|
+
}
|
|
755
|
+
|
|
756
|
+
export interface ISellerShowcaseResponse {
|
|
757
|
+
purchasesCount: number;
|
|
758
|
+
averageRating: string;
|
|
759
|
+
reviewsCount: number;
|
|
760
|
+
seller: ISeller;
|
|
761
|
+
promoCode: IPromoCode | null;
|
|
762
|
+
}
|
|
763
|
+
|
|
764
|
+
export interface ISellerSearchQueryRequest {
|
|
765
|
+
name?: string;
|
|
766
|
+
}
|
|
767
|
+
|
|
768
|
+
export interface IAdminSellersQueryRequest extends FilterBaseQuery {
|
|
769
|
+
number?: string;
|
|
770
|
+
status?: string;
|
|
771
|
+
full_name?: string;
|
|
772
|
+
shop_name?: string;
|
|
773
|
+
tel?: string;
|
|
774
|
+
all_fields?: string;
|
|
775
|
+
}
|
|
776
|
+
|
|
777
|
+
export interface IAdminSellersQueryResponse {
|
|
778
|
+
sellers: ISeller[];
|
|
779
|
+
count: number;
|
|
780
|
+
}
|
|
781
|
+
|
|
782
|
+
export interface ISellerInfo {
|
|
783
|
+
name: string;
|
|
784
|
+
surname: string;
|
|
785
|
+
patronymic?: string;
|
|
786
|
+
email: string;
|
|
787
|
+
tel: number;
|
|
788
|
+
type: ESellerTypes;
|
|
789
|
+
opt_otch: boolean;
|
|
790
|
+
birthday?: string;
|
|
791
|
+
}
|
|
792
|
+
|
|
793
|
+
export interface ICreateSellerInfo extends ISellerInfo {
|
|
794
|
+
password: string;
|
|
795
|
+
}
|
|
796
|
+
|
|
797
|
+
export type ICreateShopDetails = Omit<IShopDetails, 'logo' | 'banner'>;
|
|
798
|
+
|
|
799
|
+
export interface IAdminCreateSellerRequest {
|
|
800
|
+
seller_info: ICreateSellerInfo;
|
|
801
|
+
banking_details: ILegalBankingDetails;
|
|
802
|
+
shop_details: ICreateShopDetails;
|
|
803
|
+
logo: File | File[];
|
|
804
|
+
banner: File | File[];
|
|
805
|
+
}
|
|
806
|
+
|
|
807
|
+
export interface ICreateSellerRequest {
|
|
808
|
+
type: ESellerTypes;
|
|
809
|
+
name: string;
|
|
810
|
+
surname: string;
|
|
811
|
+
patronymic?: string;
|
|
812
|
+
tel: number;
|
|
813
|
+
INN: string;
|
|
814
|
+
shop_name: string;
|
|
815
|
+
send_email?: boolean;
|
|
816
|
+
opt_otch: boolean;
|
|
817
|
+
}
|
|
818
|
+
|
|
819
|
+
export interface IUpdateSellerRequest {
|
|
820
|
+
seller_info: Partial<ISellerInfo>;
|
|
821
|
+
banking_details: Partial<IBankingDetails>;
|
|
822
|
+
shop_details: ICreateShopDetails;
|
|
823
|
+
company_info: Partial<ISellerCompanyInfo>;
|
|
824
|
+
logo: File | File[] | string;
|
|
825
|
+
banner: File | File[] | string;
|
|
826
|
+
seller_id: string;
|
|
827
|
+
toDeletePhotos?: string[];
|
|
828
|
+
passport_details?: string;
|
|
829
|
+
passport_photo?: File | File[] | string;
|
|
830
|
+
card_number?: string;
|
|
831
|
+
}
|
|
832
|
+
|
|
833
|
+
export interface IActionsSellersRequest {
|
|
834
|
+
toDelete: string;
|
|
835
|
+
}
|
|
836
|
+
|
|
837
|
+
export interface ICreateSellerShopRequest {
|
|
838
|
+
seller_id: string;
|
|
839
|
+
name: string;
|
|
840
|
+
address: {
|
|
841
|
+
name: string;
|
|
842
|
+
lat: number;
|
|
843
|
+
lng: number;
|
|
844
|
+
};
|
|
845
|
+
work_time?: IShopWorkTime[];
|
|
846
|
+
}
|
|
847
|
+
|
|
848
|
+
export interface IAdminUpdateNearestPointOfCdekRequest
|
|
849
|
+
extends INearestPointOfCdek {
|
|
850
|
+
seller_id: string;
|
|
851
|
+
}
|
|
852
|
+
|
|
853
|
+
export interface IAdminUpdateDeliveryWaysRequest extends IDeliveryWays {
|
|
854
|
+
seller_id: string;
|
|
855
|
+
}
|
|
856
|
+
|
|
857
|
+
export interface IAdminChangeOrderStatus {
|
|
858
|
+
orderId: string;
|
|
859
|
+
status: EOrderStatus;
|
|
860
|
+
reason_of_cancel?: string;
|
|
861
|
+
}
|
|
862
|
+
|
|
863
|
+
export interface IAdminDenyItem {
|
|
864
|
+
item_id: string;
|
|
865
|
+
}
|
|
866
|
+
|
|
867
|
+
export interface IAdminRemoveOrderItemRequest {
|
|
868
|
+
current_items: IPopulatedOrderItem[];
|
|
869
|
+
}
|
|
870
|
+
|
|
871
|
+
export interface IAdminOrdersQueryRequest extends FilterBaseQuery {
|
|
872
|
+
name?: string;
|
|
873
|
+
from?: string;
|
|
874
|
+
to?: string;
|
|
875
|
+
number?: string;
|
|
876
|
+
sum?: 'asc' | 'desc';
|
|
877
|
+
status?: EOrderStatus;
|
|
878
|
+
tel?: string;
|
|
879
|
+
seller_id?: string;
|
|
880
|
+
}
|
|
881
|
+
|
|
882
|
+
export type IPopulatedOrderSeller = Pick<
|
|
883
|
+
ISeller,
|
|
884
|
+
'_id' | 'shop_details' | 'user_id' | 'nearest_point_of_cdek' | 'slug'
|
|
885
|
+
>;
|
|
886
|
+
|
|
887
|
+
export type IPopulatedOrderUser = Pick<
|
|
888
|
+
IUser,
|
|
889
|
+
| '_id'
|
|
890
|
+
| 'name'
|
|
891
|
+
| 'full_name'
|
|
892
|
+
| 'surname'
|
|
893
|
+
| 'patronymic'
|
|
894
|
+
| 'tel'
|
|
895
|
+
| 'email'
|
|
896
|
+
| 'birthday'
|
|
897
|
+
>;
|
|
898
|
+
|
|
899
|
+
export type TPopulatedProductId = Pick<
|
|
900
|
+
IProduct,
|
|
901
|
+
'_id' | 'name' | 'vendor_code' | 'photo' | 'discount'
|
|
902
|
+
>;
|
|
903
|
+
|
|
904
|
+
export interface IPopulatedOrderItem
|
|
905
|
+
extends Omit<IOrderItem, 'product_id'> {
|
|
906
|
+
product_id: IProductResponse;
|
|
907
|
+
}
|
|
908
|
+
|
|
909
|
+
export type IPopulatedOrder = Omit<
|
|
910
|
+
IOrder,
|
|
911
|
+
'items' | 'seller_id' | 'user_id' | 'shop_id'
|
|
912
|
+
> & {
|
|
913
|
+
items: IPopulatedOrderItem[];
|
|
914
|
+
seller_id?: IPopulatedOrderSeller;
|
|
915
|
+
user_id?: IPopulatedOrderUser;
|
|
916
|
+
shop_id: IShop;
|
|
917
|
+
};
|
|
918
|
+
|
|
919
|
+
export interface IAdminGetOrderResponse {
|
|
920
|
+
order: IPopulatedOrder;
|
|
921
|
+
commission: number;
|
|
922
|
+
}
|
|
923
|
+
|
|
924
|
+
export interface IAdminOrdersQueryResponse {
|
|
925
|
+
orders: IPopulatedOrder[];
|
|
926
|
+
count: number;
|
|
927
|
+
}
|
|
928
|
+
|
|
929
|
+
export interface IAdminDeliveryInfo {
|
|
930
|
+
receive_method: ERecieveMethod;
|
|
931
|
+
preparation_date: Date;
|
|
932
|
+
address?: string;
|
|
933
|
+
shop_id?: string;
|
|
934
|
+
}
|
|
935
|
+
|
|
936
|
+
export interface IAdminCdekInfo {
|
|
937
|
+
delivery_sum: number;
|
|
938
|
+
tracking: string;
|
|
939
|
+
}
|
|
940
|
+
|
|
941
|
+
export interface IAdminUpdateOrderRequest {
|
|
942
|
+
note?: string;
|
|
943
|
+
delivery_info: Partial<IAdminDeliveryInfo>;
|
|
944
|
+
cdek_info?: Partial<IAdminCdekInfo>;
|
|
945
|
+
invoice?: File;
|
|
946
|
+
items: IPopulatedOrderItem[];
|
|
947
|
+
}
|
|
948
|
+
|
|
949
|
+
export type OrderAddress = Omit<
|
|
950
|
+
IAddress,
|
|
951
|
+
'user_id' | '_id' | 'createdAt' | 'updatedAt'
|
|
952
|
+
>;
|
|
953
|
+
|
|
954
|
+
export enum EOrderStatus {
|
|
955
|
+
NOT_PAID = 'NOT_PAID',
|
|
956
|
+
ON_CONFIRMATION = 'ON_CONFIRMATION',
|
|
957
|
+
CONFIRMED_BY_SELLER = 'CONFIRMED_BY_SELLER',
|
|
958
|
+
IN_DELIVERY = 'IN_DELIVERY',
|
|
959
|
+
WAITING_IN_POINT = 'WAITING_IN_POINT',
|
|
960
|
+
FINISHED = 'FINISHED',
|
|
961
|
+
CANCELED = 'CANCELED',
|
|
962
|
+
ARCHIVED = 'ARCHIVED',
|
|
963
|
+
}
|
|
964
|
+
|
|
965
|
+
export interface IDeliveryAddress extends OrderAddress {
|
|
966
|
+
lat: number;
|
|
967
|
+
lng: number;
|
|
968
|
+
}
|
|
969
|
+
|
|
970
|
+
export interface IDeliveryInfo {
|
|
971
|
+
delivery_sum: number;
|
|
972
|
+
address: IDeliveryAddress;
|
|
973
|
+
tel: number;
|
|
974
|
+
full_name: string;
|
|
975
|
+
yandex_uuid?: string;
|
|
976
|
+
cdek_barcode?: string;
|
|
977
|
+
type?: DeliveryTypes;
|
|
978
|
+
yandex_offer?: OfferDto;
|
|
979
|
+
comment?: string;
|
|
980
|
+
}
|
|
981
|
+
|
|
982
|
+
export interface IPVZ {
|
|
983
|
+
code: string;
|
|
984
|
+
name: string;
|
|
985
|
+
location: {
|
|
986
|
+
country_code: string;
|
|
987
|
+
region_code: number;
|
|
988
|
+
region: string;
|
|
989
|
+
city_code: number;
|
|
990
|
+
city: string;
|
|
991
|
+
postal_code: string;
|
|
992
|
+
longitude: number;
|
|
993
|
+
latitude: number;
|
|
994
|
+
address: string;
|
|
995
|
+
address_full: string;
|
|
996
|
+
};
|
|
997
|
+
phones: [
|
|
998
|
+
{
|
|
999
|
+
number: string;
|
|
1000
|
+
}
|
|
1001
|
+
];
|
|
1002
|
+
email: string;
|
|
1003
|
+
delivery_sum: number;
|
|
1004
|
+
}
|
|
1005
|
+
|
|
1006
|
+
export interface IPickUpPoint {
|
|
1007
|
+
shop_id: string;
|
|
1008
|
+
}
|
|
1009
|
+
|
|
1010
|
+
export enum ERecieveMethod {
|
|
1011
|
+
PICKUP_POINT = 'PICKUP_POINT',
|
|
1012
|
+
COURIER = 'COURIER',
|
|
1013
|
+
PVZ = 'PVZ',
|
|
1014
|
+
EXPRESS = 'EXPRESS',
|
|
1015
|
+
}
|
|
1016
|
+
|
|
1017
|
+
export enum EOrderItemsStatus {
|
|
1018
|
+
AGREED = 'AGREED',
|
|
1019
|
+
DENIED = 'DENIED',
|
|
1020
|
+
}
|
|
1021
|
+
|
|
1022
|
+
export interface IOrderItem {
|
|
1023
|
+
_id: string;
|
|
1024
|
+
product_id: string;
|
|
1025
|
+
count: number;
|
|
1026
|
+
price: number; // Сумма за одну единицу товара * количество товаров
|
|
1027
|
+
discounted_price: number | null;
|
|
1028
|
+
dimension: IDimension; // Габариты за единицу товара
|
|
1029
|
+
items_status: EOrderItemsStatus;
|
|
1030
|
+
}
|
|
1031
|
+
|
|
1032
|
+
export interface ICheckIsAlsoInStock {
|
|
1033
|
+
cartItems: ICart[];
|
|
1034
|
+
}
|
|
1035
|
+
|
|
1036
|
+
export interface ICreateOrder {
|
|
1037
|
+
items: Omit<IOrderItem, '_id' | 'items_status'>[];
|
|
1038
|
+
receive_method: ERecieveMethod;
|
|
1039
|
+
receive_method_data: IDeliveryInfo | IPVZ | IPickUpPoint;
|
|
1040
|
+
seller_id: string;
|
|
1041
|
+
}
|
|
1042
|
+
|
|
1043
|
+
export interface IGetAllOrders {
|
|
1044
|
+
user_id: string;
|
|
1045
|
+
skip: number;
|
|
1046
|
+
limit: number;
|
|
1047
|
+
}
|
|
1048
|
+
|
|
1049
|
+
export type IPopulatedOrderShop = IShop;
|
|
1050
|
+
|
|
1051
|
+
export interface IPopulatedOrderItemApp
|
|
1052
|
+
extends Omit<IOrderItem, 'product_id'> {
|
|
1053
|
+
product_id: IProductResponse;
|
|
1054
|
+
}
|
|
1055
|
+
|
|
1056
|
+
export type IPopulatedOrderUserApp = Pick<
|
|
1057
|
+
IUser,
|
|
1058
|
+
| '_id'
|
|
1059
|
+
| 'name'
|
|
1060
|
+
| 'full_name'
|
|
1061
|
+
| 'surname'
|
|
1062
|
+
| 'patronymic'
|
|
1063
|
+
| 'tel'
|
|
1064
|
+
| 'email'
|
|
1065
|
+
| 'birthday'
|
|
1066
|
+
>;
|
|
1067
|
+
|
|
1068
|
+
export type IPopulatedOrderApp = Omit<
|
|
1069
|
+
IOrder,
|
|
1070
|
+
'items' | 'shop_id' | 'user_id'
|
|
1071
|
+
> & {
|
|
1072
|
+
items: IPopulatedOrderItemApp[];
|
|
1073
|
+
user_id: IPopulatedOrderUserApp;
|
|
1074
|
+
shop_id: IPopulatedOrderShop;
|
|
1075
|
+
};
|
|
1076
|
+
|
|
1077
|
+
export enum EReasonOfCancel {
|
|
1078
|
+
CHANGED_DELIVERY_DATE = 'Перенесли срок доставки',
|
|
1079
|
+
INCORRECT_CREATED_ORDER = 'Хочу изменить заказ и оформить заново',
|
|
1080
|
+
FOUND_CHEAPER = 'Нашел дешевле',
|
|
1081
|
+
WRONG_ADDRESS = 'Указал неверный адрес',
|
|
1082
|
+
OTHER = 'Другое',
|
|
1083
|
+
}
|
|
1084
|
+
|
|
1085
|
+
export interface ICancelOrderRequest {
|
|
1086
|
+
orderId: string;
|
|
1087
|
+
reason_of_cancel: EReasonOfCancel;
|
|
1088
|
+
}
|
|
1089
|
+
|
|
1090
|
+
export interface ICreateMultiOrder {
|
|
1091
|
+
orders: ICreateOrder[];
|
|
1092
|
+
sum: number;
|
|
1093
|
+
tel: number;
|
|
1094
|
+
email: string;
|
|
1095
|
+
name: string;
|
|
1096
|
+
surname: string;
|
|
1097
|
+
patronymic?: string;
|
|
1098
|
+
}
|
|
1099
|
+
|
|
1100
|
+
export interface IDeliveryFullInfo extends IDeliveryInfo {
|
|
1101
|
+
tracking: string;
|
|
1102
|
+
invoice: string;
|
|
1103
|
+
}
|
|
1104
|
+
|
|
1105
|
+
export interface IGetCDEKOffices {
|
|
1106
|
+
weight_max?: string;
|
|
1107
|
+
city: string; // city or city_district from dadata
|
|
1108
|
+
}
|
|
1109
|
+
|
|
1110
|
+
export interface ICDEKOffice {
|
|
1111
|
+
code: string;
|
|
1112
|
+
name: string;
|
|
1113
|
+
uuid: string;
|
|
1114
|
+
address_comment: string;
|
|
1115
|
+
nearest_metro_station: string;
|
|
1116
|
+
work_time: string;
|
|
1117
|
+
phones: [
|
|
1118
|
+
{
|
|
1119
|
+
number: string;
|
|
1120
|
+
}
|
|
1121
|
+
];
|
|
1122
|
+
email: string;
|
|
1123
|
+
note: string;
|
|
1124
|
+
type: string;
|
|
1125
|
+
owner_code: string;
|
|
1126
|
+
take_only: boolean;
|
|
1127
|
+
is_handout: boolean;
|
|
1128
|
+
is_reception: boolean;
|
|
1129
|
+
is_dressing_room: boolean;
|
|
1130
|
+
is_ltl: boolean;
|
|
1131
|
+
have_cashless: boolean;
|
|
1132
|
+
have_cash: boolean;
|
|
1133
|
+
allowed_cod: boolean;
|
|
1134
|
+
site: string;
|
|
1135
|
+
work_time_list: [
|
|
1136
|
+
{
|
|
1137
|
+
day: number;
|
|
1138
|
+
time: string;
|
|
1139
|
+
}
|
|
1140
|
+
];
|
|
1141
|
+
weight_min: number;
|
|
1142
|
+
weight_max: number;
|
|
1143
|
+
location: {
|
|
1144
|
+
country_code: string;
|
|
1145
|
+
region_code: number;
|
|
1146
|
+
region: string;
|
|
1147
|
+
city_code: number;
|
|
1148
|
+
city: string;
|
|
1149
|
+
fias_guid: string;
|
|
1150
|
+
postal_code: string;
|
|
1151
|
+
longitude: number;
|
|
1152
|
+
latitude: number;
|
|
1153
|
+
address: string;
|
|
1154
|
+
address_full: string;
|
|
1155
|
+
};
|
|
1156
|
+
fulfillment: boolean;
|
|
1157
|
+
}
|
|
1158
|
+
|
|
1159
|
+
export interface GetDeliverySum {
|
|
1160
|
+
address: string;
|
|
1161
|
+
type: ERecieveMethod.COURIER | ERecieveMethod.PVZ;
|
|
1162
|
+
items: Omit<IOrderItem, '_id' | 'items_status'>[];
|
|
1163
|
+
seller_id: string;
|
|
1164
|
+
}
|
|
1165
|
+
|
|
1166
|
+
export interface IDeliverySum {
|
|
1167
|
+
delivery_sum: number;
|
|
1168
|
+
period_min: number;
|
|
1169
|
+
period_max: number;
|
|
1170
|
+
calendar_min: number;
|
|
1171
|
+
calendar_max: number;
|
|
1172
|
+
weight_calc: number;
|
|
1173
|
+
services: [
|
|
1174
|
+
{
|
|
1175
|
+
code: string;
|
|
1176
|
+
sum: number;
|
|
1177
|
+
}
|
|
1178
|
+
];
|
|
1179
|
+
total_sum: number;
|
|
1180
|
+
currency: string;
|
|
1181
|
+
}
|
|
1182
|
+
|
|
1183
|
+
export interface IOrder {
|
|
1184
|
+
_id: string;
|
|
1185
|
+
total_received: number; // Сколько всего заплатил покупатель за этот заказ (сумма товаров + доставки)
|
|
1186
|
+
current_commission: number; // Текущая комиссия продавца за заказ (Сумма товаров * комиссию продавца / 100)
|
|
1187
|
+
sum: number;
|
|
1188
|
+
original_sum: number; // Сумма без учёта скидок
|
|
1189
|
+
full_sum: number; // Сумма с учетом доставки и коммиссии сервиса
|
|
1190
|
+
weight: number; // Общий вес в граммах
|
|
1191
|
+
user_id?: string;
|
|
1192
|
+
items: IOrderItem[];
|
|
1193
|
+
seller_id?: string;
|
|
1194
|
+
receive_method: ERecieveMethod;
|
|
1195
|
+
delivery_info?: Partial<IDeliveryFullInfo>;
|
|
1196
|
+
shop_id?: string;
|
|
1197
|
+
pvz?: Partial<IPVZ>;
|
|
1198
|
+
status: EOrderStatus;
|
|
1199
|
+
preparation_date?: Date;
|
|
1200
|
+
note?: string;
|
|
1201
|
+
reason_of_cancel?: string;
|
|
1202
|
+
number: number;
|
|
1203
|
+
createdAt: Date;
|
|
1204
|
+
updatedAt: Date;
|
|
1205
|
+
type?: DeliveryTypes;
|
|
1206
|
+
yandex_offer?: OfferDto;
|
|
1207
|
+
}
|
|
1208
|
+
|
|
1209
|
+
export interface IAdminMultiOrderResponse
|
|
1210
|
+
extends Omit<IMultiOrder, 'orders'> {
|
|
1211
|
+
orders: IPopulatedOrder[];
|
|
1212
|
+
}
|
|
1213
|
+
|
|
1214
|
+
export interface IMultiOrder {
|
|
1215
|
+
_id: string;
|
|
1216
|
+
user_id: string;
|
|
1217
|
+
sum: number;
|
|
1218
|
+
orders: string[];
|
|
1219
|
+
payment_id: string | null;
|
|
1220
|
+
number: number;
|
|
1221
|
+
status: EMultiOrderStatus;
|
|
1222
|
+
createdAt: Date;
|
|
1223
|
+
updatedAt: Date;
|
|
1224
|
+
}
|
|
1225
|
+
|
|
1226
|
+
export interface IPaymentCheckResponse {
|
|
1227
|
+
id: string;
|
|
1228
|
+
status: string;
|
|
1229
|
+
amount: {
|
|
1230
|
+
value: string;
|
|
1231
|
+
currency: string;
|
|
1232
|
+
};
|
|
1233
|
+
description: string;
|
|
1234
|
+
captured_at: string;
|
|
1235
|
+
created_at: string;
|
|
1236
|
+
metadata: {
|
|
1237
|
+
multiOrderId: string;
|
|
1238
|
+
multiOrderNumber: string;
|
|
1239
|
+
};
|
|
1240
|
+
confirmation: IConfirmation;
|
|
1241
|
+
purchase_unique: boolean;
|
|
1242
|
+
}
|
|
1243
|
+
|
|
1244
|
+
export type IConfirmationType = 'embedded' | 'external' | 'qr' | 'redirect';
|
|
1245
|
+
|
|
1246
|
+
export interface IConfirmation {
|
|
1247
|
+
type: IConfirmationType;
|
|
1248
|
+
locale?: string;
|
|
1249
|
+
confirmation_token?: string;
|
|
1250
|
+
confirmation_data?: string;
|
|
1251
|
+
confirmation_url?: string;
|
|
1252
|
+
enforce?: boolean;
|
|
1253
|
+
return_url?: string;
|
|
1254
|
+
}
|
|
1255
|
+
|
|
1256
|
+
export interface IPaymentResponse {
|
|
1257
|
+
id: string;
|
|
1258
|
+
status: string;
|
|
1259
|
+
amount: {
|
|
1260
|
+
value: string;
|
|
1261
|
+
currency: string;
|
|
1262
|
+
};
|
|
1263
|
+
description: string;
|
|
1264
|
+
created_at: string;
|
|
1265
|
+
confirmation: IConfirmation;
|
|
1266
|
+
metadata: {
|
|
1267
|
+
multiOrderId: string;
|
|
1268
|
+
multiOrderNumber: string;
|
|
1269
|
+
};
|
|
1270
|
+
}
|
|
1271
|
+
|
|
1272
|
+
export enum EMultiOrderStatus {
|
|
1273
|
+
CANCELED = 'CANCELED',
|
|
1274
|
+
PAID = 'PAID',
|
|
1275
|
+
PENDING = 'PENDING',
|
|
1276
|
+
}
|
|
1277
|
+
|
|
1278
|
+
export enum EComplaintsReason {
|
|
1279
|
+
NOT_MATCH_TO_DESC = 'NOT_MATCH_TO_DESC',
|
|
1280
|
+
INCORRECT_PHOTO = 'INCORRECT_PHOTO',
|
|
1281
|
+
DAMAGED_GOODS = 'DAMAGED_GOODS',
|
|
1282
|
+
POOR_QUALITY = 'POOR_QUALITY',
|
|
1283
|
+
FRAUD = 'FRAUD',
|
|
1284
|
+
OTHER = 'OTHER',
|
|
1285
|
+
}
|
|
1286
|
+
|
|
1287
|
+
export interface IComplaints {
|
|
1288
|
+
_id: string;
|
|
1289
|
+
user_id: string;
|
|
1290
|
+
product_id: string;
|
|
1291
|
+
text?: string;
|
|
1292
|
+
reason: EComplaintsReason;
|
|
1293
|
+
}
|
|
1294
|
+
|
|
1295
|
+
export interface ICreateComplaints {
|
|
1296
|
+
product_id: string;
|
|
1297
|
+
text?: string;
|
|
1298
|
+
reason: EComplaintsReason;
|
|
1299
|
+
}
|
|
1300
|
+
|
|
1301
|
+
export enum EReviewEntityType {
|
|
1302
|
+
PRODUCT = 'PRODUCT',
|
|
1303
|
+
HORSE = 'HORSE',
|
|
1304
|
+
SERVICE = 'SERVICE',
|
|
1305
|
+
}
|
|
1306
|
+
|
|
1307
|
+
export enum ECreatorType {
|
|
1308
|
+
SELLER = 'SELLER',
|
|
1309
|
+
USER = 'USER',
|
|
1310
|
+
}
|
|
1311
|
+
|
|
1312
|
+
export interface IReview {
|
|
1313
|
+
_id: string;
|
|
1314
|
+
user_id?: string;
|
|
1315
|
+
entity_id: string;
|
|
1316
|
+
entity_type: EReviewEntityType;
|
|
1317
|
+
creator_id: string;
|
|
1318
|
+
creator_type: ECreatorType;
|
|
1319
|
+
rating: number;
|
|
1320
|
+
text: string;
|
|
1321
|
+
anonymity: boolean;
|
|
1322
|
+
}
|
|
1323
|
+
|
|
1324
|
+
export interface IReviewsRequest {
|
|
1325
|
+
entity_id: string;
|
|
1326
|
+
entity_type: EReviewEntityType;
|
|
1327
|
+
creator_id: string;
|
|
1328
|
+
creator_type: ECreatorType;
|
|
1329
|
+
}
|
|
1330
|
+
|
|
1331
|
+
export interface IGetReviewsRequest
|
|
1332
|
+
extends Partial<FilterBaseQuery & IReviewsRequest> {}
|
|
1333
|
+
|
|
1334
|
+
export interface IReviewResponse {
|
|
1335
|
+
_id: string;
|
|
1336
|
+
user_id: {
|
|
1337
|
+
_id: string;
|
|
1338
|
+
tel: number;
|
|
1339
|
+
name: string;
|
|
1340
|
+
birthday: Date;
|
|
1341
|
+
email: string;
|
|
1342
|
+
full_name: string;
|
|
1343
|
+
patronymic: string;
|
|
1344
|
+
surname: string;
|
|
1345
|
+
};
|
|
1346
|
+
entity_id: string; // ID сущности, к которой привязан отзыв (например, Product или Horse)
|
|
1347
|
+
entity_type: EReviewEntityType; // Тип сущности (Product, Horse и т.д.)
|
|
1348
|
+
creator_id: string; // ID создателя сущности (продавец или пользователь)
|
|
1349
|
+
creator_type: ECreatorType; // Тип создателя (SELLER или USER)
|
|
1350
|
+
rating: number;
|
|
1351
|
+
text?: string;
|
|
1352
|
+
anonymity: boolean;
|
|
1353
|
+
createdAt: Date;
|
|
1354
|
+
updatedAt: Date;
|
|
1355
|
+
}
|
|
1356
|
+
|
|
1357
|
+
export interface IGetReviewDataRequest extends Partial<IReviewsRequest> {}
|
|
1358
|
+
|
|
1359
|
+
export interface IReviewsData {
|
|
1360
|
+
count: number;
|
|
1361
|
+
averageRating: string;
|
|
1362
|
+
sellerName?: string;
|
|
1363
|
+
}
|
|
1364
|
+
|
|
1365
|
+
export interface ICreateReviewRequest {
|
|
1366
|
+
entity_id: string;
|
|
1367
|
+
entity_type: EReviewEntityType;
|
|
1368
|
+
text?: string;
|
|
1369
|
+
anonymity: boolean;
|
|
1370
|
+
rating: number;
|
|
1371
|
+
}
|
|
1372
|
+
|
|
1373
|
+
export interface IDeleteReviewQuery {
|
|
1374
|
+
toDelete: string;
|
|
1375
|
+
}
|
|
1376
|
+
|
|
1377
|
+
export enum ESellerTransactionsType {
|
|
1378
|
+
SALE = 'SALE',
|
|
1379
|
+
FINE = 'FINE',
|
|
1380
|
+
WITHDRAW = 'WITHDRAW',
|
|
1381
|
+
REFUND = 'REFUND',
|
|
1382
|
+
}
|
|
1383
|
+
|
|
1384
|
+
export interface ISellerTransactions {
|
|
1385
|
+
_id: string;
|
|
1386
|
+
total_received: number; // Сумма которую оплатил покупатель за этот заказ (сумма товаров + сумма доставки)
|
|
1387
|
+
type: ESellerTransactionsType;
|
|
1388
|
+
sum: number;
|
|
1389
|
+
original_sum: number;
|
|
1390
|
+
admin_id?: string;
|
|
1391
|
+
order_id: string;
|
|
1392
|
+
comment?: string;
|
|
1393
|
+
commission: number;
|
|
1394
|
+
delivery_sum?: number;
|
|
1395
|
+
payment_id: string;
|
|
1396
|
+
seller_id: string;
|
|
1397
|
+
createdAt: Date;
|
|
1398
|
+
updatedAt: Date;
|
|
1399
|
+
}
|
|
1400
|
+
|
|
1401
|
+
export interface ICreateSellerTransactions {
|
|
1402
|
+
type: ESellerTransactionsType;
|
|
1403
|
+
sum: number;
|
|
1404
|
+
comment?: string;
|
|
1405
|
+
}
|
|
1406
|
+
|
|
1407
|
+
export interface IAdminGetTransactionsRequest extends FilterBaseQuery {
|
|
1408
|
+
type?: ESellerTransactionsType;
|
|
1409
|
+
sum?: 'asc' | 'desc';
|
|
1410
|
+
from?: string;
|
|
1411
|
+
to?: string;
|
|
1412
|
+
seller_id?: string;
|
|
1413
|
+
order_id?: string;
|
|
1414
|
+
}
|
|
1415
|
+
|
|
1416
|
+
export interface IAdminTransactionsQueryResponse {
|
|
1417
|
+
transactions: ISellerTransactions[];
|
|
1418
|
+
count: number;
|
|
1419
|
+
}
|
|
1420
|
+
|
|
1421
|
+
export interface IAdminTopSalesQueryRequest extends FilterBaseQuery {
|
|
1422
|
+
seller_id: string;
|
|
1423
|
+
}
|
|
1424
|
+
|
|
1425
|
+
export interface IAdminTopSalesResponse {
|
|
1426
|
+
products: IProduct[];
|
|
1427
|
+
count: number;
|
|
1428
|
+
}
|
|
1429
|
+
|
|
1430
|
+
export interface IAdminChangeCommissionRequest {
|
|
1431
|
+
commission: number;
|
|
1432
|
+
}
|
|
1433
|
+
|
|
1434
|
+
export interface IAdminChangeCommissionResponse {
|
|
1435
|
+
commission: number;
|
|
1436
|
+
}
|
|
1437
|
+
|
|
1438
|
+
export interface IAdminGetChartDataQueryRequest {
|
|
1439
|
+
year: string;
|
|
1440
|
+
seller_id: string;
|
|
1441
|
+
}
|
|
1442
|
+
|
|
1443
|
+
export interface IAdminGetChartDataResponse {
|
|
1444
|
+
[key: string]: number;
|
|
1445
|
+
}
|
|
1446
|
+
|
|
1447
|
+
export interface IAdminCreateSellerTransactionRequest {
|
|
1448
|
+
type: ESellerTransactionsType;
|
|
1449
|
+
sum: number;
|
|
1450
|
+
}
|
|
1451
|
+
|
|
1452
|
+
export interface IAdminAddCustomRefundTransactionRequest {
|
|
1453
|
+
custom_sum: number;
|
|
1454
|
+
comment: string;
|
|
1455
|
+
}
|
|
1456
|
+
|
|
1457
|
+
export enum ENotificationType {
|
|
1458
|
+
ORDER = 'ORDER',
|
|
1459
|
+
PRODUCT = 'PRODUCT',
|
|
1460
|
+
COLLECTION = 'COLLECTION',
|
|
1461
|
+
FAVORITES = 'FAVORITES',
|
|
1462
|
+
}
|
|
1463
|
+
|
|
1464
|
+
export interface IAdminChangeSellerStatusRequest {
|
|
1465
|
+
status: ESellerStatus.APPROVED | ESellerStatus.DECLINED;
|
|
1466
|
+
}
|
|
1467
|
+
|
|
1468
|
+
export enum ESellerTypes {
|
|
1469
|
+
PHYSICAL = 'PHYSICAL', // Физическое лицо
|
|
1470
|
+
LEGAL = 'LEGAL', // Юридическое лицо
|
|
1471
|
+
}
|
|
1472
|
+
|
|
1473
|
+
export enum ESellerLegalTypes {
|
|
1474
|
+
LEGAL = 'LEGAL',
|
|
1475
|
+
INDIVIDUAL = 'INDIVIDUAL',
|
|
1476
|
+
}
|
|
1477
|
+
|
|
1478
|
+
export enum ESellerLocaleTypes {
|
|
1479
|
+
PHYSICAL = 'Физическое лицо',
|
|
1480
|
+
LEGAL = 'Юридическое лицо',
|
|
1481
|
+
}
|
|
1482
|
+
|
|
1483
|
+
export interface IGetInfoOfLegalRequest {
|
|
1484
|
+
INN: string;
|
|
1485
|
+
}
|
|
1486
|
+
|
|
1487
|
+
export interface IСheckCleanOfPassportRequest {
|
|
1488
|
+
passport_details: string;
|
|
1489
|
+
}
|
|
1490
|
+
|
|
1491
|
+
export interface ICleanPassportResponse {
|
|
1492
|
+
source: string;
|
|
1493
|
+
series: string;
|
|
1494
|
+
number: string;
|
|
1495
|
+
qc: number; // Check EPassportQc
|
|
1496
|
+
}
|
|
1497
|
+
|
|
1498
|
+
export enum EPassportQc {
|
|
1499
|
+
'Действующий паспорт' = 0,
|
|
1500
|
+
'Неправильный формат серии или номера' = 1,
|
|
1501
|
+
'Исходное значение пустое' = 2,
|
|
1502
|
+
'Недействительный паспорт' = 10,
|
|
1503
|
+
}
|
|
1504
|
+
|
|
1505
|
+
export enum ECompanyStatus {
|
|
1506
|
+
'ACTIVE' = 'ACTIVE',
|
|
1507
|
+
'LIQUIDATING' = 'LIQUIDATING',
|
|
1508
|
+
'LIQUIDATED' = 'LIQUIDATED',
|
|
1509
|
+
'BANKRUPT' = 'BANKRUPT',
|
|
1510
|
+
'REORGANIZING' = 'REORGANIZING',
|
|
1511
|
+
}
|
|
1512
|
+
|
|
1513
|
+
export interface ISuggestion {
|
|
1514
|
+
value: string; // Название компании
|
|
1515
|
+
unrestricted_value: string;
|
|
1516
|
+
data: {
|
|
1517
|
+
kpp: string;
|
|
1518
|
+
branch_type: string;
|
|
1519
|
+
type: ESellerLegalTypes;
|
|
1520
|
+
state: {
|
|
1521
|
+
status: ECompanyStatus;
|
|
1522
|
+
code: null;
|
|
1523
|
+
};
|
|
1524
|
+
name: {
|
|
1525
|
+
full_with_opf: string;
|
|
1526
|
+
short_with_opf: string;
|
|
1527
|
+
};
|
|
1528
|
+
inn: string;
|
|
1529
|
+
ogrn: string;
|
|
1530
|
+
okpo: string;
|
|
1531
|
+
address: {
|
|
1532
|
+
value: string;
|
|
1533
|
+
};
|
|
1534
|
+
};
|
|
1535
|
+
}
|
|
1536
|
+
|
|
1537
|
+
export interface ICreatePhysicalSellerRequest extends ICreateSellerRequest {
|
|
1538
|
+
birthday: string;
|
|
1539
|
+
passport_details: string;
|
|
1540
|
+
passport_photo: File;
|
|
1541
|
+
}
|
|
1542
|
+
|
|
1543
|
+
export interface ISellerAdditionalInfo {
|
|
1544
|
+
passport_details?: string;
|
|
1545
|
+
passport_photo?: string;
|
|
1546
|
+
card_number?: string;
|
|
1547
|
+
}
|
|
1548
|
+
|
|
1549
|
+
export interface ISellerCompanyInfo {
|
|
1550
|
+
name: string;
|
|
1551
|
+
okpo: string;
|
|
1552
|
+
ogrn: string;
|
|
1553
|
+
type: ESellerLegalTypes;
|
|
1554
|
+
}
|
|
1555
|
+
|
|
1556
|
+
export interface IGetInfoOfPhysicRequest {
|
|
1557
|
+
name: string;
|
|
1558
|
+
surname: string;
|
|
1559
|
+
patronymic?: string;
|
|
1560
|
+
birthday: Date;
|
|
1561
|
+
passport_details: string;
|
|
1562
|
+
opt_otch: boolean;
|
|
1563
|
+
INN: string;
|
|
1564
|
+
}
|
|
1565
|
+
|
|
1566
|
+
export interface IGetInfoOfPhysicResponse {
|
|
1567
|
+
inn?: string;
|
|
1568
|
+
captcha_required: boolean;
|
|
1569
|
+
code: string; // 0 - Не найден, 1 - Все окей
|
|
1570
|
+
}
|
|
1571
|
+
|
|
1572
|
+
export interface ICheckSellerDataForCorrectness {
|
|
1573
|
+
name: string;
|
|
1574
|
+
surname: string;
|
|
1575
|
+
patronymic?: string;
|
|
1576
|
+
opt_otch: boolean;
|
|
1577
|
+
INN: string;
|
|
1578
|
+
birthday: Date;
|
|
1579
|
+
passport_details: string;
|
|
1580
|
+
}
|
|
1581
|
+
|
|
1582
|
+
export enum ECheckSellerDataErrors {
|
|
1583
|
+
'INVALID_PASSPORT' = 'INVALID_PASSPORT',
|
|
1584
|
+
'INCORRECT_INN' = 'INCORRECT_INN',
|
|
1585
|
+
'INN_NOT_FOUND' = 'INN_NOT_FOUND',
|
|
1586
|
+
}
|
|
1587
|
+
|
|
1588
|
+
export interface IAdminCreatePhysicalSellerRequest
|
|
1589
|
+
extends Omit<IAdminCreateSellerRequest, 'banking_details'> {
|
|
1590
|
+
banking_details: IPhysicalBankingDetails;
|
|
1591
|
+
passport_details: string;
|
|
1592
|
+
passport_photo: File | File[];
|
|
1593
|
+
card_number?: string;
|
|
1594
|
+
}
|
|
1595
|
+
|
|
1596
|
+
export interface IUserWithSellerType extends IUser {
|
|
1597
|
+
type: EUserSellerType;
|
|
1598
|
+
}
|
|
1599
|
+
|
|
1600
|
+
export enum EUserSellerType {
|
|
1601
|
+
'PHYSICAL' = 'PHYSICAL',
|
|
1602
|
+
'LEGAL' = 'LEGAL',
|
|
1603
|
+
'NOT_SELLER' = 'NOT_SELLER',
|
|
1604
|
+
}
|
|
1605
|
+
|
|
1606
|
+
export interface IUpdateMultiOrderStatusRequest {
|
|
1607
|
+
_id: string;
|
|
1608
|
+
status: EMultiOrderStatus;
|
|
1609
|
+
reason_of_cancel: EReasonOfCancel;
|
|
1610
|
+
}
|
|
1611
|
+
|
|
1612
|
+
export interface IUserRandomProductQueryRequest extends OptionalUserQuery {
|
|
1613
|
+
size: string;
|
|
1614
|
+
category_id?: string;
|
|
1615
|
+
subCategory_id?: string;
|
|
1616
|
+
}
|
|
1617
|
+
|
|
1618
|
+
export enum ECheckForFillingSellerDataError {
|
|
1619
|
+
SHOP_IS_NOT_EXIST = 'SHOP_IS_NOT_EXIST',
|
|
1620
|
+
CDEK_POINT_IS_NOT_EXIST = 'CDEK_POINT_IS_NOT_EXIST',
|
|
1621
|
+
DELIVERY_WAYS_IS_NOT_EXIST = 'DELIVERY_WAYS_IS_NOT_EXIST',
|
|
1622
|
+
SELLER_INFO_IS_NOT_FILLED_OUT = 'SELLER_INFO_IS_NOT_FILLED_OUT',
|
|
1623
|
+
BANKING_DETAILS_IS_NOT_FILLED_OUT = 'BANKING_DETAILS_IS_NOT_FILLED_OUT',
|
|
1624
|
+
}
|
|
1625
|
+
|
|
1626
|
+
export interface IAdminCreateWithdrawalRequest {
|
|
1627
|
+
sum: number;
|
|
1628
|
+
}
|
|
1629
|
+
|
|
1630
|
+
export interface IAddressSuggestionRequest {
|
|
1631
|
+
address: string;
|
|
1632
|
+
isCityOnly?: 'true' | 'false';
|
|
1633
|
+
}
|
|
1634
|
+
|
|
1635
|
+
export interface IAddressSuggestion {
|
|
1636
|
+
value: string;
|
|
1637
|
+
unrestricted_value: string;
|
|
1638
|
+
data: {
|
|
1639
|
+
city: string;
|
|
1640
|
+
city_district: string;
|
|
1641
|
+
region_fias_id: string;
|
|
1642
|
+
city_fias_id: string;
|
|
1643
|
+
city_kladr_id: string;
|
|
1644
|
+
fias_id: string;
|
|
1645
|
+
fias_code: null;
|
|
1646
|
+
fias_level: string;
|
|
1647
|
+
kladr_id: string;
|
|
1648
|
+
geo_lat: string | null;
|
|
1649
|
+
geo_lon: string | null;
|
|
1650
|
+
};
|
|
1651
|
+
}
|
|
1652
|
+
|
|
1653
|
+
export interface IAddressSuggestionResponse {
|
|
1654
|
+
suggestions: IAddressSuggestion[];
|
|
1655
|
+
}
|
|
1656
|
+
|
|
1657
|
+
export interface IBanner {
|
|
1658
|
+
_id: string;
|
|
1659
|
+
photo: string;
|
|
1660
|
+
position: number;
|
|
1661
|
+
seller_id: string;
|
|
1662
|
+
navigation_path: string | null; // example: "ProductScreen"
|
|
1663
|
+
navigation_params: Record<string, any> | null; // example: {product_id: "ObjectId"}
|
|
1664
|
+
createdAt: Date;
|
|
1665
|
+
updatedAt: Date;
|
|
1666
|
+
}
|
|
1667
|
+
|
|
1668
|
+
export interface IMoySkladLinkerRequest {
|
|
1669
|
+
updateData: {
|
|
1670
|
+
linker_id: string;
|
|
1671
|
+
category_id: string;
|
|
1672
|
+
subCategory_id: string;
|
|
1673
|
+
}[];
|
|
1674
|
+
}
|
|
1675
|
+
|
|
1676
|
+
export interface IMoySkladLinker {
|
|
1677
|
+
pathName: string;
|
|
1678
|
+
seller_id: string;
|
|
1679
|
+
product_ids: string[];
|
|
1680
|
+
}
|
|
1681
|
+
|
|
1682
|
+
export interface IVersion {
|
|
1683
|
+
version: string;
|
|
1684
|
+
isForceToUpdate: boolean;
|
|
1685
|
+
}
|
|
1686
|
+
|
|
1687
|
+
export interface IAppVersion {
|
|
1688
|
+
ios: IVersion;
|
|
1689
|
+
android: IVersion;
|
|
1690
|
+
}
|
|
1691
|
+
|
|
1692
|
+
export interface NotificationData {
|
|
1693
|
+
body: string;
|
|
1694
|
+
data?: InternalPushMessageData | ExternalPushMessageData;
|
|
1695
|
+
title: string;
|
|
1696
|
+
}
|
|
1697
|
+
|
|
1698
|
+
export interface INotification {
|
|
1699
|
+
_id: string;
|
|
1700
|
+
user_id?: string;
|
|
1701
|
+
push_token_id: string;
|
|
1702
|
+
message: NotificationData;
|
|
1703
|
+
status: ENotificationStatus;
|
|
1704
|
+
createdAt: Date;
|
|
1705
|
+
}
|
|
1706
|
+
|
|
1707
|
+
export enum ENotificationStatus {
|
|
1708
|
+
READ = 'READ',
|
|
1709
|
+
UNREAD = 'UNREAD',
|
|
1710
|
+
}
|
|
1711
|
+
|
|
1712
|
+
export interface ISendNotifications {
|
|
1713
|
+
to: ENotificationRecipients;
|
|
1714
|
+
notificationData: NotificationData;
|
|
1715
|
+
}
|
|
1716
|
+
|
|
1717
|
+
export enum ENotificationRecipients {
|
|
1718
|
+
ALL = 'ALL',
|
|
1719
|
+
SELLERS = 'SELLERS',
|
|
1720
|
+
USERS = 'USERS',
|
|
1721
|
+
}
|
|
1722
|
+
|
|
1723
|
+
export interface IHintCharacteristics {
|
|
1724
|
+
name: string;
|
|
1725
|
+
values: string[];
|
|
1726
|
+
}
|
|
1727
|
+
|
|
1728
|
+
export interface IPossibleCombinations {
|
|
1729
|
+
combinations: ICharacteristic[][];
|
|
1730
|
+
characteristics: {
|
|
1731
|
+
name: string;
|
|
1732
|
+
values: {
|
|
1733
|
+
name: string;
|
|
1734
|
+
url: string;
|
|
1735
|
+
}[];
|
|
1736
|
+
}[];
|
|
1737
|
+
}
|
|
1738
|
+
|
|
1739
|
+
export interface IGetVariationByCharacteristics {
|
|
1740
|
+
product_id: string;
|
|
1741
|
+
characteristics: ICharacteristic[];
|
|
1742
|
+
}
|
|
1743
|
+
|
|
1744
|
+
export enum ESex {
|
|
1745
|
+
STALLION = 'stallion',
|
|
1746
|
+
MARE = 'mare',
|
|
1747
|
+
GELDING = 'gelding',
|
|
1748
|
+
}
|
|
1749
|
+
|
|
1750
|
+
export interface ICompetitionHistory {
|
|
1751
|
+
name: string;
|
|
1752
|
+
place: string;
|
|
1753
|
+
}
|
|
1754
|
+
|
|
1755
|
+
export interface ILocation {
|
|
1756
|
+
name: string;
|
|
1757
|
+
coordinates?: number[]; // [lng, lat]
|
|
1758
|
+
lat: number;
|
|
1759
|
+
lng: number;
|
|
1760
|
+
}
|
|
1761
|
+
|
|
1762
|
+
export interface IPreferredCommunication {
|
|
1763
|
+
telegram: boolean;
|
|
1764
|
+
whatsapp: boolean;
|
|
1765
|
+
calls: boolean;
|
|
1766
|
+
sms: boolean;
|
|
1767
|
+
}
|
|
1768
|
+
|
|
1769
|
+
export interface ICommunication {
|
|
1770
|
+
tel: number;
|
|
1771
|
+
preferredCommunication: IPreferredCommunication;
|
|
1772
|
+
}
|
|
1773
|
+
|
|
1774
|
+
export interface ICreateHorse {
|
|
1775
|
+
name: string;
|
|
1776
|
+
sex: ESex;
|
|
1777
|
+
breed: string;
|
|
1778
|
+
suit: string;
|
|
1779
|
+
category: string;
|
|
1780
|
+
birthDate: string;
|
|
1781
|
+
withersHeight: number;
|
|
1782
|
+
price: number;
|
|
1783
|
+
location: ILocation;
|
|
1784
|
+
images: File | File[];
|
|
1785
|
+
video_cover?: File;
|
|
1786
|
+
desc?: string;
|
|
1787
|
+
reg_number?: string;
|
|
1788
|
+
genealogy?: string;
|
|
1789
|
+
birthplace?: string;
|
|
1790
|
+
documents?: File | File[];
|
|
1791
|
+
documentsNames?: string[];
|
|
1792
|
+
competition_history?: ICompetitionHistory[];
|
|
1793
|
+
communication: ICommunication;
|
|
1794
|
+
}
|
|
1795
|
+
|
|
1796
|
+
export interface IUpdateHorse extends Partial<ICreateHorse> {
|
|
1797
|
+
toRemoveImages?: string[];
|
|
1798
|
+
toRemoveVideoCover?: string;
|
|
1799
|
+
toRemoveDocuments?: string[]; // Array of documents.fileName
|
|
1800
|
+
}
|
|
1801
|
+
|
|
1802
|
+
export enum EHorseStatus {
|
|
1803
|
+
MODERATION = 'MODERATION',
|
|
1804
|
+
PUBLISHED = 'PUBLISHED',
|
|
1805
|
+
REJECTED = 'REJECTED',
|
|
1806
|
+
ARCHIVED = 'ARCHIVED',
|
|
1807
|
+
}
|
|
1808
|
+
|
|
1809
|
+
export interface IHorse {
|
|
1810
|
+
_id: string;
|
|
1811
|
+
user_id: string;
|
|
1812
|
+
status: EHorseStatus;
|
|
1813
|
+
name: string;
|
|
1814
|
+
sex: ESex;
|
|
1815
|
+
breed: string;
|
|
1816
|
+
suit: string;
|
|
1817
|
+
birthDate: Date;
|
|
1818
|
+
category: string;
|
|
1819
|
+
withersHeight: number;
|
|
1820
|
+
price: number;
|
|
1821
|
+
location: ILocation;
|
|
1822
|
+
images: string[];
|
|
1823
|
+
video_cover: string | null;
|
|
1824
|
+
desc: string | null;
|
|
1825
|
+
reg_number: string | null;
|
|
1826
|
+
genealogy: string | null;
|
|
1827
|
+
birthplace: string | null;
|
|
1828
|
+
documents: IDocument[] | null;
|
|
1829
|
+
competition_history: ICompetitionHistory[] | null;
|
|
1830
|
+
communication: ICommunication;
|
|
1831
|
+
reason_of_cancel?: string;
|
|
1832
|
+
distance?: number; // Расстояние пользователя до лошади (если передано гео)
|
|
1833
|
+
archived_reason?: string;
|
|
1834
|
+
telegram_message_id: string | null;
|
|
1835
|
+
slug: string;
|
|
1836
|
+
number: number;
|
|
1837
|
+
published_at?: Date;
|
|
1838
|
+
entityAnalytics?: IEntityAnalytics;
|
|
1839
|
+
createdAt: Date;
|
|
1840
|
+
updatedAt: Date;
|
|
1841
|
+
}
|
|
1842
|
+
|
|
1843
|
+
export interface IDocument {
|
|
1844
|
+
name: string;
|
|
1845
|
+
fileName: string;
|
|
1846
|
+
}
|
|
1847
|
+
|
|
1848
|
+
export interface IPopulatedHorse
|
|
1849
|
+
extends Omit<IHorse, 'user_id' | 'breed' | 'suit' | 'category'> {
|
|
1850
|
+
user_id: IPopulatedOrderUserApp;
|
|
1851
|
+
breed: IBreed;
|
|
1852
|
+
suit: ISuit;
|
|
1853
|
+
category: IHorseCategory;
|
|
1854
|
+
is_favorite?: boolean;
|
|
1855
|
+
}
|
|
1856
|
+
|
|
1857
|
+
export interface IBreed {
|
|
1858
|
+
_id: string;
|
|
1859
|
+
name: string;
|
|
1860
|
+
createdAt: Date;
|
|
1861
|
+
updatedAt: Date;
|
|
1862
|
+
}
|
|
1863
|
+
|
|
1864
|
+
export interface ISuit {
|
|
1865
|
+
_id: string;
|
|
1866
|
+
name: string;
|
|
1867
|
+
createdAt: Date;
|
|
1868
|
+
updatedAt: Date;
|
|
1869
|
+
}
|
|
1870
|
+
|
|
1871
|
+
export interface IHorseCategory {
|
|
1872
|
+
_id: string;
|
|
1873
|
+
name: string;
|
|
1874
|
+
createdAt: Date;
|
|
1875
|
+
updatedAt: Date;
|
|
1876
|
+
}
|
|
1877
|
+
|
|
1878
|
+
export interface IHorseFormInformation {
|
|
1879
|
+
breeds: IBreed[];
|
|
1880
|
+
suits: ISuit[];
|
|
1881
|
+
categories: IHorseCategory[];
|
|
1882
|
+
}
|
|
1883
|
+
|
|
1884
|
+
export enum EViewCountEntityType {
|
|
1885
|
+
HORSE = 'HORSE',
|
|
1886
|
+
PRODUCT = 'PRODUCT',
|
|
1887
|
+
SERVICE = 'SERVICE',
|
|
1888
|
+
}
|
|
1889
|
+
|
|
1890
|
+
export interface IViewCount {
|
|
1891
|
+
entity_type: EViewCountEntityType;
|
|
1892
|
+
entity_id: string;
|
|
1893
|
+
count: number;
|
|
1894
|
+
createdAt: Date;
|
|
1895
|
+
updatedAt: Date;
|
|
1896
|
+
}
|
|
1897
|
+
|
|
1898
|
+
export interface IPopulatedHorseWViewCount extends IPopulatedHorse {
|
|
1899
|
+
viewCount: IViewCount;
|
|
1900
|
+
}
|
|
1901
|
+
|
|
1902
|
+
export interface IGetCombinedHorses {
|
|
1903
|
+
user_id?: string; // objectid
|
|
1904
|
+
sex?: 'stallion' | 'mare' | 'gelding';
|
|
1905
|
+
breed?: string; // objectid
|
|
1906
|
+
suit?: string; // objectid
|
|
1907
|
+
ageMin?: string;
|
|
1908
|
+
ageMax?: string;
|
|
1909
|
+
withersHeightMin?: string;
|
|
1910
|
+
withersHeightMax?: string;
|
|
1911
|
+
priceMin?: string;
|
|
1912
|
+
priceMax?: string;
|
|
1913
|
+
category?: string; // objectid
|
|
1914
|
+
lat?: string; // user lat
|
|
1915
|
+
lng?: string; // user lng
|
|
1916
|
+
radius?: string;
|
|
1917
|
+
}
|
|
1918
|
+
|
|
1919
|
+
export interface IReverseGeocodingRequest {
|
|
1920
|
+
lat: number;
|
|
1921
|
+
lon: number;
|
|
1922
|
+
count?: number;
|
|
1923
|
+
radius_meters?: number;
|
|
1924
|
+
}
|
|
1925
|
+
|
|
1926
|
+
export interface IHorseQueryRequest extends FilterBaseQuery {}
|
|
1927
|
+
|
|
1928
|
+
export interface IAdminHorsesQueryResponse {
|
|
1929
|
+
horses: IPopulatedHorse[];
|
|
1930
|
+
count: number;
|
|
1931
|
+
}
|
|
1932
|
+
|
|
1933
|
+
export interface IActionsHorseRequest {
|
|
1934
|
+
toDelete: string;
|
|
1935
|
+
}
|
|
1936
|
+
|
|
1937
|
+
export interface IAdminChangeHorseStatusRequest {
|
|
1938
|
+
status: EHorseStatus;
|
|
1939
|
+
reason_of_cancel?: string;
|
|
1940
|
+
}
|
|
1941
|
+
|
|
1942
|
+
export interface InternalPushMessageData {
|
|
1943
|
+
type: ENotificationType;
|
|
1944
|
+
typeId: string;
|
|
1945
|
+
typeSlug?: string | null;
|
|
1946
|
+
}
|
|
1947
|
+
|
|
1948
|
+
export interface ExternalPushMessageData {
|
|
1949
|
+
url: string;
|
|
1950
|
+
}
|
|
1951
|
+
|
|
1952
|
+
export interface IGetHorseViewHistory extends FilterBaseQuery {
|
|
1953
|
+
lat?: string; // user lat
|
|
1954
|
+
lng?: string; // user lng
|
|
1955
|
+
}
|
|
1956
|
+
export interface IPriceHistorySearch {
|
|
1957
|
+
priceMin?: number;
|
|
1958
|
+
priceMax?: number;
|
|
1959
|
+
}
|
|
1960
|
+
|
|
1961
|
+
export enum ECollectionStatus {
|
|
1962
|
+
PUBLISHED = 'PUBLISHED',
|
|
1963
|
+
ARCHIVED = 'ARCHIVED',
|
|
1964
|
+
}
|
|
1965
|
+
export interface IPopulatedCollection
|
|
1966
|
+
extends Omit<ICollection, 'products'> {
|
|
1967
|
+
products: IProductResponse[];
|
|
1968
|
+
}
|
|
1969
|
+
|
|
1970
|
+
export interface ICollectionQueryRequest {
|
|
1971
|
+
title?: string;
|
|
1972
|
+
desc?: string;
|
|
1973
|
+
slug?: string;
|
|
1974
|
+
deeplink?: string;
|
|
1975
|
+
photo?: string;
|
|
1976
|
+
products?: string;
|
|
1977
|
+
status?: string;
|
|
1978
|
+
position?: number;
|
|
1979
|
+
all_fields?: string;
|
|
1980
|
+
is_thematic?: 'true' | 'false';
|
|
1981
|
+
skip: string;
|
|
1982
|
+
limit: string;
|
|
1983
|
+
}
|
|
1984
|
+
|
|
1985
|
+
export interface ICreateCollection {
|
|
1986
|
+
title: string;
|
|
1987
|
+
desc?: string;
|
|
1988
|
+
deeplink?: string;
|
|
1989
|
+
photo: File;
|
|
1990
|
+
products: string[];
|
|
1991
|
+
status: ECollectionStatus;
|
|
1992
|
+
position: number;
|
|
1993
|
+
is_thematic?: 'true' | 'false';
|
|
1994
|
+
icon?: File;
|
|
1995
|
+
}
|
|
1996
|
+
|
|
1997
|
+
export interface IUpdateCollection {
|
|
1998
|
+
title?: string;
|
|
1999
|
+
desc?: string;
|
|
2000
|
+
deeplink?: string;
|
|
2001
|
+
photo?: File;
|
|
2002
|
+
products?: string[];
|
|
2003
|
+
status?: ECollectionStatus;
|
|
2004
|
+
position?: number;
|
|
2005
|
+
is_thematic?: 'true' | 'false';
|
|
2006
|
+
icon?: File;
|
|
2007
|
+
}
|
|
2008
|
+
|
|
2009
|
+
export interface ICollection {
|
|
2010
|
+
_id: string;
|
|
2011
|
+
title: string;
|
|
2012
|
+
desc?: string;
|
|
2013
|
+
slug: string;
|
|
2014
|
+
deeplink?: string;
|
|
2015
|
+
photo: string;
|
|
2016
|
+
products: string[];
|
|
2017
|
+
status: ECollectionStatus;
|
|
2018
|
+
position: number;
|
|
2019
|
+
is_thematic: boolean;
|
|
2020
|
+
icon: string | null;
|
|
2021
|
+
}
|
|
2022
|
+
export interface IPickupPoints {
|
|
2023
|
+
lat: string;
|
|
2024
|
+
|
|
2025
|
+
lng: string;
|
|
2026
|
+
}
|
|
2027
|
+
|
|
2028
|
+
export interface ICalculateFastDeliveryPrice {
|
|
2029
|
+
lat: string;
|
|
2030
|
+
|
|
2031
|
+
lng: string;
|
|
2032
|
+
|
|
2033
|
+
items: IOrderItem[];
|
|
2034
|
+
}
|
|
2035
|
+
|
|
2036
|
+
export interface ItemSizeDto {
|
|
2037
|
+
// product.dimension: length, width, height
|
|
2038
|
+
length: number;
|
|
2039
|
+
width: number;
|
|
2040
|
+
height: number;
|
|
2041
|
+
}
|
|
2042
|
+
|
|
2043
|
+
export interface ItemDto {
|
|
2044
|
+
size?: ItemSizeDto;
|
|
2045
|
+
weight?: number;
|
|
2046
|
+
quantity: number;
|
|
2047
|
+
pickup_point: number;
|
|
2048
|
+
dropoff_point: number;
|
|
2049
|
+
}
|
|
2050
|
+
|
|
2051
|
+
export interface RoutePointDto {
|
|
2052
|
+
id: number; // 1, 2, 3...
|
|
2053
|
+
fullname?: string;
|
|
2054
|
+
coordinates: number[]; // 37.617298, 55.755825
|
|
2055
|
+
}
|
|
2056
|
+
|
|
2057
|
+
export interface DeliveryInterval {
|
|
2058
|
+
from: string;
|
|
2059
|
+
to: string;
|
|
2060
|
+
}
|
|
2061
|
+
export interface SameDayData {
|
|
2062
|
+
delivery_interval: DeliveryInterval;
|
|
2063
|
+
}
|
|
2064
|
+
export interface RequirementsDto {
|
|
2065
|
+
taxi_classes?: string[];
|
|
2066
|
+
cargo_type?: string;
|
|
2067
|
+
cargo_loaders?: number;
|
|
2068
|
+
pro_courier?: boolean;
|
|
2069
|
+
cargo_options?: string[];
|
|
2070
|
+
skip_door_to_door?: boolean;
|
|
2071
|
+
due?: string;
|
|
2072
|
+
same_day_data?: SameDayData;
|
|
2073
|
+
delivery_interval: DeliveryInterval;
|
|
2074
|
+
}
|
|
2075
|
+
|
|
2076
|
+
export interface YandexDeliveryRequestDto {
|
|
2077
|
+
items: ItemDto[];
|
|
2078
|
+
route_points: RoutePointDto[];
|
|
2079
|
+
requirements: RequirementsDto;
|
|
2080
|
+
}
|
|
2081
|
+
export interface PriceDto {
|
|
2082
|
+
total_price: string;
|
|
2083
|
+
total_price_with_vat: string;
|
|
2084
|
+
surge_ratio: number;
|
|
2085
|
+
currency: string;
|
|
2086
|
+
}
|
|
2087
|
+
|
|
2088
|
+
export interface IntervalDto {
|
|
2089
|
+
from: string;
|
|
2090
|
+
to: string;
|
|
2091
|
+
}
|
|
2092
|
+
|
|
2093
|
+
export interface OfferDto {
|
|
2094
|
+
price: PriceDto;
|
|
2095
|
+
taxi_class: string;
|
|
2096
|
+
pickup_interval: IntervalDto;
|
|
2097
|
+
delivery_interval: IntervalDto;
|
|
2098
|
+
description: string;
|
|
2099
|
+
payload: string;
|
|
2100
|
+
offer_ttl: string;
|
|
2101
|
+
}
|
|
2102
|
+
|
|
2103
|
+
export enum EProductsSortOptions {
|
|
2104
|
+
NEWEST = 'Новинки',
|
|
2105
|
+
POPULAR = 'Популярные',
|
|
2106
|
+
CHEAPEST = 'Дешевле',
|
|
2107
|
+
EXPENSIVE = 'Дороже',
|
|
2108
|
+
}
|
|
2109
|
+
|
|
2110
|
+
export interface PriceDto {
|
|
2111
|
+
total_price: string;
|
|
2112
|
+
total_price_with_vat: string;
|
|
2113
|
+
surge_ratio: number;
|
|
2114
|
+
currency: string;
|
|
2115
|
+
}
|
|
2116
|
+
|
|
2117
|
+
export interface IntervalDto {
|
|
2118
|
+
from: string;
|
|
2119
|
+
to: string;
|
|
2120
|
+
}
|
|
2121
|
+
|
|
2122
|
+
export interface OfferDto {
|
|
2123
|
+
price: PriceDto;
|
|
2124
|
+
taxi_class: string;
|
|
2125
|
+
pickup_interval: IntervalDto;
|
|
2126
|
+
delivery_interval: IntervalDto;
|
|
2127
|
+
description: string;
|
|
2128
|
+
payload: string;
|
|
2129
|
+
offer_ttl: string;
|
|
2130
|
+
}
|
|
2131
|
+
export enum DeliveryTypes {
|
|
2132
|
+
CDEK = 'CDEK',
|
|
2133
|
+
YANDEX_EXPRESS = 'YANDEX_EXPRESS',
|
|
2134
|
+
}
|
|
2135
|
+
|
|
2136
|
+
export interface GetFastDeliveryPriceDto {
|
|
2137
|
+
items: IPopulatedOrderItem[];
|
|
2138
|
+
|
|
2139
|
+
delivery_info: Partial<IDeliveryFullInfo>;
|
|
2140
|
+
}
|
|
2141
|
+
|
|
2142
|
+
// Favorites (Избранное) - Начало
|
|
2143
|
+
|
|
2144
|
+
export enum EFavoritesEntityType {
|
|
2145
|
+
PRODUCT = 'PRODUCT',
|
|
2146
|
+
HORSE = 'HORSE',
|
|
2147
|
+
SERVICE = 'SERVICE',
|
|
2148
|
+
}
|
|
2149
|
+
|
|
2150
|
+
export interface IFavorite {
|
|
2151
|
+
user_id?: string | null; // ID пользователя, который добавил в избранное
|
|
2152
|
+
session_id?: string | null;
|
|
2153
|
+
entity_id: string; // ID сущности, к которой привязано избранное (например, Product или Horse)
|
|
2154
|
+
entity_type: EFavoritesEntityType; // Тип сущности (PRODUCT, HORSE и т.д.)
|
|
2155
|
+
}
|
|
2156
|
+
|
|
2157
|
+
export interface IPopulatedFavorite extends Omit<IFavorite, 'entity_id'> {
|
|
2158
|
+
_id: string;
|
|
2159
|
+
entity_id: IProductResponse | IPopulatedHorse | IPopulatedService; // В зависимости от entity_type присваивать entity_id as IProductResponse или IPopulatedHorse
|
|
2160
|
+
}
|
|
2161
|
+
|
|
2162
|
+
export enum EFavoriteToggleActions {
|
|
2163
|
+
ADDED = 'ADDED', // Добавлен в базу
|
|
2164
|
+
REMOVED = 'REMOVED', // Убран из базы
|
|
2165
|
+
}
|
|
2166
|
+
|
|
2167
|
+
export interface IToggleFavoriteRequest
|
|
2168
|
+
extends Omit<IFavorite, 'user_id' | 'session_id'> {}
|
|
2169
|
+
|
|
2170
|
+
export interface IGetFavoritesRequest
|
|
2171
|
+
extends Omit<IFavorite, 'entity_id' | 'user_id' | 'session_id'> {}
|
|
2172
|
+
|
|
2173
|
+
export interface IToggleFavoriteResponse {
|
|
2174
|
+
action: EFavoriteToggleActions;
|
|
2175
|
+
}
|
|
2176
|
+
|
|
2177
|
+
// Favorites (Избранное) - Конец
|
|
2178
|
+
|
|
2179
|
+
// Services (Услуги) - Начало
|
|
2180
|
+
|
|
2181
|
+
export interface IGetServicesQuery extends FilterBaseQuery {
|
|
2182
|
+
creator_id?: string;
|
|
2183
|
+
user_id?: string;
|
|
2184
|
+
category?: string;
|
|
2185
|
+
priceMin?: string;
|
|
2186
|
+
priceMax?: string;
|
|
2187
|
+
lat?: string; // user lat
|
|
2188
|
+
lng?: string; // user lng
|
|
2189
|
+
radius?: string;
|
|
2190
|
+
}
|
|
2191
|
+
|
|
2192
|
+
export interface ICreateService {
|
|
2193
|
+
name: string;
|
|
2194
|
+
description?: string;
|
|
2195
|
+
category: string;
|
|
2196
|
+
price: number;
|
|
2197
|
+
location: ILocation;
|
|
2198
|
+
communication: ICommunication;
|
|
2199
|
+
photo: File;
|
|
2200
|
+
}
|
|
2201
|
+
|
|
2202
|
+
export interface IUpdateService extends Partial<ICreateService> {}
|
|
2203
|
+
|
|
2204
|
+
export enum EServiceStatus {
|
|
2205
|
+
MODERATION = 'MODERATION',
|
|
2206
|
+
PUBLISHED = 'PUBLISHED',
|
|
2207
|
+
REJECTED = 'REJECTED',
|
|
2208
|
+
ARCHIVED = 'ARCHIVED',
|
|
2209
|
+
}
|
|
2210
|
+
|
|
2211
|
+
export interface IServiceCategory {
|
|
2212
|
+
_id: string;
|
|
2213
|
+
name: string;
|
|
2214
|
+
photo: string;
|
|
2215
|
+
createdAt: Date;
|
|
2216
|
+
updatedAt: Date;
|
|
2217
|
+
}
|
|
2218
|
+
|
|
2219
|
+
export interface IService {
|
|
2220
|
+
user_id: string;
|
|
2221
|
+
name: string;
|
|
2222
|
+
description?: string;
|
|
2223
|
+
category: string;
|
|
2224
|
+
price: number;
|
|
2225
|
+
status: EServiceStatus;
|
|
2226
|
+
location: ILocation;
|
|
2227
|
+
communication: ICommunication;
|
|
2228
|
+
photo: string;
|
|
2229
|
+
telegram_message_id: number | null;
|
|
2230
|
+
slug: string;
|
|
2231
|
+
distance?: number; // Расстояние пользователя до лошади (если передано гео)
|
|
2232
|
+
number: number;
|
|
2233
|
+
published_at?: Date;
|
|
2234
|
+
entityAnalytics?: IEntityAnalytics;
|
|
2235
|
+
createdAt: Date;
|
|
2236
|
+
updatedAt: Date;
|
|
2237
|
+
}
|
|
2238
|
+
|
|
2239
|
+
export interface IPopulatedServicesWithReviewDataResponse {
|
|
2240
|
+
services: IPopulatedService[];
|
|
2241
|
+
reviewsData: IReviewsData;
|
|
2242
|
+
}
|
|
2243
|
+
|
|
2244
|
+
export interface IPopulatedService
|
|
2245
|
+
extends Omit<IService, 'category' | 'user_id'> {
|
|
2246
|
+
_id: string;
|
|
2247
|
+
category: IServiceCategory;
|
|
2248
|
+
user_id: IPopulatedOrderUserApp;
|
|
2249
|
+
is_favorite?: boolean;
|
|
2250
|
+
reviewsData?: IReviewsData;
|
|
2251
|
+
}
|
|
2252
|
+
|
|
2253
|
+
export interface IPopulatedServiceWViewCount extends IPopulatedService {
|
|
2254
|
+
viewCount: IViewCount;
|
|
2255
|
+
}
|
|
2256
|
+
|
|
2257
|
+
// Services (Услуги) - Конец
|
|
2258
|
+
|
|
2259
|
+
export interface OptionalUserQuery {
|
|
2260
|
+
user_id?: string;
|
|
2261
|
+
}
|
|
2262
|
+
|
|
2263
|
+
export interface OptionalLocationQuery {
|
|
2264
|
+
lat?: string;
|
|
2265
|
+
lng?: string;
|
|
2266
|
+
}
|
|
2267
|
+
|
|
2268
|
+
export interface OptionalUserLocationQuery
|
|
2269
|
+
extends OptionalUserQuery,
|
|
2270
|
+
OptionalLocationQuery {}
|
|
2271
|
+
|
|
2272
|
+
export interface CombinedUserLocationFilterQuery
|
|
2273
|
+
extends OptionalUserLocationQuery,
|
|
2274
|
+
FilterBaseQuery {}
|
|
2275
|
+
|
|
2276
|
+
export interface ISavePushToken {
|
|
2277
|
+
token: string;
|
|
2278
|
+
userId?: string;
|
|
2279
|
+
}
|
|
2280
|
+
|
|
2281
|
+
export enum EEntityType {
|
|
2282
|
+
PRODUCT = 'PRODUCT',
|
|
2283
|
+
HORSE = 'HORSE',
|
|
2284
|
+
SERVICE = 'SERVICE',
|
|
2285
|
+
}
|
|
2286
|
+
|
|
2287
|
+
export interface IGetUnreviewedProductsResponse {
|
|
2288
|
+
products: IProductResponse[];
|
|
2289
|
+
count: number;
|
|
2290
|
+
}
|
|
2291
|
+
|
|
2292
|
+
export enum EArchivedReason {
|
|
2293
|
+
HORSESMART = 'На HorseSmart',
|
|
2294
|
+
OTHER_PLATFORM = 'На другой площадке',
|
|
2295
|
+
PERSONAL = 'Лично',
|
|
2296
|
+
NOT_SOLD = 'Не продал',
|
|
2297
|
+
}
|
|
2298
|
+
|
|
2299
|
+
export interface IDeleteHorse {
|
|
2300
|
+
archived_reason: EArchivedReason;
|
|
2301
|
+
}
|
|
2302
|
+
|
|
2303
|
+
export interface SellerSlugResponse {
|
|
2304
|
+
_id: string;
|
|
2305
|
+
slug: string;
|
|
2306
|
+
shop_details: IShopDetails;
|
|
2307
|
+
updatedAt: Date;
|
|
2308
|
+
}
|
|
2309
|
+
|
|
2310
|
+
export interface IEntityAnalytics {
|
|
2311
|
+
entity_type: EEntityType;
|
|
2312
|
+
entity_id: string;
|
|
2313
|
+
views_count: number;
|
|
2314
|
+
favorites_count: number;
|
|
2315
|
+
purchases_count: number;
|
|
2316
|
+
cart_count: number;
|
|
2317
|
+
createdAt: Date;
|
|
2318
|
+
updatedAt: Date;
|
|
2319
|
+
}
|
|
2320
|
+
|
|
2321
|
+
export interface ISendOtpRequest {
|
|
2322
|
+
email: string;
|
|
2323
|
+
}
|
|
2324
|
+
|
|
2325
|
+
export interface IVerifyOtpRequest {
|
|
2326
|
+
email: string;
|
|
2327
|
+
code: number;
|
|
2328
|
+
}
|
|
2329
|
+
|
|
2330
|
+
export interface IVerifyOtpResponse extends ITokensResponse {
|
|
2331
|
+
user_id: string;
|
|
2332
|
+
}
|
|
2333
|
+
|
|
2334
|
+
export interface ICreateMultiOrderResponse {
|
|
2335
|
+
payment: IPaymentResponse;
|
|
2336
|
+
tokens?: ITokensResponse;
|
|
2337
|
+
}
|
|
2338
|
+
|
|
2339
|
+
export interface IPopulatedOrderAppWPaymentId {
|
|
2340
|
+
order: IPopulatedOrderApp;
|
|
2341
|
+
payment_id: string;
|
|
2342
|
+
}
|
|
2343
|
+
|
|
2344
|
+
// PromoCode
|
|
2345
|
+
|
|
2346
|
+
export interface ICreatePromo {
|
|
2347
|
+
discount_percent: number;
|
|
2348
|
+
start_date?: string; // default: new Date().toISOString()
|
|
2349
|
+
end_date: string;
|
|
2350
|
+
}
|
|
2351
|
+
|
|
2352
|
+
export interface IApplyPromo {
|
|
2353
|
+
code: string;
|
|
2354
|
+
}
|
|
2355
|
+
|
|
2356
|
+
export interface IPromoCode {
|
|
2357
|
+
_id: string;
|
|
2358
|
+
seller_id: string; // Привязка к продавцу
|
|
2359
|
+
code: string; // Сам промокод, например HSYORK20
|
|
2360
|
+
discount_percent: number; // Процент скидки (20 -> 20%)
|
|
2361
|
+
start_date: Date; // Дата начала действия промокода
|
|
2362
|
+
end_date: Date; // Дата окончания действия промокода
|
|
2363
|
+
showcase_url: string; // Ссылка на витрину продавца
|
|
2364
|
+
createdAt: Date;
|
|
2365
|
+
updatedAt: Date;
|
|
2366
|
+
}
|
|
2367
|
+
|
|
2368
|
+
/**
|
|
2369
|
+
* Порядок сортировки
|
|
2370
|
+
*/
|
|
2371
|
+
export enum SortOrder {
|
|
2372
|
+
ASC = 'asc',
|
|
2373
|
+
DESC = 'desc',
|
|
2374
|
+
}
|
|
2375
|
+
|
|
2376
|
+
/**
|
|
2377
|
+
* Payload для запроса на улучшение описания
|
|
2378
|
+
*/
|
|
2379
|
+
export interface EnhanceDescriptionPayload {
|
|
2380
|
+
productId: string;
|
|
2381
|
+
additionalPrompt?: string;
|
|
2382
|
+
}
|
|
2383
|
+
|
|
2384
|
+
/**
|
|
2385
|
+
* Payload для запроса на улучшение характеристик
|
|
2386
|
+
*/
|
|
2387
|
+
export interface EnhanceCharacteristicsPayload {
|
|
2388
|
+
productId: string;
|
|
2389
|
+
}
|
|
2390
|
+
|
|
2391
|
+
/**
|
|
2392
|
+
* Payload для запроса на улучшение изображения
|
|
2393
|
+
*/
|
|
2394
|
+
export interface EnhanceImagePayload {
|
|
2395
|
+
photo?: File;
|
|
2396
|
+
productId: string;
|
|
2397
|
+
type?: string;
|
|
2398
|
+
additionalPrompt?: string;
|
|
2399
|
+
removedBackgroundLink?: string;
|
|
2400
|
+
}
|
|
2401
|
+
|
|
2402
|
+
/**
|
|
2403
|
+
* Bulk payload для массового улучшения
|
|
2404
|
+
*/
|
|
2405
|
+
export interface EnhanceBulkPayload {
|
|
2406
|
+
productIds: string[];
|
|
2407
|
+
description: boolean;
|
|
2408
|
+
characteristics: boolean;
|
|
2409
|
+
image: boolean;
|
|
2410
|
+
}
|
|
2411
|
+
|
|
2412
|
+
/**
|
|
2413
|
+
* Интерфейс для ответа со списком улучшений
|
|
2414
|
+
*/
|
|
2415
|
+
export interface EnhancementListResponse {
|
|
2416
|
+
items: EnhancementResponse[];
|
|
2417
|
+
pagination: {
|
|
2418
|
+
totalItems: number;
|
|
2419
|
+
itemsPerPage: number;
|
|
2420
|
+
totalPages: number;
|
|
2421
|
+
currentPage: number;
|
|
2422
|
+
sortBy: string;
|
|
2423
|
+
sortOrder: SortOrder;
|
|
2424
|
+
};
|
|
2425
|
+
}
|
|
2426
|
+
|
|
2427
|
+
/**
|
|
2428
|
+
* Базовый интерфейс улучшения
|
|
2429
|
+
*/
|
|
2430
|
+
export interface EnhancementResponse {
|
|
2431
|
+
_id: string;
|
|
2432
|
+
product: PopulatedProduct;
|
|
2433
|
+
ai_characteristics_variants: EnhancementCharacteristicsResponse[];
|
|
2434
|
+
ai_descriptions_variants: EnhancementDescriptionResponse[];
|
|
2435
|
+
ai_image_variants: EnhancementImageResponse[];
|
|
2436
|
+
createdAt: Date;
|
|
2437
|
+
updatedAt: Date;
|
|
2438
|
+
}
|
|
2439
|
+
|
|
2440
|
+
export interface PopulatedProduct {
|
|
2441
|
+
_id: string;
|
|
2442
|
+
vendor_code?: string;
|
|
2443
|
+
article?: string;
|
|
2444
|
+
name: string;
|
|
2445
|
+
photo: string[];
|
|
2446
|
+
category: {
|
|
2447
|
+
_id: string;
|
|
2448
|
+
name: string;
|
|
2449
|
+
};
|
|
2450
|
+
subCategory: {
|
|
2451
|
+
_id: string;
|
|
2452
|
+
name: string;
|
|
2453
|
+
};
|
|
2454
|
+
}
|
|
2455
|
+
|
|
2456
|
+
export interface EnhancementDescriptionResponse {
|
|
2457
|
+
_id: string;
|
|
2458
|
+
productId: string;
|
|
2459
|
+
new_desc: string;
|
|
2460
|
+
status: string;
|
|
2461
|
+
additionalPrompt?: string;
|
|
2462
|
+
enhancementId: string;
|
|
2463
|
+
createdAt: Date;
|
|
2464
|
+
updatedAt: Date;
|
|
2465
|
+
}
|
|
2466
|
+
|
|
2467
|
+
export interface EnhancementCharacteristicsResponse {
|
|
2468
|
+
_id: string;
|
|
2469
|
+
productId: string;
|
|
2470
|
+
characteristics: ICharacteristic[];
|
|
2471
|
+
status: string;
|
|
2472
|
+
enhancementId: string;
|
|
2473
|
+
createdAt: Date;
|
|
2474
|
+
updatedAt: Date;
|
|
2475
|
+
}
|
|
2476
|
+
|
|
2477
|
+
export interface EnhancementImageResponse {
|
|
2478
|
+
_id: string;
|
|
2479
|
+
productId: string;
|
|
2480
|
+
image: string;
|
|
2481
|
+
type: EEnhancementImageType;
|
|
2482
|
+
status: string;
|
|
2483
|
+
enhancementId: string;
|
|
2484
|
+
createdAt: Date;
|
|
2485
|
+
updatedAt: Date;
|
|
2486
|
+
}
|
|
2487
|
+
|
|
2488
|
+
export enum EEnhancementImageType {
|
|
2489
|
+
BACKGROUND = 'background',
|
|
2490
|
+
FULL = 'full',
|
|
2491
|
+
INFOGRAPHIC = 'infographic',
|
|
2492
|
+
}
|
|
2493
|
+
|
|
2494
|
+
/**
|
|
2495
|
+
* Общий интерфейс для пагинации
|
|
2496
|
+
*/
|
|
2497
|
+
export interface PaginateDto {
|
|
2498
|
+
page?: number;
|
|
2499
|
+
limit?: number;
|
|
2500
|
+
sortBy?: string;
|
|
2501
|
+
sortOrder?: SortOrder;
|
|
2502
|
+
}
|
|
2503
|
+
|
|
2504
|
+
export interface GetEnhancementDto extends PaginateDto {
|
|
2505
|
+
sellerId?: string;
|
|
2506
|
+
enhancementIds?: string;
|
|
2507
|
+
}
|
|
2508
|
+
|
|
2509
|
+
export interface MergeAiVariantsResponse {
|
|
2510
|
+
success: boolean;
|
|
2511
|
+
mergedCount: number;
|
|
2512
|
+
errors: Array<{
|
|
2513
|
+
productId: string;
|
|
2514
|
+
error: string;
|
|
2515
|
+
}>;
|
|
2516
|
+
}
|
|
2517
|
+
|
|
2518
|
+
export interface IBitrixLeadRequest {
|
|
2519
|
+
name: string;
|
|
2520
|
+
tel: string;
|
|
2521
|
+
email?: string;
|
|
2522
|
+
comments?: string;
|
|
2523
|
+
source?: string;
|
|
2524
|
+
}
|
|
2525
|
+
|
|
2526
|
+
export interface IFilterWithSelect {
|
|
2527
|
+
name: string;
|
|
2528
|
+
values: {
|
|
2529
|
+
value: string;
|
|
2530
|
+
select: boolean;
|
|
2531
|
+
}[];
|
|
2532
|
+
}
|
|
2533
|
+
|
|
2534
|
+
export interface IProductQueryRequestWithFilter {
|
|
2535
|
+
category_id?: string;
|
|
2536
|
+
subCategory_id?: string;
|
|
2537
|
+
priceMin?: string;
|
|
2538
|
+
priceMax?: string;
|
|
2539
|
+
seller_id?: string;
|
|
2540
|
+
user_id?: string;
|
|
2541
|
+
sortBy: string;
|
|
2542
|
+
}
|
|
2543
|
+
|
|
2544
|
+
export interface IProductsWithFilterResponse {
|
|
2545
|
+
products: IProductResponse[];
|
|
2546
|
+
filters: IFilterWithSelect[];
|
|
2547
|
+
}
|
|
2548
|
+
}
|
|
2549
|
+
}
|