@icanbwell/bwell-sdk-ts 1.117.0 → 1.118.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/dist/__version__.d.ts +1 -1
- package/dist/__version__.js +1 -1
- package/dist/api/base/support/create-support-request-request.d.ts +5 -0
- package/dist/api/base/support/create-support-request-request.js +4 -0
- package/dist/api/graphql-api/support/create-support-request-request-factory.js +2 -0
- package/dist/graphql/schema.d.ts +5 -0
- package/package.json +1 -1
package/dist/__version__.d.ts
CHANGED
package/dist/__version__.js
CHANGED
|
@@ -11,9 +11,14 @@ export type SupportRequestMetadataInput = {
|
|
|
11
11
|
device?: string;
|
|
12
12
|
appVersion?: string;
|
|
13
13
|
};
|
|
14
|
+
export type SupportRequestEmailCcInput = {
|
|
15
|
+
email: string;
|
|
16
|
+
name?: string;
|
|
17
|
+
};
|
|
14
18
|
export type CreateSupportRequestRequestInput = {
|
|
15
19
|
comment: CommentInput;
|
|
16
20
|
email?: string;
|
|
21
|
+
emailCcs?: SupportRequestEmailCcInput[];
|
|
17
22
|
fields: SupportRequestFieldsInput;
|
|
18
23
|
metadata?: SupportRequestMetadataInput;
|
|
19
24
|
name?: string;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ValidationRequest, } from "../../../requests/index.js";
|
|
2
2
|
class CreateSupportRequestRequestValidator {
|
|
3
3
|
validate(data, errors) {
|
|
4
|
+
var _a;
|
|
4
5
|
if (!data.subject.trim()) {
|
|
5
6
|
errors.add("Subject is required");
|
|
6
7
|
}
|
|
@@ -10,6 +11,9 @@ class CreateSupportRequestRequestValidator {
|
|
|
10
11
|
if (!data.fields.category.trim()) {
|
|
11
12
|
errors.add("Category is required");
|
|
12
13
|
}
|
|
14
|
+
if ((_a = data.emailCcs) === null || _a === void 0 ? void 0 : _a.some((cc) => !cc.email.trim())) {
|
|
15
|
+
errors.add("CC email is required");
|
|
16
|
+
}
|
|
13
17
|
}
|
|
14
18
|
}
|
|
15
19
|
export class CreateSupportRequestRequest extends ValidationRequest {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export class GraphQLCreateSupportRequestRequestFactory {
|
|
2
2
|
create(request) {
|
|
3
|
+
var _a;
|
|
3
4
|
const data = request.data();
|
|
4
5
|
return {
|
|
5
6
|
input: {
|
|
@@ -12,6 +13,7 @@ export class GraphQLCreateSupportRequestRequestFactory {
|
|
|
12
13
|
category: data.fields.category,
|
|
13
14
|
},
|
|
14
15
|
email: data.email,
|
|
16
|
+
emailCcs: (_a = data.emailCcs) === null || _a === void 0 ? void 0 : _a.map(({ email, name }) => ({ email, name })),
|
|
15
17
|
name: data.name,
|
|
16
18
|
metadata: data.metadata,
|
|
17
19
|
},
|
package/dist/graphql/schema.d.ts
CHANGED
|
@@ -1958,6 +1958,7 @@ export type CreateSupportCommentResponse = {
|
|
|
1958
1958
|
export type CreateSupportRequestInput = {
|
|
1959
1959
|
comment: CommentInput;
|
|
1960
1960
|
email?: InputMaybe<Scalars['String']['input']>;
|
|
1961
|
+
emailCcs?: InputMaybe<Array<SupportRequestEmailCcInput>>;
|
|
1961
1962
|
fields: SupportRequestFieldsInput;
|
|
1962
1963
|
metadata?: InputMaybe<SupportRequestMetadataInput>;
|
|
1963
1964
|
name?: InputMaybe<Scalars['String']['input']>;
|
|
@@ -8197,6 +8198,10 @@ export type SupportRequest = {
|
|
|
8197
8198
|
status: RequestStatus;
|
|
8198
8199
|
subject: Scalars['String']['output'];
|
|
8199
8200
|
};
|
|
8201
|
+
export type SupportRequestEmailCcInput = {
|
|
8202
|
+
email: Scalars['String']['input'];
|
|
8203
|
+
name?: InputMaybe<Scalars['String']['input']>;
|
|
8204
|
+
};
|
|
8200
8205
|
export type SupportRequestFieldsInput = {
|
|
8201
8206
|
category: Scalars['String']['input'];
|
|
8202
8207
|
};
|