@aptly-as/types 2.5.3 → 2.5.4
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/core/api.d.ts +13 -13
- package/core/api.js +1 -1
- package/core/app.d.ts +37 -37
- package/core/app.js +9 -9
- package/core/cloudinary.d.ts +2 -2
- package/core/cloudinary.js +1 -1
- package/core/fields.d.ts +19 -19
- package/core/fields.js +1 -1
- package/core/index.d.ts +16 -16
- package/core/index.js +9 -9
- package/core/job.d.ts +21 -21
- package/core/job.js +11 -11
- package/core/redirect.d.ts +17 -17
- package/core/redirect.js +12 -12
- package/core/scope.d.ts +124 -124
- package/core/scope.js +117 -117
- package/core/signage.d.ts +19 -19
- package/core/signage.js +1 -1
- package/core/webhook-event-data.d.ts +16 -16
- package/core/webhook-event-data.js +1 -1
- package/enums/document.d.ts +38 -38
- package/enums/document.js +41 -41
- package/enums/fields.d.ts +30 -30
- package/enums/fields.js +31 -31
- package/enums/index.d.ts +151 -150
- package/enums/index.js +171 -170
- package/enums/unit-template.d.ts +10 -10
- package/enums/unit-template.js +12 -12
- package/enums/webhook.d.ts +23 -23
- package/enums/webhook.js +26 -26
- package/error/error.d.ts +28 -28
- package/error/error.js +50 -50
- package/error/index.d.ts +1 -1
- package/error/index.js +1 -1
- package/index.d.ts +4 -4
- package/index.js +4 -4
- package/models/algorithm.d.ts +32 -32
- package/models/algorithm.js +15 -15
- package/models/app.d.ts +101 -101
- package/models/app.js +52 -52
- package/models/availability.d.ts +35 -35
- package/models/availability.js +1 -1
- package/models/booking.d.ts +57 -57
- package/models/booking.js +1 -1
- package/models/client.d.ts +10 -10
- package/models/client.js +1 -1
- package/models/department.d.ts +28 -28
- package/models/department.js +1 -1
- package/models/document.d.ts +37 -37
- package/models/document.js +1 -1
- package/models/email.d.ts +16 -16
- package/models/email.js +1 -1
- package/models/extends.d.ts +37 -37
- package/models/extends.js +1 -1
- package/models/index.d.ts +34 -34
- package/models/index.js +34 -34
- package/models/inquiry.d.ts +57 -57
- package/models/inquiry.js +1 -1
- package/models/media.d.ts +50 -50
- package/models/media.js +1 -1
- package/models/module.d.ts +19 -19
- package/models/module.js +1 -1
- package/models/note.d.ts +19 -19
- package/models/note.js +1 -1
- package/models/notification-trigger.d.ts +9 -9
- package/models/notification-trigger.js +1 -1
- package/models/option-label.d.ts +7 -7
- package/models/option-label.js +1 -1
- package/models/order.d.ts +164 -163
- package/models/order.js +20 -20
- package/models/organization.d.ts +86 -86
- package/models/organization.js +7 -7
- package/models/page.d.ts +22 -22
- package/models/page.js +1 -1
- package/models/payment.d.ts +94 -94
- package/models/payment.js +1 -1
- package/models/period.d.ts +8 -8
- package/models/period.js +1 -1
- package/models/producer.d.ts +24 -24
- package/models/producer.js +1 -1
- package/models/product-stats.d.ts +18 -18
- package/models/product-stats.js +1 -1
- package/models/product.d.ts +78 -78
- package/models/product.js +1 -1
- package/models/project.d.ts +124 -124
- package/models/project.js +1 -1
- package/models/queue-download.d.ts +19 -19
- package/models/queue-download.js +1 -1
- package/models/recommendation.d.ts +12 -12
- package/models/recommendation.js +1 -1
- package/models/supplier.d.ts +12 -12
- package/models/supplier.js +1 -1
- package/models/tag.d.ts +5 -5
- package/models/tag.js +1 -1
- package/models/unit-email.d.ts +21 -21
- package/models/unit-email.js +1 -1
- package/models/unit-template.d.ts +124 -124
- package/models/unit-template.js +1 -1
- package/models/unit.d.ts +243 -243
- package/models/unit.js +1 -1
- package/models/upsell-template.d.ts +13 -13
- package/models/upsell-template.js +1 -1
- package/models/user.d.ts +33 -33
- package/models/user.js +16 -16
- package/models/webhook-event.d.ts +43 -43
- package/models/webhook-event.js +1 -1
- package/models/webhook.d.ts +15 -15
- package/models/webhook.js +1 -1
- package/package.json +5 -5
package/models/payment.d.ts
CHANGED
|
@@ -1,94 +1,94 @@
|
|
|
1
|
-
import { AptlyAppSchema } from './app.js';
|
|
2
|
-
import { AptlyDocumentSchema } from './document.js';
|
|
3
|
-
import { AptlyAddress, AptlyBaseSchema } from './extends.js';
|
|
4
|
-
import { AptlyOrderPaymentStatus, AptlyOrderSchema } from './order.js';
|
|
5
|
-
import { AptlyOrganizationSchema } from './organization.js';
|
|
6
|
-
import { AptlyProjectSchema } from './project.js';
|
|
7
|
-
import { AptlyUnitSchema } from './unit.js';
|
|
8
|
-
import { AptlyUserSchema } from './user.js';
|
|
9
|
-
export type AptlyPayment = AptlyPaymentSchema<string, string>;
|
|
10
|
-
export interface AptlyPaymentSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'name' | 'archived'> {
|
|
11
|
-
organization: ID | AptlyOrganizationSchema<ID, DATE>;
|
|
12
|
-
project: ID | AptlyProjectSchema<ID, DATE>;
|
|
13
|
-
unit: ID | AptlyUnitSchema<ID, DATE>;
|
|
14
|
-
order: ID | AptlyOrderSchema<ID, DATE>;
|
|
15
|
-
app: ID | AptlyAppSchema<ID, DATE>;
|
|
16
|
-
document?: ID | AptlyDocumentSchema<ID, DATE>;
|
|
17
|
-
number: number;
|
|
18
|
-
totalCost: number;
|
|
19
|
-
totalVat: number;
|
|
20
|
-
items: AptlyPaymentItemSchema<ID>[];
|
|
21
|
-
transaction: {
|
|
22
|
-
ref: string;
|
|
23
|
-
at: DATE;
|
|
24
|
-
};
|
|
25
|
-
company: AptlyPaymentCompany;
|
|
26
|
-
customer: AptlyPaymentCustomerSchema<ID, DATE>;
|
|
27
|
-
shipping: AptlyAddress;
|
|
28
|
-
shippingDate?: DATE;
|
|
29
|
-
billing?: AptlyAddress;
|
|
30
|
-
card?: {
|
|
31
|
-
brand: string;
|
|
32
|
-
last4: string;
|
|
33
|
-
};
|
|
34
|
-
captures: AptlyPaymentCaptureSchema<ID, DATE>[];
|
|
35
|
-
captured: {
|
|
36
|
-
amount: number;
|
|
37
|
-
at: DATE;
|
|
38
|
-
};
|
|
39
|
-
}
|
|
40
|
-
export type AptlyPaymentCapture = AptlyPaymentCaptureSchema<string, string>;
|
|
41
|
-
export interface AptlyPaymentCaptureSchema<ID, DATE> {
|
|
42
|
-
_id: ID;
|
|
43
|
-
amount: number;
|
|
44
|
-
description: string;
|
|
45
|
-
ref: string;
|
|
46
|
-
user: ID | AptlyUserSchema<ID, DATE>;
|
|
47
|
-
at: DATE;
|
|
48
|
-
}
|
|
49
|
-
export interface AptlyPaymentCompany {
|
|
50
|
-
vat: string;
|
|
51
|
-
name: string;
|
|
52
|
-
email: string;
|
|
53
|
-
address: AptlyAddress;
|
|
54
|
-
phone?: string;
|
|
55
|
-
}
|
|
56
|
-
export type AptlyPaymentCustomer = AptlyPaymentCustomerSchema<string, string>;
|
|
57
|
-
export interface AptlyPaymentCustomerSchema<ID, DATE> {
|
|
58
|
-
user: ID | AptlyUserSchema<ID, DATE>;
|
|
59
|
-
firstName: string;
|
|
60
|
-
lastName: string;
|
|
61
|
-
email: string;
|
|
62
|
-
phone?: string;
|
|
63
|
-
}
|
|
64
|
-
export interface AptlyPaymentItemSchema<ID> {
|
|
65
|
-
_id: ID;
|
|
66
|
-
name: string;
|
|
67
|
-
sku: string;
|
|
68
|
-
quantity: number;
|
|
69
|
-
unitCost: number;
|
|
70
|
-
totalCost: number;
|
|
71
|
-
totalVat: number;
|
|
72
|
-
}
|
|
73
|
-
export interface AptlyPaymentCaptureBody {
|
|
74
|
-
id: string;
|
|
75
|
-
status: AptlyOrderPaymentStatus;
|
|
76
|
-
capturedAmount: number;
|
|
77
|
-
totalCost: number;
|
|
78
|
-
at: string;
|
|
79
|
-
}
|
|
80
|
-
export interface AptlyPaymentTransactionBody {
|
|
81
|
-
app: string;
|
|
82
|
-
id: string;
|
|
83
|
-
at: string;
|
|
84
|
-
customer: {
|
|
85
|
-
user: string;
|
|
86
|
-
firstName: string;
|
|
87
|
-
lastName: string;
|
|
88
|
-
email: string;
|
|
89
|
-
phone?: string;
|
|
90
|
-
};
|
|
91
|
-
card: AptlyPayment['card'];
|
|
92
|
-
shipping: AptlyAddress;
|
|
93
|
-
billing?: AptlyAddress;
|
|
94
|
-
}
|
|
1
|
+
import { AptlyAppSchema } from './app.js';
|
|
2
|
+
import { AptlyDocumentSchema } from './document.js';
|
|
3
|
+
import { AptlyAddress, AptlyBaseSchema } from './extends.js';
|
|
4
|
+
import { AptlyOrderPaymentStatus, AptlyOrderSchema } from './order.js';
|
|
5
|
+
import { AptlyOrganizationSchema } from './organization.js';
|
|
6
|
+
import { AptlyProjectSchema } from './project.js';
|
|
7
|
+
import { AptlyUnitSchema } from './unit.js';
|
|
8
|
+
import { AptlyUserSchema } from './user.js';
|
|
9
|
+
export type AptlyPayment = AptlyPaymentSchema<string, string>;
|
|
10
|
+
export interface AptlyPaymentSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'name' | 'archived'> {
|
|
11
|
+
organization: ID | AptlyOrganizationSchema<ID, DATE>;
|
|
12
|
+
project: ID | AptlyProjectSchema<ID, DATE>;
|
|
13
|
+
unit: ID | AptlyUnitSchema<ID, DATE>;
|
|
14
|
+
order: ID | AptlyOrderSchema<ID, DATE>;
|
|
15
|
+
app: ID | AptlyAppSchema<ID, DATE>;
|
|
16
|
+
document?: ID | AptlyDocumentSchema<ID, DATE>;
|
|
17
|
+
number: number;
|
|
18
|
+
totalCost: number;
|
|
19
|
+
totalVat: number;
|
|
20
|
+
items: AptlyPaymentItemSchema<ID>[];
|
|
21
|
+
transaction: {
|
|
22
|
+
ref: string;
|
|
23
|
+
at: DATE;
|
|
24
|
+
};
|
|
25
|
+
company: AptlyPaymentCompany;
|
|
26
|
+
customer: AptlyPaymentCustomerSchema<ID, DATE>;
|
|
27
|
+
shipping: AptlyAddress;
|
|
28
|
+
shippingDate?: DATE;
|
|
29
|
+
billing?: AptlyAddress;
|
|
30
|
+
card?: {
|
|
31
|
+
brand: string;
|
|
32
|
+
last4: string;
|
|
33
|
+
};
|
|
34
|
+
captures: AptlyPaymentCaptureSchema<ID, DATE>[];
|
|
35
|
+
captured: {
|
|
36
|
+
amount: number;
|
|
37
|
+
at: DATE;
|
|
38
|
+
};
|
|
39
|
+
}
|
|
40
|
+
export type AptlyPaymentCapture = AptlyPaymentCaptureSchema<string, string>;
|
|
41
|
+
export interface AptlyPaymentCaptureSchema<ID, DATE> {
|
|
42
|
+
_id: ID;
|
|
43
|
+
amount: number;
|
|
44
|
+
description: string;
|
|
45
|
+
ref: string;
|
|
46
|
+
user: ID | AptlyUserSchema<ID, DATE>;
|
|
47
|
+
at: DATE;
|
|
48
|
+
}
|
|
49
|
+
export interface AptlyPaymentCompany {
|
|
50
|
+
vat: string;
|
|
51
|
+
name: string;
|
|
52
|
+
email: string;
|
|
53
|
+
address: AptlyAddress;
|
|
54
|
+
phone?: string;
|
|
55
|
+
}
|
|
56
|
+
export type AptlyPaymentCustomer = AptlyPaymentCustomerSchema<string, string>;
|
|
57
|
+
export interface AptlyPaymentCustomerSchema<ID, DATE> {
|
|
58
|
+
user: ID | AptlyUserSchema<ID, DATE>;
|
|
59
|
+
firstName: string;
|
|
60
|
+
lastName: string;
|
|
61
|
+
email: string;
|
|
62
|
+
phone?: string;
|
|
63
|
+
}
|
|
64
|
+
export interface AptlyPaymentItemSchema<ID> {
|
|
65
|
+
_id: ID;
|
|
66
|
+
name: string;
|
|
67
|
+
sku: string;
|
|
68
|
+
quantity: number;
|
|
69
|
+
unitCost: number;
|
|
70
|
+
totalCost: number;
|
|
71
|
+
totalVat: number;
|
|
72
|
+
}
|
|
73
|
+
export interface AptlyPaymentCaptureBody {
|
|
74
|
+
id: string;
|
|
75
|
+
status: AptlyOrderPaymentStatus;
|
|
76
|
+
capturedAmount: number;
|
|
77
|
+
totalCost: number;
|
|
78
|
+
at: string;
|
|
79
|
+
}
|
|
80
|
+
export interface AptlyPaymentTransactionBody {
|
|
81
|
+
app: string;
|
|
82
|
+
id: string;
|
|
83
|
+
at: string;
|
|
84
|
+
customer: {
|
|
85
|
+
user: string;
|
|
86
|
+
firstName: string;
|
|
87
|
+
lastName: string;
|
|
88
|
+
email: string;
|
|
89
|
+
phone?: string;
|
|
90
|
+
};
|
|
91
|
+
card: AptlyPayment['card'];
|
|
92
|
+
shipping: AptlyAddress;
|
|
93
|
+
billing?: AptlyAddress;
|
|
94
|
+
}
|
package/models/payment.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export {};
|
|
1
|
+
export {};
|
package/models/period.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export type AptlyPeriod = AptlyPeriodSchema<string, string>;
|
|
2
|
-
export interface AptlyPeriodSchema<ID, DATE> {
|
|
3
|
-
_id: ID;
|
|
4
|
-
name: string;
|
|
5
|
-
open: DATE;
|
|
6
|
-
close: DATE;
|
|
7
|
-
override?: boolean;
|
|
8
|
-
}
|
|
1
|
+
export type AptlyPeriod = AptlyPeriodSchema<string, string>;
|
|
2
|
+
export interface AptlyPeriodSchema<ID, DATE> {
|
|
3
|
+
_id: ID;
|
|
4
|
+
name: string;
|
|
5
|
+
open: DATE;
|
|
6
|
+
close: DATE;
|
|
7
|
+
override?: boolean;
|
|
8
|
+
}
|
package/models/period.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export {};
|
|
1
|
+
export {};
|
package/models/producer.d.ts
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import { AptlyBaseSchema, AptlyHistorySchema } from './extends.js';
|
|
2
|
-
import { AptlyMediaSrc } from './media.js';
|
|
3
|
-
export type AptlyProducer = AptlyProducerSchema<string, string>;
|
|
4
|
-
export interface AptlyProducerSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE>, AptlyHistorySchema<ID, DATE> {
|
|
5
|
-
email: string;
|
|
6
|
-
logo: string | null;
|
|
7
|
-
logoMedia?: AptlyMediaSrc | null;
|
|
8
|
-
url?: string;
|
|
9
|
-
organization?: ID;
|
|
10
|
-
createdBy: ID;
|
|
11
|
-
tags: ID[];
|
|
12
|
-
trademarks?: AptlyProducerTrademarkSchema<ID, DATE>[];
|
|
13
|
-
featured: boolean;
|
|
14
|
-
extends: ID;
|
|
15
|
-
created: DATE;
|
|
16
|
-
}
|
|
17
|
-
export type AptlyProducerTrademark = AptlyProducerTrademarkSchema<string, string>;
|
|
18
|
-
export interface AptlyProducerTrademarkSchema<ID, DATE> {
|
|
19
|
-
_id: ID;
|
|
20
|
-
name: string;
|
|
21
|
-
logo?: AptlyMediaSrc | null;
|
|
22
|
-
updatedAt: DATE;
|
|
23
|
-
createdAt: DATE;
|
|
24
|
-
}
|
|
1
|
+
import { AptlyBaseSchema, AptlyHistorySchema } from './extends.js';
|
|
2
|
+
import { AptlyMediaSrc } from './media.js';
|
|
3
|
+
export type AptlyProducer = AptlyProducerSchema<string, string>;
|
|
4
|
+
export interface AptlyProducerSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE>, AptlyHistorySchema<ID, DATE> {
|
|
5
|
+
email: string;
|
|
6
|
+
logo: string | null;
|
|
7
|
+
logoMedia?: AptlyMediaSrc | null;
|
|
8
|
+
url?: string;
|
|
9
|
+
organization?: ID;
|
|
10
|
+
createdBy: ID;
|
|
11
|
+
tags: ID[];
|
|
12
|
+
trademarks?: AptlyProducerTrademarkSchema<ID, DATE>[];
|
|
13
|
+
featured: boolean;
|
|
14
|
+
extends: ID;
|
|
15
|
+
created: DATE;
|
|
16
|
+
}
|
|
17
|
+
export type AptlyProducerTrademark = AptlyProducerTrademarkSchema<string, string>;
|
|
18
|
+
export interface AptlyProducerTrademarkSchema<ID, DATE> {
|
|
19
|
+
_id: ID;
|
|
20
|
+
name: string;
|
|
21
|
+
logo?: AptlyMediaSrc | null;
|
|
22
|
+
updatedAt: DATE;
|
|
23
|
+
createdAt: DATE;
|
|
24
|
+
}
|
package/models/producer.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export {};
|
|
1
|
+
export {};
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { AptlyBaseSchema } from './extends.js';
|
|
2
|
-
export type AptlyProductStats = AptlyProductStatsSchema<string, string>;
|
|
3
|
-
export interface AptlyProductStatsSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'name'> {
|
|
4
|
-
product: ID;
|
|
5
|
-
project: ID;
|
|
6
|
-
organization: ID;
|
|
7
|
-
producer: ID;
|
|
8
|
-
extends?: ID;
|
|
9
|
-
tags: ID[];
|
|
10
|
-
stats: {
|
|
11
|
-
likes: number;
|
|
12
|
-
inUnits: number;
|
|
13
|
-
amountInUnits: number;
|
|
14
|
-
availability: number;
|
|
15
|
-
picks: number;
|
|
16
|
-
complaints: number;
|
|
17
|
-
};
|
|
18
|
-
}
|
|
1
|
+
import { AptlyBaseSchema } from './extends.js';
|
|
2
|
+
export type AptlyProductStats = AptlyProductStatsSchema<string, string>;
|
|
3
|
+
export interface AptlyProductStatsSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'name'> {
|
|
4
|
+
product: ID;
|
|
5
|
+
project: ID;
|
|
6
|
+
organization: ID;
|
|
7
|
+
producer: ID;
|
|
8
|
+
extends?: ID;
|
|
9
|
+
tags: ID[];
|
|
10
|
+
stats: {
|
|
11
|
+
likes: number;
|
|
12
|
+
inUnits: number;
|
|
13
|
+
amountInUnits: number;
|
|
14
|
+
availability: number;
|
|
15
|
+
picks: number;
|
|
16
|
+
complaints: number;
|
|
17
|
+
};
|
|
18
|
+
}
|
package/models/product-stats.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export {};
|
|
1
|
+
export {};
|
package/models/product.d.ts
CHANGED
|
@@ -1,78 +1,78 @@
|
|
|
1
|
-
import { AptlyDocumentSchema } from './document.js';
|
|
2
|
-
import { AptlyBaseSchema, AptlyDBCrawlerCleaner, AptlyHistorySchema } from './extends.js';
|
|
3
|
-
import { AptlyMediaSrcSchema } from './media.js';
|
|
4
|
-
import { AptlyProducerSchema } from './producer.js';
|
|
5
|
-
import { AptlyTagSchema } from './tag.js';
|
|
6
|
-
export type AptlyProduct = AptlyProductSchema<string, string>;
|
|
7
|
-
export interface AptlyProductSchema<ID, DATE> extends AptlyDBCrawlerCleaner, AptlyBaseSchema<ID, DATE>, AptlyHistorySchema<ID, DATE> {
|
|
8
|
-
searchableName: string;
|
|
9
|
-
organization?: ID;
|
|
10
|
-
project?: ID;
|
|
11
|
-
base?: boolean;
|
|
12
|
-
extends?: ID | AptlyProductSchema<ID, DATE>;
|
|
13
|
-
productNumber: string;
|
|
14
|
-
itemNumber?: string;
|
|
15
|
-
eanNumber?: string;
|
|
16
|
-
description: string;
|
|
17
|
-
images: AptlyProductImageSchema<ID, DATE>[];
|
|
18
|
-
variants: AptlyProductVariantSchema<ID, DATE>[];
|
|
19
|
-
products?: (ID | AptlyProductSchema<ID, DATE>)[];
|
|
20
|
-
url?: string;
|
|
21
|
-
color?: string;
|
|
22
|
-
colorLabel?: string;
|
|
23
|
-
series?: string;
|
|
24
|
-
style?: string;
|
|
25
|
-
width?: string;
|
|
26
|
-
height?: string;
|
|
27
|
-
length?: string;
|
|
28
|
-
depth?: string;
|
|
29
|
-
volume?: string;
|
|
30
|
-
circumference?: string;
|
|
31
|
-
material?: string;
|
|
32
|
-
unitCost?: number;
|
|
33
|
-
netCost?: number;
|
|
34
|
-
producer?: ID | AptlyProducerSchema<ID, DATE> | null;
|
|
35
|
-
supplier?: ID;
|
|
36
|
-
tags: (ID | AptlyTagSchema<ID, DATE>)[];
|
|
37
|
-
documents: (ID | AptlyDocumentSchema<ID, DATE>)[];
|
|
38
|
-
createdBy: ID;
|
|
39
|
-
stats?: any;
|
|
40
|
-
importID?: ID;
|
|
41
|
-
source?: string;
|
|
42
|
-
title?: string;
|
|
43
|
-
likes: {
|
|
44
|
-
user: ID;
|
|
45
|
-
date: DATE;
|
|
46
|
-
}[];
|
|
47
|
-
created: DATE;
|
|
48
|
-
}
|
|
49
|
-
export type AptlyProductImage = AptlyProductImageSchema<string, string>;
|
|
50
|
-
export interface AptlyProductImageSchema<ID, DATE> extends AptlyMediaSrcSchema<ID, DATE> {
|
|
51
|
-
image: string;
|
|
52
|
-
description?: string;
|
|
53
|
-
featured?: boolean;
|
|
54
|
-
}
|
|
55
|
-
export type AptlyProductVariant = AptlyProductVariantSchema<string, string>;
|
|
56
|
-
export interface AptlyProductVariantSchema<ID, DATE> {
|
|
57
|
-
_id: ID;
|
|
58
|
-
title?: string;
|
|
59
|
-
images: AptlyProductImageSchema<ID, DATE>[];
|
|
60
|
-
documents: (ID | AptlyDocumentSchema<ID, DATE>)[];
|
|
61
|
-
name?: string;
|
|
62
|
-
description?: string;
|
|
63
|
-
productNumber?: string;
|
|
64
|
-
color?: string;
|
|
65
|
-
colorLabel?: string;
|
|
66
|
-
series?: string;
|
|
67
|
-
material?: string;
|
|
68
|
-
style?: string;
|
|
69
|
-
width?: string;
|
|
70
|
-
height?: string;
|
|
71
|
-
length?: string;
|
|
72
|
-
unitCost?: number;
|
|
73
|
-
}
|
|
74
|
-
export type AptlyProductImport = AptlyProductImportSchema<string, string>;
|
|
75
|
-
export interface AptlyProductImportSchema<ID, DATE> extends Partial<Omit<AptlyProductSchema<ID, DATE>, 'images' | 'documents'>> {
|
|
76
|
-
images: string[];
|
|
77
|
-
documents: string[];
|
|
78
|
-
}
|
|
1
|
+
import { AptlyDocumentSchema } from './document.js';
|
|
2
|
+
import { AptlyBaseSchema, AptlyDBCrawlerCleaner, AptlyHistorySchema } from './extends.js';
|
|
3
|
+
import { AptlyMediaSrcSchema } from './media.js';
|
|
4
|
+
import { AptlyProducerSchema } from './producer.js';
|
|
5
|
+
import { AptlyTagSchema } from './tag.js';
|
|
6
|
+
export type AptlyProduct = AptlyProductSchema<string, string>;
|
|
7
|
+
export interface AptlyProductSchema<ID, DATE> extends AptlyDBCrawlerCleaner, AptlyBaseSchema<ID, DATE>, AptlyHistorySchema<ID, DATE> {
|
|
8
|
+
searchableName: string;
|
|
9
|
+
organization?: ID;
|
|
10
|
+
project?: ID;
|
|
11
|
+
base?: boolean;
|
|
12
|
+
extends?: ID | AptlyProductSchema<ID, DATE>;
|
|
13
|
+
productNumber: string;
|
|
14
|
+
itemNumber?: string;
|
|
15
|
+
eanNumber?: string;
|
|
16
|
+
description: string;
|
|
17
|
+
images: AptlyProductImageSchema<ID, DATE>[];
|
|
18
|
+
variants: AptlyProductVariantSchema<ID, DATE>[];
|
|
19
|
+
products?: (ID | AptlyProductSchema<ID, DATE>)[];
|
|
20
|
+
url?: string;
|
|
21
|
+
color?: string;
|
|
22
|
+
colorLabel?: string;
|
|
23
|
+
series?: string;
|
|
24
|
+
style?: string;
|
|
25
|
+
width?: string;
|
|
26
|
+
height?: string;
|
|
27
|
+
length?: string;
|
|
28
|
+
depth?: string;
|
|
29
|
+
volume?: string;
|
|
30
|
+
circumference?: string;
|
|
31
|
+
material?: string;
|
|
32
|
+
unitCost?: number;
|
|
33
|
+
netCost?: number;
|
|
34
|
+
producer?: ID | AptlyProducerSchema<ID, DATE> | null;
|
|
35
|
+
supplier?: ID;
|
|
36
|
+
tags: (ID | AptlyTagSchema<ID, DATE>)[];
|
|
37
|
+
documents: (ID | AptlyDocumentSchema<ID, DATE>)[];
|
|
38
|
+
createdBy: ID;
|
|
39
|
+
stats?: any;
|
|
40
|
+
importID?: ID;
|
|
41
|
+
source?: string;
|
|
42
|
+
title?: string;
|
|
43
|
+
likes: {
|
|
44
|
+
user: ID;
|
|
45
|
+
date: DATE;
|
|
46
|
+
}[];
|
|
47
|
+
created: DATE;
|
|
48
|
+
}
|
|
49
|
+
export type AptlyProductImage = AptlyProductImageSchema<string, string>;
|
|
50
|
+
export interface AptlyProductImageSchema<ID, DATE> extends AptlyMediaSrcSchema<ID, DATE> {
|
|
51
|
+
image: string;
|
|
52
|
+
description?: string;
|
|
53
|
+
featured?: boolean;
|
|
54
|
+
}
|
|
55
|
+
export type AptlyProductVariant = AptlyProductVariantSchema<string, string>;
|
|
56
|
+
export interface AptlyProductVariantSchema<ID, DATE> {
|
|
57
|
+
_id: ID;
|
|
58
|
+
title?: string;
|
|
59
|
+
images: AptlyProductImageSchema<ID, DATE>[];
|
|
60
|
+
documents: (ID | AptlyDocumentSchema<ID, DATE>)[];
|
|
61
|
+
name?: string;
|
|
62
|
+
description?: string;
|
|
63
|
+
productNumber?: string;
|
|
64
|
+
color?: string;
|
|
65
|
+
colorLabel?: string;
|
|
66
|
+
series?: string;
|
|
67
|
+
material?: string;
|
|
68
|
+
style?: string;
|
|
69
|
+
width?: string;
|
|
70
|
+
height?: string;
|
|
71
|
+
length?: string;
|
|
72
|
+
unitCost?: number;
|
|
73
|
+
}
|
|
74
|
+
export type AptlyProductImport = AptlyProductImportSchema<string, string>;
|
|
75
|
+
export interface AptlyProductImportSchema<ID, DATE> extends Partial<Omit<AptlyProductSchema<ID, DATE>, 'images' | 'documents'>> {
|
|
76
|
+
images: string[];
|
|
77
|
+
documents: string[];
|
|
78
|
+
}
|
package/models/product.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export {};
|
|
1
|
+
export {};
|