@aptly-as/types 2.3.2 → 2.3.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/fields.d.ts +4 -2
- package/core/scope.d.ts +1 -0
- package/core/scope.js +1 -0
- package/enums/fields.d.ts +19 -18
- package/enums/fields.js +19 -18
- package/enums/index.d.ts +17 -0
- package/enums/index.js +18 -0
- package/models/email.d.ts +16 -0
- package/models/email.js +1 -0
- package/models/extends.d.ts +3 -0
- package/models/index.d.ts +1 -0
- package/models/index.js +1 -0
- package/models/order.d.ts +3 -0
- package/models/organization.d.ts +1 -0
- package/models/producer.d.ts +9 -0
- package/models/project.d.ts +2 -1
- package/models/unit-email.d.ts +2 -14
- package/models/unit-email.js +1 -14
- package/package.json +1 -1
package/core/fields.d.ts
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import { AptlyFieldType } from '../enums/index.js';
|
|
2
|
-
export
|
|
2
|
+
export type AptlyDraftJS = string;
|
|
3
|
+
export type AptlyMarkdown = string;
|
|
4
|
+
export interface AptlyField<L = string> {
|
|
3
5
|
type: AptlyFieldType;
|
|
4
|
-
label:
|
|
6
|
+
label: L;
|
|
5
7
|
placeholder?: string;
|
|
6
8
|
required?: boolean;
|
|
7
9
|
pattern?: string;
|
package/core/scope.d.ts
CHANGED
|
@@ -56,6 +56,7 @@ export declare enum AptlyScopes {
|
|
|
56
56
|
ProjectAlgorithms = "projectAlgorithms",
|
|
57
57
|
ProjectBooking = "projectBooking",
|
|
58
58
|
ProjectDocuments = "projectDocuments",
|
|
59
|
+
ProjectEmails = "projectEmails",
|
|
59
60
|
ProjectInquiry = "projectInquiry",
|
|
60
61
|
ProjectInquiryComplaint = "projectInquiryComplaint",
|
|
61
62
|
ProjectOrders = "projectOrders",
|
package/core/scope.js
CHANGED
|
@@ -58,6 +58,7 @@ export var AptlyScopes;
|
|
|
58
58
|
AptlyScopes["ProjectAlgorithms"] = "projectAlgorithms";
|
|
59
59
|
AptlyScopes["ProjectBooking"] = "projectBooking";
|
|
60
60
|
AptlyScopes["ProjectDocuments"] = "projectDocuments";
|
|
61
|
+
AptlyScopes["ProjectEmails"] = "projectEmails";
|
|
61
62
|
AptlyScopes["ProjectInquiry"] = "projectInquiry";
|
|
62
63
|
AptlyScopes["ProjectInquiryComplaint"] = "projectInquiryComplaint";
|
|
63
64
|
AptlyScopes["ProjectOrders"] = "projectOrders";
|
package/enums/fields.d.ts
CHANGED
|
@@ -1,27 +1,28 @@
|
|
|
1
1
|
export declare enum AptlyFieldType {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
Text = "text",
|
|
7
|
-
StringArray = "string-array",
|
|
8
|
-
Password = "password",
|
|
9
|
-
TextArea = "text-area",
|
|
10
|
-
Email = "email",
|
|
11
|
-
Number = "number",
|
|
2
|
+
BulkIds = "bulk-ids",
|
|
3
|
+
Checkbox = "checkbox",
|
|
4
|
+
Custom = "custom",
|
|
5
|
+
Color = "color",
|
|
12
6
|
Date = "date",
|
|
13
7
|
DateTime = "date-time",
|
|
14
|
-
Color = "color",
|
|
15
|
-
Select = "select",
|
|
16
|
-
File = "file",
|
|
17
|
-
Files = "files",
|
|
18
8
|
Documents = "documents",
|
|
19
9
|
DraftJS = "draft-js",
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
10
|
+
Email = "email",
|
|
11
|
+
File = "file",
|
|
12
|
+
Files = "files",
|
|
23
13
|
Hidden = "hidden",
|
|
14
|
+
Images = "images",
|
|
15
|
+
Image = "image",
|
|
16
|
+
Markdown = "markdown",
|
|
17
|
+
Media = "media",
|
|
18
|
+
Number = "number",
|
|
19
|
+
Object = "object",
|
|
20
|
+
Password = "password",
|
|
21
|
+
Reference = "reference",
|
|
22
|
+
StringArray = "string-array",
|
|
23
|
+
Select = "select",
|
|
24
24
|
Sort = "sort",
|
|
25
25
|
Switch = "switch",
|
|
26
|
-
|
|
26
|
+
Text = "text",
|
|
27
|
+
TextArea = "text-area"
|
|
27
28
|
}
|
package/enums/fields.js
CHANGED
|
@@ -1,28 +1,29 @@
|
|
|
1
1
|
export var AptlyFieldType;
|
|
2
2
|
(function (AptlyFieldType) {
|
|
3
|
-
AptlyFieldType["
|
|
4
|
-
AptlyFieldType["
|
|
5
|
-
AptlyFieldType["
|
|
6
|
-
AptlyFieldType["
|
|
7
|
-
AptlyFieldType["Text"] = "text";
|
|
8
|
-
AptlyFieldType["StringArray"] = "string-array";
|
|
9
|
-
AptlyFieldType["Password"] = "password";
|
|
10
|
-
AptlyFieldType["TextArea"] = "text-area";
|
|
11
|
-
AptlyFieldType["Email"] = "email";
|
|
12
|
-
AptlyFieldType["Number"] = "number";
|
|
3
|
+
AptlyFieldType["BulkIds"] = "bulk-ids";
|
|
4
|
+
AptlyFieldType["Checkbox"] = "checkbox";
|
|
5
|
+
AptlyFieldType["Custom"] = "custom";
|
|
6
|
+
AptlyFieldType["Color"] = "color";
|
|
13
7
|
AptlyFieldType["Date"] = "date";
|
|
14
8
|
AptlyFieldType["DateTime"] = "date-time";
|
|
15
|
-
AptlyFieldType["Color"] = "color";
|
|
16
|
-
AptlyFieldType["Select"] = "select";
|
|
17
|
-
AptlyFieldType["File"] = "file";
|
|
18
|
-
AptlyFieldType["Files"] = "files";
|
|
19
9
|
AptlyFieldType["Documents"] = "documents";
|
|
20
10
|
AptlyFieldType["DraftJS"] = "draft-js";
|
|
21
|
-
AptlyFieldType["
|
|
22
|
-
AptlyFieldType["
|
|
23
|
-
AptlyFieldType["
|
|
11
|
+
AptlyFieldType["Email"] = "email";
|
|
12
|
+
AptlyFieldType["File"] = "file";
|
|
13
|
+
AptlyFieldType["Files"] = "files";
|
|
24
14
|
AptlyFieldType["Hidden"] = "hidden";
|
|
15
|
+
AptlyFieldType["Images"] = "images";
|
|
16
|
+
AptlyFieldType["Image"] = "image";
|
|
17
|
+
AptlyFieldType["Markdown"] = "markdown";
|
|
18
|
+
AptlyFieldType["Media"] = "media";
|
|
19
|
+
AptlyFieldType["Number"] = "number";
|
|
20
|
+
AptlyFieldType["Object"] = "object";
|
|
21
|
+
AptlyFieldType["Password"] = "password";
|
|
22
|
+
AptlyFieldType["Reference"] = "reference";
|
|
23
|
+
AptlyFieldType["StringArray"] = "string-array";
|
|
24
|
+
AptlyFieldType["Select"] = "select";
|
|
25
25
|
AptlyFieldType["Sort"] = "sort";
|
|
26
26
|
AptlyFieldType["Switch"] = "switch";
|
|
27
|
-
AptlyFieldType["
|
|
27
|
+
AptlyFieldType["Text"] = "text";
|
|
28
|
+
AptlyFieldType["TextArea"] = "text-area";
|
|
28
29
|
})(AptlyFieldType || (AptlyFieldType = {}));
|
package/enums/index.d.ts
CHANGED
|
@@ -124,3 +124,20 @@ export declare enum AptlyOrganizationStatus {
|
|
|
124
124
|
Paused = 3,
|
|
125
125
|
Closed = 4
|
|
126
126
|
}
|
|
127
|
+
export declare enum AptlyEmailType {
|
|
128
|
+
Invite = "invite",
|
|
129
|
+
Inquiry = "inquiry",
|
|
130
|
+
NewOwner = "new-owner",
|
|
131
|
+
PeriodOpen = "period-open",
|
|
132
|
+
PeriodClose = "period-close",
|
|
133
|
+
BookingConfirm = "booking-confirm",
|
|
134
|
+
BookingCancel = "booking-cancel",
|
|
135
|
+
OrderCreated = "order-created",
|
|
136
|
+
OrderSign = "order-sign",
|
|
137
|
+
OrderSigned = "order-signed",
|
|
138
|
+
OrderPay = "order-pay",
|
|
139
|
+
OrderPayed = "order-payed",
|
|
140
|
+
OrderReceipt = "order-receipt",
|
|
141
|
+
OrderCompleted = "order-completed",
|
|
142
|
+
ActionRecipients = "action_recipients"
|
|
143
|
+
}
|
package/enums/index.js
CHANGED
|
@@ -143,3 +143,21 @@ export var AptlyOrganizationStatus;
|
|
|
143
143
|
AptlyOrganizationStatus[AptlyOrganizationStatus["Paused"] = 3] = "Paused";
|
|
144
144
|
AptlyOrganizationStatus[AptlyOrganizationStatus["Closed"] = 4] = "Closed";
|
|
145
145
|
})(AptlyOrganizationStatus || (AptlyOrganizationStatus = {}));
|
|
146
|
+
export var AptlyEmailType;
|
|
147
|
+
(function (AptlyEmailType) {
|
|
148
|
+
AptlyEmailType["Invite"] = "invite";
|
|
149
|
+
AptlyEmailType["Inquiry"] = "inquiry";
|
|
150
|
+
AptlyEmailType["NewOwner"] = "new-owner";
|
|
151
|
+
AptlyEmailType["PeriodOpen"] = "period-open";
|
|
152
|
+
AptlyEmailType["PeriodClose"] = "period-close";
|
|
153
|
+
AptlyEmailType["BookingConfirm"] = "booking-confirm";
|
|
154
|
+
AptlyEmailType["BookingCancel"] = "booking-cancel";
|
|
155
|
+
AptlyEmailType["OrderCreated"] = "order-created";
|
|
156
|
+
AptlyEmailType["OrderSign"] = "order-sign";
|
|
157
|
+
AptlyEmailType["OrderSigned"] = "order-signed";
|
|
158
|
+
AptlyEmailType["OrderPay"] = "order-pay";
|
|
159
|
+
AptlyEmailType["OrderPayed"] = "order-payed";
|
|
160
|
+
AptlyEmailType["OrderReceipt"] = "order-receipt";
|
|
161
|
+
AptlyEmailType["OrderCompleted"] = "order-completed";
|
|
162
|
+
AptlyEmailType["ActionRecipients"] = "action_recipients";
|
|
163
|
+
})(AptlyEmailType || (AptlyEmailType = {}));
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { AptlyEmailType } from '../enums/index.js';
|
|
2
|
+
import { AptlyMarkdown } from '../core';
|
|
3
|
+
export type AptlyEmail = AptlyEmailSchema<string, string>;
|
|
4
|
+
export interface AptlyEmailSchema<ID, DATE> {
|
|
5
|
+
_id: ID;
|
|
6
|
+
name: string;
|
|
7
|
+
type: AptlyEmailType;
|
|
8
|
+
subject: string;
|
|
9
|
+
content: AptlyMarkdown;
|
|
10
|
+
actionLabel?: string;
|
|
11
|
+
organization: ID;
|
|
12
|
+
project?: ID;
|
|
13
|
+
archived: boolean;
|
|
14
|
+
createdAt: DATE;
|
|
15
|
+
updatedAt: DATE;
|
|
16
|
+
}
|
package/models/email.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/models/extends.d.ts
CHANGED
package/models/index.d.ts
CHANGED
package/models/index.js
CHANGED
package/models/order.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { AptlyOrderStatus } from '../enums/index.js';
|
|
2
2
|
import { AptlyAppImplementationSetting, AptlyAppSchema } from './app.js';
|
|
3
3
|
import { AptlyDocumentSchema } from './document.js';
|
|
4
|
+
import { AptlyEmailSchema } from './email.js';
|
|
4
5
|
import { AptlyOrganizationAppConfigSchema, AptlyOrganizationSchema } from './organization.js';
|
|
5
6
|
import { AptlyProductSchema } from './product.js';
|
|
6
7
|
import { AptlyProject, AptlyProjectPeriodSchema, AptlyProjectSchema } from './project.js';
|
|
@@ -118,6 +119,7 @@ export interface AptlyOrderActionPostBody {
|
|
|
118
119
|
app?: string;
|
|
119
120
|
emailSubject: string;
|
|
120
121
|
emailText: string;
|
|
122
|
+
emailMarkdown: string;
|
|
121
123
|
users: AptlyOrderActionPostBodyUser[];
|
|
122
124
|
deadlineInDays?: number;
|
|
123
125
|
}
|
|
@@ -132,6 +134,7 @@ export interface AptlyOrderActionItemSchema<ID, DATE, S extends object> {
|
|
|
132
134
|
path: string;
|
|
133
135
|
app?: Pick<AptlyAppSchema<ID, DATE>, '_id' | 'name' | 'sign' | 'logo' | 'settings'>;
|
|
134
136
|
appSettings?: AptlyOrganizationAppConfigSchema<ID, DATE, S>['settings'];
|
|
137
|
+
email?: AptlyEmailSchema<ID, DATE>;
|
|
135
138
|
}
|
|
136
139
|
export interface AptlyOrderActionItemSignSettings {
|
|
137
140
|
[AptlyAppImplementationSetting.SignCostPer]: number;
|
package/models/organization.d.ts
CHANGED
|
@@ -13,6 +13,7 @@ export type AptlyOrganization = AptlyOrganizationSchema<string, string>;
|
|
|
13
13
|
export interface AptlyOrganizationSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE>, AptlyHistorySchema<ID, DATE> {
|
|
14
14
|
slug: string;
|
|
15
15
|
number?: string;
|
|
16
|
+
vat?: string;
|
|
16
17
|
logo?: string | null;
|
|
17
18
|
logoMedia?: AptlyMediaSrc | null;
|
|
18
19
|
negativeLogoMedia?: AptlyMediaSrc | null;
|
package/models/producer.d.ts
CHANGED
|
@@ -9,7 +9,16 @@ export interface AptlyProducerSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE>
|
|
|
9
9
|
organization?: ID;
|
|
10
10
|
createdBy: ID;
|
|
11
11
|
tags: ID[];
|
|
12
|
+
trademarks?: AptlyProducerTrademarkSchema<ID, DATE>[];
|
|
12
13
|
featured: boolean;
|
|
13
14
|
extends: ID;
|
|
14
15
|
created: DATE;
|
|
15
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/project.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AptlyProjectStatus } from '../enums/index.js';
|
|
1
|
+
import { AptlyEmailType, AptlyProjectStatus } from '../enums/index.js';
|
|
2
2
|
import { AptlyAlgorithm, AptlyAlgorithmPipeline, AptlyAlgorithmPipelineSchema, AptlyAlgorithmSchema } from './algorithm.js';
|
|
3
3
|
import { AptlyAppSchema } from './app.js';
|
|
4
4
|
import { AptlyOrganizationSchema } from './organization.js';
|
|
@@ -97,6 +97,7 @@ export type AptlyProjectNotify = AptlyProjectNotifySchema<string, string>;
|
|
|
97
97
|
interface AptlyProjectNotifySchema<ID, DATE> {
|
|
98
98
|
_id: ID;
|
|
99
99
|
user: AptlyUserSchema<ID, DATE> | ID;
|
|
100
|
+
types?: AptlyEmailType[];
|
|
100
101
|
inquiry: boolean;
|
|
101
102
|
booking: boolean;
|
|
102
103
|
complaint: boolean;
|
package/models/unit-email.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { AptlyEmailType } from '../enums/index.js';
|
|
1
2
|
import { AptlyBookingSchema } from './booking.js';
|
|
2
3
|
import { AptlyBaseSchema } from './extends.js';
|
|
3
4
|
import { AptlyInquirySchema } from './inquiry.js';
|
|
@@ -6,7 +7,7 @@ import { AptlyProjectSchema } from './project.js';
|
|
|
6
7
|
import { AptlyUnitSchema } from './unit.js';
|
|
7
8
|
export type AptlyUnitEmail = AptlyUnitEmailSchema<string, string>;
|
|
8
9
|
export interface AptlyUnitEmailSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'name' | 'archived'> {
|
|
9
|
-
type:
|
|
10
|
+
type: AptlyEmailType;
|
|
10
11
|
to: string[];
|
|
11
12
|
subject: string;
|
|
12
13
|
references: string;
|
|
@@ -18,16 +19,3 @@ export interface AptlyUnitEmailSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID,
|
|
|
18
19
|
booking?: ID | AptlyBookingSchema<ID, DATE>;
|
|
19
20
|
created: DATE;
|
|
20
21
|
}
|
|
21
|
-
export declare enum AptlyUnitEmailType {
|
|
22
|
-
Inquiry = "inquiry",
|
|
23
|
-
Invite = "invite",
|
|
24
|
-
NewOwner = "new-owner",
|
|
25
|
-
PeriodOpen = "period-open",
|
|
26
|
-
PeriodClose = "period-close",
|
|
27
|
-
BookingConfirm = "booking-confirm",
|
|
28
|
-
BookingCancel = "booking-cancel",
|
|
29
|
-
OrderCreated = "order-created",
|
|
30
|
-
OrderSigned = "order-signed",
|
|
31
|
-
OrderCompleted = "order-completed",
|
|
32
|
-
ActionRecipients = "action_recipients"
|
|
33
|
-
}
|
package/models/unit-email.js
CHANGED
|
@@ -1,14 +1 @@
|
|
|
1
|
-
export
|
|
2
|
-
(function (AptlyUnitEmailType) {
|
|
3
|
-
AptlyUnitEmailType["Inquiry"] = "inquiry";
|
|
4
|
-
AptlyUnitEmailType["Invite"] = "invite";
|
|
5
|
-
AptlyUnitEmailType["NewOwner"] = "new-owner";
|
|
6
|
-
AptlyUnitEmailType["PeriodOpen"] = "period-open";
|
|
7
|
-
AptlyUnitEmailType["PeriodClose"] = "period-close";
|
|
8
|
-
AptlyUnitEmailType["BookingConfirm"] = "booking-confirm";
|
|
9
|
-
AptlyUnitEmailType["BookingCancel"] = "booking-cancel";
|
|
10
|
-
AptlyUnitEmailType["OrderCreated"] = "order-created";
|
|
11
|
-
AptlyUnitEmailType["OrderSigned"] = "order-signed";
|
|
12
|
-
AptlyUnitEmailType["OrderCompleted"] = "order-completed";
|
|
13
|
-
AptlyUnitEmailType["ActionRecipients"] = "action_recipients";
|
|
14
|
-
})(AptlyUnitEmailType || (AptlyUnitEmailType = {}));
|
|
1
|
+
export {};
|