@aptly-as/types 1.3.3 → 1.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/core/permission.d.ts +2 -2
- package/core/permission.ts +3 -0
- package/models/client.d.ts +5 -3
- package/models/client.ts +6 -3
- package/models/department.d.ts +28 -0
- package/models/department.js +3 -0
- package/models/department.js.map +1 -0
- package/models/department.ts +31 -0
- package/models/document.d.ts +6 -4
- package/models/document.ts +6 -4
- package/models/extends.d.ts +14 -0
- package/models/extends.ts +16 -1
- package/models/index.d.ts +1 -0
- package/models/index.js +1 -0
- package/models/index.js.map +1 -1
- package/models/index.ts +1 -0
- package/models/media.d.ts +10 -6
- package/models/media.ts +11 -6
- package/models/option-label.d.ts +6 -5
- package/models/option-label.ts +7 -5
- package/models/order.d.ts +7 -3
- package/models/order.ts +8 -3
- package/models/organization.d.ts +26 -5
- package/models/organization.ts +28 -5
- package/models/page.d.ts +14 -7
- package/models/page.ts +15 -7
- package/models/producer.d.ts +6 -6
- package/models/producer.ts +7 -6
- package/models/product-stats.d.ts +2 -3
- package/models/product-stats.ts +2 -3
- package/models/product.d.ts +15 -11
- package/models/product.ts +16 -11
- package/models/project.d.ts +6 -6
- package/models/project.ts +7 -6
- package/models/queue-download.d.ts +2 -4
- package/models/queue-download.ts +2 -5
- package/models/recommendation.d.ts +2 -4
- package/models/recommendation.ts +2 -4
- package/models/supplier.d.ts +6 -5
- package/models/supplier.ts +7 -5
- package/models/tag.d.ts +5 -3
- package/models/tag.ts +5 -3
- package/models/unit-email.d.ts +5 -2
- package/models/unit-email.js.map +1 -1
- package/models/unit-email.ts +5 -2
- package/models/unit-template.d.ts +2 -3
- package/models/unit-template.ts +2 -3
- package/models/unit.d.ts +5 -5
- package/models/unit.ts +6 -6
- package/models/upsell-template.d.ts +9 -9
- package/models/upsell-template.ts +10 -9
- package/models/user.d.ts +5 -2
- package/models/user.ts +6 -2
- package/models/webhook-event.d.ts +5 -2
- package/models/webhook-event.ts +6 -2
- package/models/webhook.d.ts +6 -4
- package/models/webhook.ts +7 -4
- package/package.json +1 -1
package/core/permission.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export declare type AptlyPermissionGlobalModels = 'superAdmin' | 'admin' | 'beta' | 'default';
|
|
2
2
|
export declare type AptlyPermissionModules = 'projectBooking' | 'projectSupport' | 'projectRecommendations';
|
|
3
|
-
export declare type AptlyPermissionModulesModels = 'default' | 'core' | 'algorithms' | 'booking' | 'unitExtraOptions' | 'unitExtraFields' | 'pages' | 'recommendations' | 'subcontractor' | 'optionLabels' | 'support' | 'testing';
|
|
3
|
+
export declare type AptlyPermissionModulesModels = 'default' | 'core' | 'algorithms' | 'departments' | 'booking' | 'unitExtraOptions' | 'unitExtraFields' | 'pages' | 'recommendations' | 'subcontractor' | 'optionLabels' | 'support' | 'testing';
|
|
4
4
|
export declare type AptlyPermissionOrganizationModels = 'testingAdmin' | 'admin' | 'content' | 'reports' | 'support' | 'thirdParty' | 'default';
|
|
5
|
-
export declare type AptlyPermissionModels = 'admin' | 'adminBilling' | 'adminProducers' | 'adminProducts' | 'adminReport' | 'adminStats' | 'adminSuppliers' | 'adminTags' | 'adminTesting' | 'adminUsers' | 'adminOrganizations' | 'beta' | 'organization' | 'organizationBooking' | 'organizationClients' | 'organizationMembers' | 'organizationOptionLabels' | 'organizationProducts' | 'organizationReport' | 'organizationStats' | 'organizationLogo' | 'organizationWebhooks' | 'project' | 'projectAlgorithms' | 'projectBooking' | 'projectDocuments' | 'projectInquiry' | 'projectOrders' | 'projectPages' | 'projectPeriods' | 'projectProducts' | 'projectRecommendations' | 'projectReport' | 'projectReportPrice' | 'projectTheme' | 'projectSigning' | 'projectSubcontractor' | 'projectUnits' | 'projectUnitInvites' | 'projectUnitExtraFields' | 'projectUnitExtraOptions' | 'projectUnitTemplates' | 'projectUnitTemplatesAlgorithms' | 'projectUnitTemplatesPrices' | 'projectUpsellTemplates' | 'unit' | 'unitBooking' | 'unitInquiry' | 'unitOrders' | 'unitPages' | 'unitProducts' | 'unitReport';
|
|
5
|
+
export declare type AptlyPermissionModels = 'admin' | 'adminBilling' | 'adminProducers' | 'adminProducts' | 'adminReport' | 'adminStats' | 'adminSuppliers' | 'adminTags' | 'adminTesting' | 'adminUsers' | 'adminOrganizations' | 'beta' | 'organization' | 'organizationBooking' | 'organizationClients' | 'organizationDepartments' | 'organizationMembers' | 'organizationOptionLabels' | 'organizationOrders' | 'organizationProducts' | 'organizationReport' | 'organizationStats' | 'organizationLogo' | 'organizationWebhooks' | 'project' | 'projectAlgorithms' | 'projectBooking' | 'projectDocuments' | 'projectInquiry' | 'projectOrders' | 'projectPages' | 'projectPeriods' | 'projectProducts' | 'projectRecommendations' | 'projectReport' | 'projectReportPrice' | 'projectTheme' | 'projectSigning' | 'projectSubcontractor' | 'projectUnits' | 'projectUnitInvites' | 'projectUnitExtraFields' | 'projectUnitExtraOptions' | 'projectUnitTemplates' | 'projectUnitTemplatesAlgorithms' | 'projectUnitTemplatesPrices' | 'projectUpsellTemplates' | 'unit' | 'unitBooking' | 'unitInquiry' | 'unitOrders' | 'unitPages' | 'unitProducts' | 'unitReport';
|
package/core/permission.ts
CHANGED
|
@@ -7,6 +7,7 @@ export type AptlyPermissionModulesModels =
|
|
|
7
7
|
| 'default'
|
|
8
8
|
| 'core'
|
|
9
9
|
| 'algorithms'
|
|
10
|
+
| 'departments'
|
|
10
11
|
| 'booking'
|
|
11
12
|
| 'unitExtraOptions'
|
|
12
13
|
| 'unitExtraFields'
|
|
@@ -42,8 +43,10 @@ export type AptlyPermissionModels =
|
|
|
42
43
|
| 'organization'
|
|
43
44
|
| 'organizationBooking'
|
|
44
45
|
| 'organizationClients'
|
|
46
|
+
| 'organizationDepartments'
|
|
45
47
|
| 'organizationMembers'
|
|
46
48
|
| 'organizationOptionLabels'
|
|
49
|
+
| 'organizationOrders'
|
|
47
50
|
| 'organizationProducts'
|
|
48
51
|
| 'organizationReport'
|
|
49
52
|
| 'organizationStats'
|
package/models/client.d.ts
CHANGED
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import { AptlyBaseSchema } from './extends';
|
|
2
|
+
export interface AptlyUserClientSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'archived'> {
|
|
3
3
|
user: ID;
|
|
4
4
|
subject: string;
|
|
5
5
|
clientId: string;
|
|
6
6
|
clientSecret?: string;
|
|
7
7
|
permissions: any;
|
|
8
|
+
/**
|
|
9
|
+
* @deprecated use createdAt
|
|
10
|
+
*/
|
|
8
11
|
created: DATE;
|
|
9
|
-
name: string;
|
|
10
12
|
}
|
|
11
13
|
export declare type AptlyUserClient = AptlyUserClientSchema<string, string>;
|
package/models/client.ts
CHANGED
|
@@ -1,11 +1,14 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import { AptlyBaseSchema } from './extends';
|
|
2
|
+
|
|
3
|
+
export interface AptlyUserClientSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'archived'> {
|
|
3
4
|
user: ID;
|
|
4
5
|
subject: string;
|
|
5
6
|
clientId: string;
|
|
6
7
|
clientSecret?: string;
|
|
7
8
|
permissions: any;
|
|
9
|
+
/**
|
|
10
|
+
* @deprecated use createdAt
|
|
11
|
+
*/
|
|
8
12
|
created: DATE;
|
|
9
|
-
name: string;
|
|
10
13
|
}
|
|
11
14
|
export type AptlyUserClient = AptlyUserClientSchema<string, string>;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { AptlyPermissionOrganizationModels } from '../core';
|
|
2
|
+
import { AptlyOrganizationSchema } from './organization';
|
|
3
|
+
import { AptlyProjectSchema } from './project';
|
|
4
|
+
import { AptlyUserSchema } from './user';
|
|
5
|
+
import { AptlyBaseSchema } from './extends';
|
|
6
|
+
import { AptlyUnitSchema } from './unit';
|
|
7
|
+
export declare type AptlyDepartment = AptlyDepartmentGeneric<string, string>;
|
|
8
|
+
export interface AptlyDepartmentGeneric<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'archived'> {
|
|
9
|
+
organization: ID | AptlyOrganizationSchema<ID, DATE>;
|
|
10
|
+
projects: AptlyDepartmentProjectGeneric<ID, DATE>[];
|
|
11
|
+
users: AptlyDepartmentUserGeneric<ID, DATE>[];
|
|
12
|
+
}
|
|
13
|
+
export declare type AptlyDepartmentProject = AptlyDepartmentProjectGeneric<string, string>;
|
|
14
|
+
export interface AptlyDepartmentProjectGeneric<ID, DATE> {
|
|
15
|
+
_id: ID;
|
|
16
|
+
project: (ID | AptlyProjectSchema<ID, DATE>);
|
|
17
|
+
units: (ID | AptlyUnitSchema<ID, DATE>)[] | null;
|
|
18
|
+
createdAt: DATE;
|
|
19
|
+
updatedAt: DATE;
|
|
20
|
+
}
|
|
21
|
+
export declare type AptlyDepartmentUser = AptlyDepartmentUserGeneric<string, string>;
|
|
22
|
+
export interface AptlyDepartmentUserGeneric<ID, DATE> {
|
|
23
|
+
_id: ID;
|
|
24
|
+
user: (ID | AptlyUserSchema<ID, DATE>);
|
|
25
|
+
permissions: AptlyPermissionOrganizationModels[];
|
|
26
|
+
createdAt: DATE;
|
|
27
|
+
updatedAt: DATE;
|
|
28
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"department.js","sourceRoot":"","sources":["department.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { AptlyPermissionOrganizationModels } from '../core';
|
|
2
|
+
import { AptlyOrganizationSchema } from './organization';
|
|
3
|
+
import { AptlyProjectSchema } from './project';
|
|
4
|
+
import { AptlyUserSchema } from './user';
|
|
5
|
+
import { AptlyBaseSchema } from './extends';
|
|
6
|
+
import { AptlyUnitSchema } from './unit';
|
|
7
|
+
|
|
8
|
+
export type AptlyDepartment = AptlyDepartmentGeneric<string, string>;
|
|
9
|
+
export interface AptlyDepartmentGeneric<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'archived'> {
|
|
10
|
+
organization: ID | AptlyOrganizationSchema<ID, DATE>;
|
|
11
|
+
projects: AptlyDepartmentProjectGeneric<ID, DATE>[];
|
|
12
|
+
users: AptlyDepartmentUserGeneric<ID, DATE>[];
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export type AptlyDepartmentProject = AptlyDepartmentProjectGeneric<string, string>;
|
|
16
|
+
export interface AptlyDepartmentProjectGeneric<ID, DATE> {
|
|
17
|
+
_id: ID;
|
|
18
|
+
project: (ID | AptlyProjectSchema<ID, DATE>);
|
|
19
|
+
units: (ID | AptlyUnitSchema<ID, DATE>)[] | null;
|
|
20
|
+
createdAt: DATE;
|
|
21
|
+
updatedAt: DATE;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export type AptlyDepartmentUser = AptlyDepartmentUserGeneric<string, string>;
|
|
25
|
+
export interface AptlyDepartmentUserGeneric<ID, DATE> {
|
|
26
|
+
_id: ID;
|
|
27
|
+
user: (ID | AptlyUserSchema<ID, DATE>);
|
|
28
|
+
permissions: AptlyPermissionOrganizationModels[];
|
|
29
|
+
createdAt: DATE;
|
|
30
|
+
updatedAt: DATE;
|
|
31
|
+
}
|
package/models/document.d.ts
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import { AptlyDocumentType } from '../enums';
|
|
2
|
+
import { AptlyBaseSchema } from './extends';
|
|
2
3
|
export declare type AptlyDocument = AptlyDocumentSchema<string, string>;
|
|
3
|
-
export interface AptlyDocumentSchema<ID, DATE> {
|
|
4
|
-
_id: ID;
|
|
4
|
+
export interface AptlyDocumentSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'archived'> {
|
|
5
5
|
mime: string;
|
|
6
6
|
_type: AptlyDocumentType;
|
|
7
|
-
name: string;
|
|
8
7
|
data: string;
|
|
9
8
|
organization?: string;
|
|
10
9
|
project?: string;
|
|
@@ -12,7 +11,6 @@ export interface AptlyDocumentSchema<ID, DATE> {
|
|
|
12
11
|
product?: string;
|
|
13
12
|
text?: string;
|
|
14
13
|
size: number;
|
|
15
|
-
created: DATE;
|
|
16
14
|
thirdPartyUploader: string | null;
|
|
17
15
|
thirdPartyId: string | null;
|
|
18
16
|
external_url?: string;
|
|
@@ -20,6 +18,10 @@ export interface AptlyDocumentSchema<ID, DATE> {
|
|
|
20
18
|
boligmappaStatus?: AptlyDocumentSchemaBoligmappaStatusSchema<ID, DATE>[];
|
|
21
19
|
chunks?: ID[];
|
|
22
20
|
isPasswordProtected?: boolean;
|
|
21
|
+
/**
|
|
22
|
+
* @deprecated use createdAt
|
|
23
|
+
*/
|
|
24
|
+
created: DATE;
|
|
23
25
|
}
|
|
24
26
|
export declare type AptlyDocumentSchemaBoligmappaStatus = AptlyDocumentSchemaBoligmappaStatusSchema<string, string>;
|
|
25
27
|
export interface AptlyDocumentSchemaBoligmappaStatusSchema<ID, DATE> {
|
package/models/document.ts
CHANGED
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import { AptlyDocumentType } from '../enums';
|
|
2
|
+
import { AptlyBaseSchema } from './extends';
|
|
2
3
|
|
|
3
4
|
|
|
4
5
|
export type AptlyDocument = AptlyDocumentSchema<string, string>;
|
|
5
|
-
export interface AptlyDocumentSchema<ID, DATE> {
|
|
6
|
-
_id: ID;
|
|
6
|
+
export interface AptlyDocumentSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'archived'> {
|
|
7
7
|
mime: string;
|
|
8
8
|
_type: AptlyDocumentType;
|
|
9
|
-
name: string;
|
|
10
9
|
data: string;
|
|
11
10
|
organization?: string;
|
|
12
11
|
project?: string;
|
|
@@ -14,7 +13,6 @@ export interface AptlyDocumentSchema<ID, DATE> {
|
|
|
14
13
|
product?: string;
|
|
15
14
|
text?: string;
|
|
16
15
|
size: number;
|
|
17
|
-
created: DATE;
|
|
18
16
|
thirdPartyUploader: string | null;
|
|
19
17
|
thirdPartyId: string | null;
|
|
20
18
|
external_url?: string;
|
|
@@ -22,6 +20,10 @@ export interface AptlyDocumentSchema<ID, DATE> {
|
|
|
22
20
|
boligmappaStatus?: AptlyDocumentSchemaBoligmappaStatusSchema<ID, DATE>[];
|
|
23
21
|
chunks?: ID[];
|
|
24
22
|
isPasswordProtected?: boolean;
|
|
23
|
+
/**
|
|
24
|
+
* @deprecated use createdAt
|
|
25
|
+
*/
|
|
26
|
+
created: DATE;
|
|
25
27
|
}
|
|
26
28
|
|
|
27
29
|
export type AptlyDocumentSchemaBoligmappaStatus = AptlyDocumentSchemaBoligmappaStatusSchema<string, string>;
|
package/models/extends.d.ts
CHANGED
|
@@ -1,8 +1,21 @@
|
|
|
1
1
|
import { AptlyUserSchema } from './user';
|
|
2
2
|
import { AptlyHistoryType } from '../enums';
|
|
3
|
+
export interface AptlyBaseSchema<ID, DATE> {
|
|
4
|
+
_id: ID;
|
|
5
|
+
name: string;
|
|
6
|
+
archived: boolean;
|
|
7
|
+
createdAt: DATE;
|
|
8
|
+
updatedAt: DATE;
|
|
9
|
+
}
|
|
3
10
|
export declare type AptlyHistory = AptlyHistorySchema<string, string>;
|
|
4
11
|
export interface AptlyHistorySchema<ID, DATE> {
|
|
12
|
+
/**
|
|
13
|
+
* @deprecated not used in v2
|
|
14
|
+
*/
|
|
5
15
|
locked: boolean;
|
|
16
|
+
/**
|
|
17
|
+
* @deprecated use updatedAt
|
|
18
|
+
*/
|
|
6
19
|
lastChange: DATE;
|
|
7
20
|
history: AptlyHistoryHistorySchema<ID, DATE>[];
|
|
8
21
|
}
|
|
@@ -14,6 +27,7 @@ export interface AptlyHistoryHistorySchema<ID, DATE> {
|
|
|
14
27
|
diffDate: DATE;
|
|
15
28
|
diff: object;
|
|
16
29
|
user: ID | Pick<AptlyUserSchema<ID, DATE>, '_id' | 'fullName'>;
|
|
30
|
+
meta?: object;
|
|
17
31
|
}
|
|
18
32
|
export interface AptlyDBCrawlerCleaner {
|
|
19
33
|
dontClean?: boolean;
|
package/models/extends.ts
CHANGED
|
@@ -1,9 +1,23 @@
|
|
|
1
1
|
import { AptlyUserSchema } from './user';
|
|
2
2
|
import { AptlyHistoryType } from '../enums';
|
|
3
3
|
|
|
4
|
+
export interface AptlyBaseSchema<ID, DATE> {
|
|
5
|
+
_id: ID;
|
|
6
|
+
name: string;
|
|
7
|
+
archived: boolean;
|
|
8
|
+
createdAt: DATE;
|
|
9
|
+
updatedAt: DATE;
|
|
10
|
+
}
|
|
11
|
+
|
|
4
12
|
export type AptlyHistory = AptlyHistorySchema<string, string>;
|
|
5
13
|
export interface AptlyHistorySchema<ID, DATE> {
|
|
14
|
+
/**
|
|
15
|
+
* @deprecated not used in v2
|
|
16
|
+
*/
|
|
6
17
|
locked: boolean;
|
|
18
|
+
/**
|
|
19
|
+
* @deprecated use updatedAt
|
|
20
|
+
*/
|
|
7
21
|
lastChange: DATE;
|
|
8
22
|
history: AptlyHistoryHistorySchema<ID, DATE>[];
|
|
9
23
|
}
|
|
@@ -16,9 +30,10 @@ export interface AptlyHistoryHistorySchema<ID, DATE> {
|
|
|
16
30
|
diffDate: DATE;
|
|
17
31
|
diff: object;
|
|
18
32
|
user: ID | Pick<AptlyUserSchema<ID, DATE>, '_id' | 'fullName'>;
|
|
33
|
+
meta?: object;
|
|
19
34
|
}
|
|
20
35
|
|
|
21
36
|
export interface AptlyDBCrawlerCleaner {
|
|
22
37
|
dontClean?: boolean;
|
|
23
38
|
lastClean?: boolean;
|
|
24
|
-
}
|
|
39
|
+
}
|
package/models/index.d.ts
CHANGED
package/models/index.js
CHANGED
|
@@ -5,6 +5,7 @@ function __export(m) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
__export(require("./booking"));
|
|
7
7
|
__export(require("./client"));
|
|
8
|
+
__export(require("./department"));
|
|
8
9
|
__export(require("./document"));
|
|
9
10
|
__export(require("./extends"));
|
|
10
11
|
__export(require("./inquiry"));
|
package/models/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;AACA,+BAA0B;AAC1B,8BAAyB;AACzB,gCAA2B;AAC3B,+BAA0B;AAC1B,+BAA0B;AAC1B,6BAAwB;AACxB,4CAAuC;AACvC,oCAA+B;AAC/B,6BAAwB;AACxB,oCAA+B;AAC/B,4BAAuB;AACvB,gCAA2B;AAC3B,+BAA0B;AAC1B,qCAAgC;AAChC,+BAA0B;AAC1B,sCAAiC;AACjC,sCAAiC;AACjC,gCAA2B;AAC3B,2BAAsB;AACtB,4BAAuB;AACvB,qCAAgC;AAChC,kCAA6B;AAC7B,uCAAkC;AAClC,4BAAuB;AACvB,+BAA0B;AAC1B,qCAAgC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":";;;;;AACA,+BAA0B;AAC1B,8BAAyB;AACzB,kCAA6B;AAC7B,gCAA2B;AAC3B,+BAA0B;AAC1B,+BAA0B;AAC1B,6BAAwB;AACxB,4CAAuC;AACvC,oCAA+B;AAC/B,6BAAwB;AACxB,oCAA+B;AAC/B,4BAAuB;AACvB,gCAA2B;AAC3B,+BAA0B;AAC1B,qCAAgC;AAChC,+BAA0B;AAC1B,sCAAiC;AACjC,sCAAiC;AACjC,gCAA2B;AAC3B,2BAAsB;AACtB,4BAAuB;AACvB,qCAAgC;AAChC,kCAA6B;AAC7B,uCAAkC;AAClC,4BAAuB;AACvB,+BAA0B;AAC1B,qCAAgC"}
|
package/models/index.ts
CHANGED
package/models/media.d.ts
CHANGED
|
@@ -1,12 +1,8 @@
|
|
|
1
1
|
import { AptlyOrganizationSchema } from './organization';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
archived: boolean;
|
|
5
|
-
created: DATE;
|
|
6
|
-
updated: DATE;
|
|
2
|
+
import { AptlyBaseSchema } from './extends';
|
|
3
|
+
export interface AptlyMediaSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE> {
|
|
7
4
|
organization: ID | AptlyOrganizationSchema<ID, DATE>;
|
|
8
5
|
src: string;
|
|
9
|
-
name: string;
|
|
10
6
|
alt: string;
|
|
11
7
|
caption?: string;
|
|
12
8
|
title?: string;
|
|
@@ -29,6 +25,14 @@ export interface AptlyMediaSchema<ID, DATE> {
|
|
|
29
25
|
placeholder: boolean;
|
|
30
26
|
url: string;
|
|
31
27
|
original_filename: string;
|
|
28
|
+
/**
|
|
29
|
+
* @deprecated use createdAt
|
|
30
|
+
*/
|
|
31
|
+
created: DATE;
|
|
32
|
+
/**
|
|
33
|
+
* @deprecated use updatedAt
|
|
34
|
+
*/
|
|
35
|
+
updated: DATE;
|
|
32
36
|
srcUrl?: string;
|
|
33
37
|
uploadSignature?: string;
|
|
34
38
|
}
|
package/models/media.ts
CHANGED
|
@@ -1,14 +1,10 @@
|
|
|
1
1
|
import { AptlyOrganizationSchema } from './organization';
|
|
2
|
+
import { AptlyBaseSchema } from './extends';
|
|
2
3
|
|
|
3
|
-
export interface AptlyMediaSchema<ID, DATE> {
|
|
4
|
+
export interface AptlyMediaSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE> {
|
|
4
5
|
// Aptly data
|
|
5
|
-
_id: ID;
|
|
6
|
-
archived: boolean;
|
|
7
|
-
created: DATE;
|
|
8
|
-
updated: DATE;
|
|
9
6
|
organization: ID | AptlyOrganizationSchema<ID, DATE>;
|
|
10
7
|
src: string;
|
|
11
|
-
name: string;
|
|
12
8
|
alt: string;
|
|
13
9
|
caption?: string;
|
|
14
10
|
title?: string;
|
|
@@ -34,6 +30,15 @@ export interface AptlyMediaSchema<ID, DATE> {
|
|
|
34
30
|
url: string;
|
|
35
31
|
original_filename: string;
|
|
36
32
|
|
|
33
|
+
/**
|
|
34
|
+
* @deprecated use createdAt
|
|
35
|
+
*/
|
|
36
|
+
created: DATE;
|
|
37
|
+
/**
|
|
38
|
+
* @deprecated use updatedAt
|
|
39
|
+
*/
|
|
40
|
+
updated: DATE;
|
|
41
|
+
|
|
37
42
|
// Aptly recognize help values
|
|
38
43
|
srcUrl?: string; // Recognize image if uploaded with url.
|
|
39
44
|
uploadSignature?: string; // Recognize images with buffer content
|
package/models/option-label.d.ts
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
|
+
import { AptlyBaseSchema } from './extends';
|
|
1
2
|
export declare type AptlyOptionLabel = AptlyOptionLabelSchema<string, string>;
|
|
2
|
-
export interface AptlyOptionLabelSchema<ID, DATE> {
|
|
3
|
-
_id: ID;
|
|
4
|
-
name: string;
|
|
5
|
-
created: DATE;
|
|
3
|
+
export interface AptlyOptionLabelSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE> {
|
|
6
4
|
organization?: string;
|
|
7
5
|
project?: string;
|
|
8
|
-
|
|
6
|
+
/**
|
|
7
|
+
* @deprecated use createdAt
|
|
8
|
+
*/
|
|
9
|
+
created: DATE;
|
|
9
10
|
}
|
package/models/option-label.ts
CHANGED
|
@@ -1,10 +1,12 @@
|
|
|
1
|
+
import { AptlyBaseSchema } from './extends';
|
|
1
2
|
|
|
2
3
|
export type AptlyOptionLabel = AptlyOptionLabelSchema<string, string>;
|
|
3
|
-
export interface AptlyOptionLabelSchema<ID, DATE> {
|
|
4
|
-
_id: ID;
|
|
5
|
-
name: string;
|
|
6
|
-
created: DATE;
|
|
4
|
+
export interface AptlyOptionLabelSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE> {
|
|
7
5
|
organization?: string;
|
|
8
6
|
project?: string;
|
|
9
|
-
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* @deprecated use createdAt
|
|
10
|
+
*/
|
|
11
|
+
created: DATE;
|
|
10
12
|
}
|
package/models/order.d.ts
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import { AptlyOrderStatus } from '../enums';
|
|
2
2
|
import { AptlyUnitItemParamSchema } from './unit';
|
|
3
|
+
import { AptlyBaseSchema } from './extends';
|
|
3
4
|
export declare type AptlyOrder = AptlyOrderSchema<string, string>;
|
|
4
|
-
export interface AptlyOrderSchema<ID, DATE> {
|
|
5
|
-
_id: ID;
|
|
5
|
+
export interface AptlyOrderSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'name' | 'archived'> {
|
|
6
6
|
orderNumber: string;
|
|
7
|
-
created: DATE;
|
|
8
7
|
organization: ID;
|
|
9
8
|
project: ID;
|
|
10
9
|
period: ID;
|
|
@@ -17,6 +16,10 @@ export interface AptlyOrderSchema<ID, DATE> {
|
|
|
17
16
|
items: AptlyOrderItemSchema<ID, DATE>[];
|
|
18
17
|
totalCost: number;
|
|
19
18
|
pricePipeline: AptlyOrderPricePipelineItemSchema<ID>[];
|
|
19
|
+
/**
|
|
20
|
+
* @deprecated use createdAt
|
|
21
|
+
*/
|
|
22
|
+
created: DATE;
|
|
20
23
|
}
|
|
21
24
|
export declare type AptlyOrderPricePipelineItem = AptlyOrderPricePipelineItemSchema<string>;
|
|
22
25
|
export interface AptlyOrderPricePipelineItemSchema<ID> {
|
|
@@ -46,6 +49,7 @@ export interface AptlyOrderItemSchema<ID, DATE> {
|
|
|
46
49
|
producer: ID;
|
|
47
50
|
params: AptlyUnitItemParamSchema<ID, DATE>[];
|
|
48
51
|
quantity: number;
|
|
52
|
+
unitCost: number;
|
|
49
53
|
pricePipeline: AptlyOrderItemPricePipelineSchema<ID>[];
|
|
50
54
|
}
|
|
51
55
|
export declare type AptlyOrderItemPricePipeline = AptlyOrderItemPricePipelineSchema<string>;
|
package/models/order.ts
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import { AptlyOrderStatus } from '../enums';
|
|
2
2
|
import { AptlyUnitItemParamSchema } from './unit';
|
|
3
|
+
import { AptlyBaseSchema } from './extends';
|
|
3
4
|
|
|
4
5
|
export type AptlyOrder = AptlyOrderSchema<string, string>;
|
|
5
|
-
export interface AptlyOrderSchema<ID, DATE> {
|
|
6
|
-
_id: ID;
|
|
6
|
+
export interface AptlyOrderSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'name' | 'archived'> {
|
|
7
7
|
orderNumber: string;
|
|
8
|
-
created: DATE;
|
|
9
8
|
organization: ID;
|
|
10
9
|
project: ID;
|
|
11
10
|
period: ID;
|
|
@@ -18,6 +17,11 @@ export interface AptlyOrderSchema<ID, DATE> {
|
|
|
18
17
|
items: AptlyOrderItemSchema<ID, DATE>[];
|
|
19
18
|
totalCost: number;
|
|
20
19
|
pricePipeline: AptlyOrderPricePipelineItemSchema<ID>[];
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* @deprecated use createdAt
|
|
23
|
+
*/
|
|
24
|
+
created: DATE;
|
|
21
25
|
}
|
|
22
26
|
|
|
23
27
|
export type AptlyOrderPricePipelineItem = AptlyOrderPricePipelineItemSchema<string>;
|
|
@@ -50,6 +54,7 @@ export interface AptlyOrderItemSchema<ID, DATE> {
|
|
|
50
54
|
producer: ID;
|
|
51
55
|
params: AptlyUnitItemParamSchema<ID, DATE>[];
|
|
52
56
|
quantity: number;
|
|
57
|
+
unitCost: number;
|
|
53
58
|
pricePipeline: AptlyOrderItemPricePipelineSchema<ID>[];
|
|
54
59
|
}
|
|
55
60
|
|
package/models/organization.d.ts
CHANGED
|
@@ -2,10 +2,11 @@ import { AptlyPermissionModulesModels, AptlyPermissionOrganizationModels } from
|
|
|
2
2
|
import { AptlySignageSchema } from '../core/signage';
|
|
3
3
|
import { AptlyUserSchema } from './user';
|
|
4
4
|
import { AptlyMediaSrc } from './media';
|
|
5
|
+
import { AptlyBaseSchema } from './extends';
|
|
6
|
+
import { AptlyDepartmentGeneric } from './department';
|
|
7
|
+
import { AptlyProducerSchema } from './producer';
|
|
5
8
|
export declare type AptlyOrganization = AptlyOrganizationSchema<string, string>;
|
|
6
|
-
export interface AptlyOrganizationSchema<ID, DATE> {
|
|
7
|
-
_id: ID;
|
|
8
|
-
name: string;
|
|
9
|
+
export interface AptlyOrganizationSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE> {
|
|
9
10
|
slug: string;
|
|
10
11
|
logo?: string | null;
|
|
11
12
|
logoMedia?: AptlyMediaSrc | null;
|
|
@@ -23,12 +24,15 @@ export interface AptlyOrganizationSchema<ID, DATE> {
|
|
|
23
24
|
};
|
|
24
25
|
phone: string;
|
|
25
26
|
email: string;
|
|
26
|
-
created: DATE;
|
|
27
|
-
archived: boolean;
|
|
28
27
|
members: AptlyOrganizationMemberSchema<ID, DATE>[];
|
|
29
28
|
modules: AptlyPermissionModulesModels[];
|
|
30
29
|
contractSign?: AptlySignageSchema<ID, DATE>;
|
|
31
30
|
integrations: AptlyOrganizationIntegrationsSchema<ID>[];
|
|
31
|
+
invites: AptlyOrganizationInviteSchema<ID, DATE>[];
|
|
32
|
+
/**
|
|
33
|
+
* @deprecated use createdAt
|
|
34
|
+
*/
|
|
35
|
+
created: DATE;
|
|
32
36
|
}
|
|
33
37
|
export declare type AptlyOrganizationIntegrations = AptlyOrganizationIntegrationsSchema<string>;
|
|
34
38
|
export interface AptlyOrganizationIntegrationsSchema<ID> {
|
|
@@ -42,4 +46,21 @@ export interface AptlyOrganizationMemberSchema<ID, DATE> {
|
|
|
42
46
|
_id: ID;
|
|
43
47
|
user: AptlyUserSchema<ID, DATE> | ID;
|
|
44
48
|
permissions: AptlyPermissionOrganizationModels[];
|
|
49
|
+
projects?: (ID | AptlyProducerSchema<ID, DATE>)[] | null;
|
|
50
|
+
departments?: (ID | AptlyDepartmentGeneric<ID, DATE>)[];
|
|
51
|
+
}
|
|
52
|
+
export declare type AptlyOrganizationInvite = AptlyOrganizationInviteSchema<string, string>;
|
|
53
|
+
export interface AptlyOrganizationInviteSchema<ID, DATE> {
|
|
54
|
+
_id: ID;
|
|
55
|
+
code: string;
|
|
56
|
+
created: DATE;
|
|
57
|
+
permissions?: AptlyPermissionOrganizationModels[];
|
|
58
|
+
projects?: ID[] | null;
|
|
59
|
+
departments?: ID[] | null;
|
|
60
|
+
claim: {
|
|
61
|
+
email?: string;
|
|
62
|
+
claimed: boolean;
|
|
63
|
+
claimedBy: ID;
|
|
64
|
+
claimTime?: DATE;
|
|
65
|
+
};
|
|
45
66
|
}
|
package/models/organization.ts
CHANGED
|
@@ -2,11 +2,12 @@ import { AptlyPermissionModulesModels, AptlyPermissionOrganizationModels } from
|
|
|
2
2
|
import { AptlySignageSchema } from '../core/signage';
|
|
3
3
|
import { AptlyUserSchema } from './user';
|
|
4
4
|
import { AptlyMediaSrc } from './media';
|
|
5
|
+
import { AptlyBaseSchema } from './extends';
|
|
6
|
+
import { AptlyDepartmentGeneric } from './department';
|
|
7
|
+
import { AptlyProducerSchema } from './producer';
|
|
5
8
|
|
|
6
9
|
export type AptlyOrganization = AptlyOrganizationSchema<string, string>;
|
|
7
|
-
export interface AptlyOrganizationSchema<ID, DATE> {
|
|
8
|
-
_id: ID;
|
|
9
|
-
name: string;
|
|
10
|
+
export interface AptlyOrganizationSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE> {
|
|
10
11
|
slug: string;
|
|
11
12
|
logo?: string | null;
|
|
12
13
|
logoMedia?: AptlyMediaSrc | null;
|
|
@@ -24,12 +25,16 @@ export interface AptlyOrganizationSchema<ID, DATE> {
|
|
|
24
25
|
};
|
|
25
26
|
phone: string;
|
|
26
27
|
email: string;
|
|
27
|
-
created: DATE;
|
|
28
|
-
archived: boolean;
|
|
29
28
|
members: AptlyOrganizationMemberSchema<ID, DATE>[];
|
|
30
29
|
modules: AptlyPermissionModulesModels[];
|
|
31
30
|
contractSign?: AptlySignageSchema<ID, DATE>;
|
|
32
31
|
integrations: AptlyOrganizationIntegrationsSchema<ID>[];
|
|
32
|
+
invites: AptlyOrganizationInviteSchema<ID, DATE>[];
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* @deprecated use createdAt
|
|
36
|
+
*/
|
|
37
|
+
created: DATE;
|
|
33
38
|
}
|
|
34
39
|
|
|
35
40
|
export type AptlyOrganizationIntegrations = AptlyOrganizationIntegrationsSchema<string>;
|
|
@@ -45,4 +50,22 @@ export interface AptlyOrganizationMemberSchema<ID, DATE> {
|
|
|
45
50
|
_id: ID;
|
|
46
51
|
user: AptlyUserSchema<ID, DATE> | ID;
|
|
47
52
|
permissions: AptlyPermissionOrganizationModels[];
|
|
53
|
+
projects?: (ID | AptlyProducerSchema<ID, DATE>)[] | null;
|
|
54
|
+
departments?: (ID | AptlyDepartmentGeneric<ID, DATE>)[];
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
export type AptlyOrganizationInvite = AptlyOrganizationInviteSchema<string, string>;
|
|
58
|
+
export interface AptlyOrganizationInviteSchema<ID, DATE> {
|
|
59
|
+
_id: ID;
|
|
60
|
+
code: string;
|
|
61
|
+
created: DATE;
|
|
62
|
+
permissions?: AptlyPermissionOrganizationModels[];
|
|
63
|
+
projects?: ID[] | null;
|
|
64
|
+
departments?: ID[] | null;
|
|
65
|
+
claim: {
|
|
66
|
+
email?: string;
|
|
67
|
+
claimed: boolean;
|
|
68
|
+
claimedBy: ID;
|
|
69
|
+
claimTime?: DATE;
|
|
70
|
+
}
|
|
48
71
|
}
|
package/models/page.d.ts
CHANGED
|
@@ -1,19 +1,26 @@
|
|
|
1
1
|
import { AptlyPageSectionType } from '../enums';
|
|
2
|
+
import { AptlyBaseSchema } from './extends';
|
|
2
3
|
export declare type AptlyPage = AptlyPageSchema<string, string>;
|
|
3
|
-
export interface AptlyPageSchema<ID, DATE> {
|
|
4
|
-
_id: ID;
|
|
4
|
+
export interface AptlyPageSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE> {
|
|
5
5
|
slug: string;
|
|
6
|
-
name: string;
|
|
7
6
|
project: ID;
|
|
8
7
|
organization: ID;
|
|
9
|
-
showInMenu: boolean;
|
|
10
8
|
summary: string;
|
|
11
9
|
icon?: string;
|
|
12
|
-
legacy?: string;
|
|
13
|
-
image?: string;
|
|
14
10
|
upsellTemplate?: ID | null;
|
|
15
11
|
sections: AptlyPageSectionSchema<ID, DATE>[];
|
|
16
|
-
|
|
12
|
+
/**
|
|
13
|
+
* @deprecated use upsellTemplate
|
|
14
|
+
*/
|
|
15
|
+
legacy?: string;
|
|
16
|
+
/**
|
|
17
|
+
* @deprecated use upsellTemplate
|
|
18
|
+
*/
|
|
19
|
+
image?: string;
|
|
20
|
+
/**
|
|
21
|
+
* @deprecated connected with project pages
|
|
22
|
+
*/
|
|
23
|
+
showInMenu: boolean;
|
|
17
24
|
}
|
|
18
25
|
export declare type AptlyPageSection = AptlyPageSectionSchema<string, string>;
|
|
19
26
|
export interface AptlyPageSectionSchema<ID, DATE, VALUE = any> {
|
package/models/page.ts
CHANGED
|
@@ -1,20 +1,28 @@
|
|
|
1
1
|
import { AptlyPageSectionType } from '../enums';
|
|
2
|
+
import { AptlyBaseSchema } from './extends';
|
|
2
3
|
|
|
3
4
|
export type AptlyPage = AptlyPageSchema<string, string>;
|
|
4
|
-
export interface AptlyPageSchema<ID, DATE> {
|
|
5
|
-
_id: ID;
|
|
5
|
+
export interface AptlyPageSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE> {
|
|
6
6
|
slug: string;
|
|
7
|
-
name: string;
|
|
8
7
|
project: ID;
|
|
9
8
|
organization: ID;
|
|
10
|
-
showInMenu: boolean;
|
|
11
9
|
summary: string;
|
|
12
10
|
icon?: string;
|
|
13
|
-
legacy?: string; // Deprecated
|
|
14
|
-
image?: string; // Deprecated
|
|
15
11
|
upsellTemplate?: ID | null;
|
|
16
12
|
sections: AptlyPageSectionSchema<ID, DATE>[];
|
|
17
|
-
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* @deprecated use upsellTemplate
|
|
16
|
+
*/
|
|
17
|
+
legacy?: string; // Deprecated
|
|
18
|
+
/**
|
|
19
|
+
* @deprecated use upsellTemplate
|
|
20
|
+
*/
|
|
21
|
+
image?: string; // Deprecated
|
|
22
|
+
/**
|
|
23
|
+
* @deprecated connected with project pages
|
|
24
|
+
*/
|
|
25
|
+
showInMenu: boolean;
|
|
18
26
|
}
|
|
19
27
|
|
|
20
28
|
export type AptlyPageSection = AptlyPageSectionSchema<string, string>;
|