@webiny/api-apw 0.0.0-unstable.6e5425ee89 → 0.0.0-unstable.78f581c1d2
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/ApwChangeRequestNotification.js +10 -0
- package/ApwChangeRequestNotification.js.map +1 -1
- package/ApwCommentNotification.js +10 -0
- package/ApwCommentNotification.js.map +1 -1
- package/ApwContentReviewNotification.js +10 -0
- package/ApwContentReviewNotification.js.map +1 -1
- package/ApwContentUrlPlugin.js +10 -0
- package/ApwContentUrlPlugin.js.map +1 -1
- package/ContentApwSettingsPlugin.js +5 -0
- package/ContentApwSettingsPlugin.js.map +1 -1
- package/crud/createChangeRequestMethods.js +11 -4
- package/crud/createChangeRequestMethods.js.map +1 -1
- package/crud/createCommentMethods.js +12 -4
- package/crud/createCommentMethods.js.map +1 -1
- package/crud/createContentReviewMethods.js +84 -20
- package/crud/createContentReviewMethods.js.map +1 -1
- package/crud/createReviewerMethods.js +12 -4
- package/crud/createReviewerMethods.js.map +1 -1
- package/crud/createWorkflowMethods.js +17 -4
- package/crud/createWorkflowMethods.js.map +1 -1
- package/crud/index.js +25 -0
- package/crud/index.js.map +1 -1
- package/crud/utils.js +28 -0
- package/crud/utils.js.map +1 -1
- package/index.js +11 -1
- package/index.js.map +1 -1
- package/package.json +34 -34
- package/plugins/cms/CmsEntryApwSettingsGetterPlugin.js +15 -0
- package/plugins/cms/CmsEntryApwSettingsGetterPlugin.js.map +1 -1
- package/plugins/cms/apwEntryPlugins.js +8 -0
- package/plugins/cms/apwEntryPlugins.js.map +1 -1
- package/plugins/cms/index.js +13 -0
- package/plugins/cms/index.js.map +1 -1
- package/plugins/cms/linkContentReviewToEntry.js +17 -0
- package/plugins/cms/linkContentReviewToEntry.js.map +1 -1
- package/plugins/cms/linkWorkflowToEntry.js +31 -2
- package/plugins/cms/linkWorkflowToEntry.js.map +1 -1
- package/plugins/cms/notifications/changeRequestNotification.js +4 -0
- package/plugins/cms/notifications/changeRequestNotification.js.map +1 -1
- package/plugins/cms/notifications/commentNotification.js +4 -0
- package/plugins/cms/notifications/commentNotification.js.map +1 -1
- package/plugins/cms/notifications/contentReviewNotification.js +4 -0
- package/plugins/cms/notifications/contentReviewNotification.js.map +1 -1
- package/plugins/cms/notifications/contentUrl.js +8 -1
- package/plugins/cms/notifications/contentUrl.js.map +1 -1
- package/plugins/cms/triggerContentReview.js +14 -0
- package/plugins/cms/triggerContentReview.js.map +1 -1
- package/plugins/cms/updateContentReviewStatus.js +18 -0
- package/plugins/cms/updateContentReviewStatus.js.map +1 -1
- package/plugins/cms/utils.js +47 -2
- package/plugins/cms/utils.js.map +1 -1
- package/plugins/context.js +31 -0
- package/plugins/context.js.map +1 -1
- package/plugins/graphql/changeRequest.gql.js +8 -1
- package/plugins/graphql/changeRequest.gql.js.map +1 -1
- package/plugins/graphql/comment.gql.js +8 -1
- package/plugins/graphql/comment.gql.js.map +1 -1
- package/plugins/graphql/contentReview.gql.js +20 -1
- package/plugins/graphql/contentReview.gql.js.map +1 -1
- package/plugins/graphql/reviewer.gql.js +8 -1
- package/plugins/graphql/reviewer.gql.js.map +1 -1
- package/plugins/graphql/workflow.gql.js +8 -1
- package/plugins/graphql/workflow.gql.js.map +1 -1
- package/plugins/graphql.js +16 -1
- package/plugins/graphql.js.map +1 -1
- package/plugins/hooks/createReviewerFromIdentity.js +11 -2
- package/plugins/hooks/createReviewerFromIdentity.js.map +1 -1
- package/plugins/hooks/deleteChangeRequestsAfterContentReview.js +9 -1
- package/plugins/hooks/deleteChangeRequestsAfterContentReview.js.map +1 -1
- package/plugins/hooks/deleteCommentsAfterChangeRequest.js +8 -1
- package/plugins/hooks/deleteCommentsAfterChangeRequest.js.map +1 -1
- package/plugins/hooks/index.js +14 -0
- package/plugins/hooks/index.js.map +1 -1
- package/plugins/hooks/initializeContentReviewSteps.js +15 -2
- package/plugins/hooks/initializeContentReviewSteps.js.map +1 -1
- package/plugins/hooks/initializeNotifications.js +5 -0
- package/plugins/hooks/initializeNotifications.js.map +1 -1
- package/plugins/hooks/listContentReviews.js +12 -0
- package/plugins/hooks/listContentReviews.js.map +1 -1
- package/plugins/hooks/notifications/appUrl.js +4 -0
- package/plugins/hooks/notifications/appUrl.js.map +1 -1
- package/plugins/hooks/notifications/changeRequestAfterCreate.js +28 -0
- package/plugins/hooks/notifications/changeRequestAfterCreate.js.map +1 -1
- package/plugins/hooks/notifications/changeRequestUrl.js +4 -0
- package/plugins/hooks/notifications/changeRequestUrl.js.map +1 -1
- package/plugins/hooks/notifications/commentAfterCreate.js +30 -0
- package/plugins/hooks/notifications/commentAfterCreate.js.map +1 -1
- package/plugins/hooks/notifications/commentUrl.js +4 -0
- package/plugins/hooks/notifications/commentUrl.js.map +1 -1
- package/plugins/hooks/notifications/contentReviewAfterCreate.js +24 -1
- package/plugins/hooks/notifications/contentReviewAfterCreate.js.map +1 -1
- package/plugins/hooks/notifications/contentReviewUrl.js +4 -0
- package/plugins/hooks/notifications/contentReviewUrl.js.map +1 -1
- package/plugins/hooks/notifications/contentUrl.js +5 -0
- package/plugins/hooks/notifications/contentUrl.js.map +1 -1
- package/plugins/hooks/notifications/lastChangeRequestNotificationPlugin.js +4 -0
- package/plugins/hooks/notifications/lastChangeRequestNotificationPlugin.js.map +1 -1
- package/plugins/hooks/notifications/lastCommentNotificationPlugin.js +4 -0
- package/plugins/hooks/notifications/lastCommentNotificationPlugin.js.map +1 -1
- package/plugins/hooks/notifications/lastContentReviewNotificationPlugin.js +4 -0
- package/plugins/hooks/notifications/lastContentReviewNotificationPlugin.js.map +1 -1
- package/plugins/hooks/notifications/reviewers.js +7 -0
- package/plugins/hooks/notifications/reviewers.js.map +1 -1
- package/plugins/hooks/notifications/sendChangeRequestNotification.js +11 -0
- package/plugins/hooks/notifications/sendChangeRequestNotification.js.map +1 -1
- package/plugins/hooks/notifications/sendCommentNotification.js +11 -0
- package/plugins/hooks/notifications/sendCommentNotification.js.map +1 -1
- package/plugins/hooks/notifications/sendContentReviewNotification.js +11 -0
- package/plugins/hooks/notifications/sendContentReviewNotification.js.map +1 -1
- package/plugins/hooks/updatePendingChangeRequests.js +8 -0
- package/plugins/hooks/updatePendingChangeRequests.js.map +1 -1
- package/plugins/hooks/updateTotalComments.js +9 -0
- package/plugins/hooks/updateTotalComments.js.map +1 -1
- package/plugins/hooks/validateChangeRequest.js +16 -0
- package/plugins/hooks/validateChangeRequest.js.map +1 -1
- package/plugins/hooks/validateComment.js +12 -1
- package/plugins/hooks/validateComment.js.map +1 -1
- package/plugins/hooks/validateContentReview.js +6 -0
- package/plugins/hooks/validateContentReview.js.map +1 -1
- package/plugins/pageBuilder/PageApwSettingsGetterPlugin.js +15 -0
- package/plugins/pageBuilder/PageApwSettingsGetterPlugin.js.map +1 -1
- package/plugins/pageBuilder/apwContentPagePlugins.js +4 -0
- package/plugins/pageBuilder/apwContentPagePlugins.js.map +1 -1
- package/plugins/pageBuilder/extendPbPageSettingsSchema.js +6 -1
- package/plugins/pageBuilder/extendPbPageSettingsSchema.js.map +1 -1
- package/plugins/pageBuilder/index.js +11 -0
- package/plugins/pageBuilder/index.js.map +1 -1
- package/plugins/pageBuilder/linkContentReviewToPage.js +16 -0
- package/plugins/pageBuilder/linkContentReviewToPage.js.map +1 -1
- package/plugins/pageBuilder/linkWorkflowToPage.js +31 -1
- package/plugins/pageBuilder/linkWorkflowToPage.js.map +1 -1
- package/plugins/pageBuilder/notifications/changeRequestNotification.js +4 -0
- package/plugins/pageBuilder/notifications/changeRequestNotification.js.map +1 -1
- package/plugins/pageBuilder/notifications/commentNotification.js +4 -0
- package/plugins/pageBuilder/notifications/commentNotification.js.map +1 -1
- package/plugins/pageBuilder/notifications/contentReviewNotification.js +4 -0
- package/plugins/pageBuilder/notifications/contentReviewNotification.js.map +1 -1
- package/plugins/pageBuilder/notifications/contentUrl.js +7 -1
- package/plugins/pageBuilder/notifications/contentUrl.js.map +1 -1
- package/plugins/pageBuilder/triggerContentReview.js +11 -0
- package/plugins/pageBuilder/triggerContentReview.js.map +1 -1
- package/plugins/pageBuilder/updateContentReviewStatus.js +12 -0
- package/plugins/pageBuilder/updateContentReviewStatus.js.map +1 -1
- package/plugins/pageBuilder/utils.js +35 -1
- package/plugins/pageBuilder/utils.js.map +1 -1
- package/plugins/utils.js +43 -0
- package/plugins/utils.js.map +1 -1
- package/scheduler/createScheduleActionMethods.js +20 -1
- package/scheduler/createScheduleActionMethods.js.map +1 -1
- package/scheduler/handlers/executeAction/index.js +33 -9
- package/scheduler/handlers/executeAction/index.js.map +1 -1
- package/scheduler/handlers/executeAction/plugins/ApplicationGraphQL.js +5 -0
- package/scheduler/handlers/executeAction/plugins/ApplicationGraphQL.js.map +1 -1
- package/scheduler/handlers/executeAction/plugins/HeadlessCMSGraphQL.js +21 -0
- package/scheduler/handlers/executeAction/plugins/HeadlessCMSGraphQL.js.map +1 -1
- package/scheduler/handlers/executeAction/plugins/PageBuilderGraphQL.js +27 -4
- package/scheduler/handlers/executeAction/plugins/PageBuilderGraphQL.js.map +1 -1
- package/scheduler/handlers/executeAction/security.js +11 -0
- package/scheduler/handlers/executeAction/security.js.map +1 -1
- package/scheduler/handlers/scheduleAction/index.js +25 -5
- package/scheduler/handlers/scheduleAction/index.js.map +1 -1
- package/scheduler/handlers/scheduleAction/scheduleAction.utils.js +23 -2
- package/scheduler/handlers/scheduleAction/scheduleAction.utils.js.map +1 -1
- package/scheduler/handlers/utils.js +40 -3
- package/scheduler/handlers/utils.js.map +1 -1
- package/scheduler/index.js +3 -0
- package/scheduler/index.js.map +1 -1
- package/scheduler/types.js +6 -0
- package/scheduler/types.js.map +1 -1
- package/storageOperations/changeRequestStorageOperations.js +19 -0
- package/storageOperations/changeRequestStorageOperations.js.map +1 -1
- package/storageOperations/commentStorageOperations.js +21 -0
- package/storageOperations/commentStorageOperations.js.map +1 -1
- package/storageOperations/contentReviewStorageOperations.js +17 -0
- package/storageOperations/contentReviewStorageOperations.js.map +1 -1
- package/storageOperations/index.js +14 -0
- package/storageOperations/index.js.map +1 -1
- package/storageOperations/models/changeRequest.model.js +9 -0
- package/storageOperations/models/changeRequest.model.js.map +1 -1
- package/storageOperations/models/comment.model.js +8 -0
- package/storageOperations/models/comment.model.js.map +1 -1
- package/storageOperations/models/contentModelPluginFactory.js +5 -0
- package/storageOperations/models/contentModelPluginFactory.js.map +1 -1
- package/storageOperations/models/contentReview.model.js +26 -0
- package/storageOperations/models/contentReview.model.js.map +1 -1
- package/storageOperations/models/index.js +24 -2
- package/storageOperations/models/index.js.map +1 -1
- package/storageOperations/models/reviewer.model.js +8 -0
- package/storageOperations/models/reviewer.model.js.map +1 -1
- package/storageOperations/models/utils.js +4 -0
- package/storageOperations/models/utils.js.map +1 -1
- package/storageOperations/models/workflow.model.js +23 -0
- package/storageOperations/models/workflow.model.js.map +1 -1
- package/storageOperations/reviewerStorageOperations.js +17 -0
- package/storageOperations/reviewerStorageOperations.js.map +1 -1
- package/storageOperations/workflowStorageOperations.js +19 -0
- package/storageOperations/workflowStorageOperations.js.map +1 -1
- package/types.js +14 -0
- package/types.js.map +1 -1
- package/utils/contentApwSettingsPlugin.js +6 -0
- package/utils/contentApwSettingsPlugin.js.map +1 -1
- package/utils/errors.js +17 -0
- package/utils/errors.js.map +1 -1
- package/utils/fieldResolver.js +12 -2
- package/utils/fieldResolver.js.map +1 -1
- package/utils/resolve.js +3 -0
- package/utils/resolve.js.map +1 -1
@@ -1,14 +1,20 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
4
|
+
|
4
5
|
Object.defineProperty(exports, "__esModule", {
|
5
6
|
value: true
|
6
7
|
});
|
7
8
|
exports.createContentReviewStorageOperations = void 0;
|
9
|
+
|
8
10
|
var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/objectSpread2"));
|
11
|
+
|
9
12
|
var _index = require("./index");
|
13
|
+
|
10
14
|
var _error = _interopRequireDefault(require("@webiny/error"));
|
15
|
+
|
11
16
|
var _contentReview = require("./models/contentReview.model");
|
17
|
+
|
12
18
|
const createContentReviewStorageOperations = ({
|
13
19
|
cms,
|
14
20
|
security
|
@@ -17,11 +23,14 @@ const createContentReviewStorageOperations = ({
|
|
17
23
|
security.disableAuthorization();
|
18
24
|
const model = await cms.getModel(_contentReview.CONTENT_REVIEW_MODEL_ID);
|
19
25
|
security.enableAuthorization();
|
26
|
+
|
20
27
|
if (!model) {
|
21
28
|
throw new _error.default(`Could not find "${_contentReview.CONTENT_REVIEW_MODEL_ID}" model.`, "MODEL_NOT_FOUND_ERROR");
|
22
29
|
}
|
30
|
+
|
23
31
|
return model;
|
24
32
|
};
|
33
|
+
|
25
34
|
const getContentReview = async ({
|
26
35
|
id
|
27
36
|
}) => {
|
@@ -31,9 +40,11 @@ const createContentReviewStorageOperations = ({
|
|
31
40
|
security.enableAuthorization();
|
32
41
|
return (0, _index.getFieldValues)(entry, _index.baseFields);
|
33
42
|
};
|
43
|
+
|
34
44
|
return {
|
35
45
|
getContentReviewModel,
|
36
46
|
getContentReview,
|
47
|
+
|
37
48
|
async listContentReviews(params) {
|
38
49
|
const model = await getContentReviewModel();
|
39
50
|
security.disableAuthorization();
|
@@ -43,6 +54,7 @@ const createContentReviewStorageOperations = ({
|
|
43
54
|
security.enableAuthorization();
|
44
55
|
return [entries.map(entry => (0, _index.getFieldValues)(entry, _index.baseFields)), meta];
|
45
56
|
},
|
57
|
+
|
46
58
|
async createContentReview(params) {
|
47
59
|
const model = await getContentReviewModel();
|
48
60
|
security.disableAuthorization();
|
@@ -50,12 +62,14 @@ const createContentReviewStorageOperations = ({
|
|
50
62
|
security.enableAuthorization();
|
51
63
|
return (0, _index.getFieldValues)(entry, _index.baseFields);
|
52
64
|
},
|
65
|
+
|
53
66
|
async updateContentReview(params) {
|
54
67
|
const model = await getContentReviewModel();
|
55
68
|
/**
|
56
69
|
* We're fetching the existing entry here because we're not accepting "app" field as input,
|
57
70
|
* but, we still need to retain its value after the "update" operation.
|
58
71
|
*/
|
72
|
+
|
59
73
|
const existingEntry = await getContentReview({
|
60
74
|
id: params.id
|
61
75
|
});
|
@@ -64,6 +78,7 @@ const createContentReviewStorageOperations = ({
|
|
64
78
|
security.enableAuthorization();
|
65
79
|
return (0, _index.getFieldValues)(entry, _index.baseFields);
|
66
80
|
},
|
81
|
+
|
67
82
|
async deleteContentReview(params) {
|
68
83
|
const model = await getContentReviewModel();
|
69
84
|
security.disableAuthorization();
|
@@ -71,6 +86,8 @@ const createContentReviewStorageOperations = ({
|
|
71
86
|
security.enableAuthorization();
|
72
87
|
return true;
|
73
88
|
}
|
89
|
+
|
74
90
|
};
|
75
91
|
};
|
92
|
+
|
76
93
|
exports.createContentReviewStorageOperations = createContentReviewStorageOperations;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["createContentReviewStorageOperations","cms","security","getContentReviewModel","disableAuthorization","model","getModel","CONTENT_REVIEW_MODEL_ID","enableAuthorization","WebinyError","getContentReview","id","entry","getEntryById","getFieldValues","baseFields","listContentReviews","params","entries","meta","listLatestEntries","where","map","createContentReview","createEntry","data","updateContentReview","existingEntry","updateEntry","deleteContentReview","deleteEntry"],"sources":["contentReviewStorageOperations.ts"],"sourcesContent":["import { ApwContentReviewStorageOperations } from \"./types\";\nimport {\n baseFields,\n CreateApwStorageOperationsParams,\n getFieldValues\n} from \"~/storageOperations/index\";\nimport WebinyError from \"@webiny/error\";\nimport { CONTENT_REVIEW_MODEL_ID } from \"~/storageOperations/models/contentReview.model\";\n\nexport const createContentReviewStorageOperations = ({\n cms,\n security\n}: CreateApwStorageOperationsParams): ApwContentReviewStorageOperations => {\n const getContentReviewModel = async () => {\n security.disableAuthorization();\n const model = await cms.getModel(CONTENT_REVIEW_MODEL_ID);\n security.enableAuthorization();\n if (!model) {\n throw new WebinyError(\n `Could not find \"${CONTENT_REVIEW_MODEL_ID}\" model.`,\n \"MODEL_NOT_FOUND_ERROR\"\n );\n }\n return model;\n };\n const getContentReview: ApwContentReviewStorageOperations[\"getContentReview\"] = async ({\n id\n }) => {\n const model = await getContentReviewModel();\n security.disableAuthorization();\n const entry = await cms.getEntryById(model, id);\n security.enableAuthorization();\n return getFieldValues(entry, baseFields);\n };\n return {\n getContentReviewModel,\n getContentReview,\n async listContentReviews(params) {\n const model = await getContentReviewModel();\n security.disableAuthorization();\n const [entries, meta] = await cms.listLatestEntries(model, {\n ...params,\n where: {\n ...params.where\n }\n });\n security.enableAuthorization();\n return [entries.map(entry => getFieldValues(entry, baseFields)), meta];\n },\n async createContentReview(params) {\n const model = await getContentReviewModel();\n security.disableAuthorization();\n const entry = await cms.createEntry(model, params.data);\n security.enableAuthorization();\n return getFieldValues(entry, baseFields);\n },\n async updateContentReview(params) {\n const model = await getContentReviewModel();\n /**\n * We're fetching the existing entry here because we're not accepting \"app\" field as input,\n * but, we still need to retain its value after the \"update\" operation.\n */\n const existingEntry = await getContentReview({ id: params.id });\n\n security.disableAuthorization();\n const entry = await cms.updateEntry(model, params.id, {\n ...existingEntry,\n ...params.data\n });\n security.enableAuthorization();\n return getFieldValues(entry, baseFields);\n },\n async deleteContentReview(params) {\n const model = await getContentReviewModel();\n security.disableAuthorization();\n await cms.deleteEntry(model, params.id);\n security.enableAuthorization();\n return true;\n }\n };\n};\n"],"mappings":"
|
1
|
+
{"version":3,"names":["createContentReviewStorageOperations","cms","security","getContentReviewModel","disableAuthorization","model","getModel","CONTENT_REVIEW_MODEL_ID","enableAuthorization","WebinyError","getContentReview","id","entry","getEntryById","getFieldValues","baseFields","listContentReviews","params","entries","meta","listLatestEntries","where","map","createContentReview","createEntry","data","updateContentReview","existingEntry","updateEntry","deleteContentReview","deleteEntry"],"sources":["contentReviewStorageOperations.ts"],"sourcesContent":["import { ApwContentReviewStorageOperations } from \"./types\";\nimport {\n baseFields,\n CreateApwStorageOperationsParams,\n getFieldValues\n} from \"~/storageOperations/index\";\nimport WebinyError from \"@webiny/error\";\nimport { CONTENT_REVIEW_MODEL_ID } from \"~/storageOperations/models/contentReview.model\";\n\nexport const createContentReviewStorageOperations = ({\n cms,\n security\n}: CreateApwStorageOperationsParams): ApwContentReviewStorageOperations => {\n const getContentReviewModel = async () => {\n security.disableAuthorization();\n const model = await cms.getModel(CONTENT_REVIEW_MODEL_ID);\n security.enableAuthorization();\n if (!model) {\n throw new WebinyError(\n `Could not find \"${CONTENT_REVIEW_MODEL_ID}\" model.`,\n \"MODEL_NOT_FOUND_ERROR\"\n );\n }\n return model;\n };\n const getContentReview: ApwContentReviewStorageOperations[\"getContentReview\"] = async ({\n id\n }) => {\n const model = await getContentReviewModel();\n security.disableAuthorization();\n const entry = await cms.getEntryById(model, id);\n security.enableAuthorization();\n return getFieldValues(entry, baseFields);\n };\n return {\n getContentReviewModel,\n getContentReview,\n async listContentReviews(params) {\n const model = await getContentReviewModel();\n security.disableAuthorization();\n const [entries, meta] = await cms.listLatestEntries(model, {\n ...params,\n where: {\n ...params.where\n }\n });\n security.enableAuthorization();\n return [entries.map(entry => getFieldValues(entry, baseFields)), meta];\n },\n async createContentReview(params) {\n const model = await getContentReviewModel();\n security.disableAuthorization();\n const entry = await cms.createEntry(model, params.data);\n security.enableAuthorization();\n return getFieldValues(entry, baseFields);\n },\n async updateContentReview(params) {\n const model = await getContentReviewModel();\n /**\n * We're fetching the existing entry here because we're not accepting \"app\" field as input,\n * but, we still need to retain its value after the \"update\" operation.\n */\n const existingEntry = await getContentReview({ id: params.id });\n\n security.disableAuthorization();\n const entry = await cms.updateEntry(model, params.id, {\n ...existingEntry,\n ...params.data\n });\n security.enableAuthorization();\n return getFieldValues(entry, baseFields);\n },\n async deleteContentReview(params) {\n const model = await getContentReviewModel();\n security.disableAuthorization();\n await cms.deleteEntry(model, params.id);\n security.enableAuthorization();\n return true;\n }\n };\n};\n"],"mappings":";;;;;;;;;;;AACA;;AAKA;;AACA;;AAEO,MAAMA,oCAAoC,GAAG,CAAC;EACjDC,GADiD;EAEjDC;AAFiD,CAAD,KAGuB;EACvE,MAAMC,qBAAqB,GAAG,YA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X,GAAG,CAACuB,WAAJ,CAAgBnB,KAAhB,EAAuBY,MAAM,CAACQ,IAA9B,CAApB;MACAvB,QAAQ,CAACM,mBAAT;MACA,OAAO,IAAAM,qBAAA,EAAeF,KAAf,EAAsBG,iBAAtB,CAAP;IACH,CArBE;;IAsBH,MAAMW,mBAAN,CAA0BT,MAA1B,EAAkC;MAC9B,MAAMZ,KAAK,GAAG,MAAMF,qBAAqB,EAAzC;MACA;AACZ;AACA;AACA;;MACY,MAAMwB,aAAa,GAAG,MAAMjB,gBAAgB,CAAC;QAAEC,EAAE,EAAEM,MAAM,CAACN;MAAb,CAAD,CAA5C;MAEAT,QAAQ,CAACE,oBAAT;MACA,MAAMQ,KAAK,GAAG,MAAMX,GAAG,CAAC2B,WAAJ,CAAgBvB,KAAhB,EAAuBY,MAAM,CAACN,EAA9B,8DACbgB,aADa,GAEbV,MAAM,CAACQ,IAFM,EAApB;MAIAvB,QAAQ,CAACM,mBAAT;MACA,OAAO,IAAAM,qBAAA,EAAeF,KAAf,EAAsBG,iBAAtB,CAAP;IACH,CArCE;;IAsCH,MAAMc,mBAAN,CAA0BZ,MAA1B,EAAkC;MAC9B,MAAMZ,KAAK,GAAG,MAAMF,qBAAqB,EAAzC;MACAD,QAAQ,CAACE,oBAAT;MACA,MAAMH,GAAG,CAAC6B,WAAJ,CAAgBzB,KAAhB,EAAuBY,MAAM,CAACN,EAA9B,CAAN;MACAT,QAAQ,CAACM,mBAAT;MACA,OAAO,IAAP;IACH;;EA5CE,CAAP;AA8CH,CAvEM"}
|
@@ -1,19 +1,29 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
4
|
+
|
4
5
|
Object.defineProperty(exports, "__esModule", {
|
5
6
|
value: true
|
6
7
|
});
|
7
8
|
exports.createStorageOperations = exports.baseFields = void 0;
|
8
9
|
exports.getFieldValues = getFieldValues;
|
10
|
+
|
9
11
|
var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/objectSpread2"));
|
12
|
+
|
10
13
|
var _pick = _interopRequireDefault(require("lodash/pick"));
|
14
|
+
|
11
15
|
var _reviewerStorageOperations = require("./reviewerStorageOperations");
|
16
|
+
|
12
17
|
var _workflowStorageOperations = require("./workflowStorageOperations");
|
18
|
+
|
13
19
|
var _contentReviewStorageOperations = require("./contentReviewStorageOperations");
|
20
|
+
|
14
21
|
var _changeRequestStorageOperations = require("./changeRequestStorageOperations");
|
22
|
+
|
15
23
|
var _commentStorageOperations = require("./commentStorageOperations");
|
24
|
+
|
16
25
|
var _models = require("./models");
|
26
|
+
|
17
27
|
/**
|
18
28
|
* Using any because value can be a lot of types.
|
19
29
|
* TODO @ts-refactor figure out correct types.
|
@@ -21,14 +31,18 @@ var _models = require("./models");
|
|
21
31
|
function getFieldValues(entry, fields) {
|
22
32
|
return (0, _objectSpread2.default)((0, _objectSpread2.default)({}, (0, _pick.default)(entry, fields)), entry.values);
|
23
33
|
}
|
34
|
+
|
24
35
|
const baseFields = ["id", "entryId", "createdBy", "createdOn", "savedOn"];
|
25
36
|
exports.baseFields = baseFields;
|
37
|
+
|
26
38
|
const createStorageOperations = params => {
|
27
39
|
const context = params.getCmsContext();
|
28
40
|
/**
|
29
41
|
* Register Apw models.
|
30
42
|
*/
|
43
|
+
|
31
44
|
(0, _models.createApwModels)(context);
|
32
45
|
return (0, _objectSpread2.default)((0, _objectSpread2.default)((0, _objectSpread2.default)((0, _objectSpread2.default)((0, _objectSpread2.default)({}, (0, _reviewerStorageOperations.createReviewerStorageOperations)(params)), (0, _workflowStorageOperations.createWorkflowStorageOperations)(params)), (0, _contentReviewStorageOperations.createContentReviewStorageOperations)(params)), (0, _changeRequestStorageOperations.createChangeRequestStorageOperations)(params)), (0, _commentStorageOperations.createCommentStorageOperations)(params));
|
33
46
|
};
|
47
|
+
|
34
48
|
exports.createStorageOperations = createStorageOperations;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["getFieldValues","entry","fields","pick","values","baseFields","createStorageOperations","params","context","getCmsContext","createApwModels","createReviewerStorageOperations","createWorkflowStorageOperations","createContentReviewStorageOperations","createChangeRequestStorageOperations","createCommentStorageOperations"],"sources":["index.ts"],"sourcesContent":["import pick from \"lodash/pick\";\nimport { CmsContext, CmsEntry, HeadlessCms } from \"@webiny/api-headless-cms/types\";\nimport { ApwStorageOperations } from \"~/types\";\nimport { createReviewerStorageOperations } from \"./reviewerStorageOperations\";\nimport { createWorkflowStorageOperations } from \"./workflowStorageOperations\";\nimport { createContentReviewStorageOperations } from \"./contentReviewStorageOperations\";\nimport { createChangeRequestStorageOperations } from \"./changeRequestStorageOperations\";\nimport { createCommentStorageOperations } from \"~/storageOperations/commentStorageOperations\";\nimport { createApwModels } from \"./models\";\nimport { Security } from \"@webiny/api-security/types\";\n\nexport interface CreateApwStorageOperationsParams {\n cms: HeadlessCms;\n security: Security;\n getCmsContext: () => CmsContext;\n}\n\n/**\n * Using any because value can be a lot of types.\n * TODO @ts-refactor figure out correct types.\n */\nexport function getFieldValues(entry: CmsEntry, fields: string[]): any {\n return { ...pick(entry, fields), ...entry.values };\n}\n\nexport const baseFields = [\"id\", \"entryId\", \"createdBy\", \"createdOn\", \"savedOn\"];\n\nexport const createStorageOperations = (\n params: CreateApwStorageOperationsParams\n): ApwStorageOperations => {\n const context = params.getCmsContext();\n /**\n * Register Apw models.\n */\n createApwModels(context);\n\n return {\n ...createReviewerStorageOperations(params),\n ...createWorkflowStorageOperations(params),\n ...createContentReviewStorageOperations(params),\n ...createChangeRequestStorageOperations(params),\n ...createCommentStorageOperations(params)\n };\n};\n"],"mappings":"
|
1
|
+
{"version":3,"names":["getFieldValues","entry","fields","pick","values","baseFields","createStorageOperations","params","context","getCmsContext","createApwModels","createReviewerStorageOperations","createWorkflowStorageOperations","createContentReviewStorageOperations","createChangeRequestStorageOperations","createCommentStorageOperations"],"sources":["index.ts"],"sourcesContent":["import pick from \"lodash/pick\";\nimport { CmsContext, CmsEntry, HeadlessCms } from \"@webiny/api-headless-cms/types\";\nimport { ApwStorageOperations } from \"~/types\";\nimport { createReviewerStorageOperations } from \"./reviewerStorageOperations\";\nimport { createWorkflowStorageOperations } from \"./workflowStorageOperations\";\nimport { createContentReviewStorageOperations } from \"./contentReviewStorageOperations\";\nimport { createChangeRequestStorageOperations } from \"./changeRequestStorageOperations\";\nimport { createCommentStorageOperations } from \"~/storageOperations/commentStorageOperations\";\nimport { createApwModels } from \"./models\";\nimport { Security } from \"@webiny/api-security/types\";\n\nexport interface CreateApwStorageOperationsParams {\n cms: HeadlessCms;\n security: Security;\n getCmsContext: () => CmsContext;\n}\n\n/**\n * Using any because value can be a lot of types.\n * TODO @ts-refactor figure out correct types.\n */\nexport function getFieldValues(entry: CmsEntry, fields: string[]): any {\n return { ...pick(entry, fields), ...entry.values };\n}\n\nexport const baseFields = [\"id\", \"entryId\", \"createdBy\", \"createdOn\", \"savedOn\"];\n\nexport const createStorageOperations = (\n params: CreateApwStorageOperationsParams\n): ApwStorageOperations => {\n const context = params.getCmsContext();\n /**\n * Register Apw models.\n */\n createApwModels(context);\n\n return {\n ...createReviewerStorageOperations(params),\n ...createWorkflowStorageOperations(params),\n ...createContentReviewStorageOperations(params),\n ...createChangeRequestStorageOperations(params),\n ...createCommentStorageOperations(params)\n };\n};\n"],"mappings":";;;;;;;;;;;;AAAA;;AAGA;;AACA;;AACA;;AACA;;AACA;;AACA;;AASA;AACA;AACA;AACA;AACO,SAASA,cAAT,CAAwBC,KAAxB,EAAyCC,MAAzC,EAAgE;EACnE,mEAAY,IAAAC,aAAA,EAAKF,KAAL,EAAYC,MAAZ,CAAZ,GAAoCD,KAAK,CAACG,MAA1C;AACH;;AAEM,MAAMC,UAAU,GAAG,CAAC,IAAD,EAAO,SAAP,EAAkB,WAAlB,EAA+B,WAA/B,EAA4C,SAA5C,CAAnB;;;AAEA,MAAMC,uBAAuB,GAChCC,MADmC,IAEZ;EACvB,MAAMC,OAAO,GAAGD,MAAM,CAACE,aAAP,EAAhB;EACA;AACJ;AACA;;EACI,IAAAC,uBAAA,EAAgBF,OAAhB;EAEA,uJACO,IAAAG,0DAAA,EAAgCJ,MAAhC,CADP,GAEO,IAAAK,0DAAA,EAAgCL,MAAhC,CAFP,GAGO,IAAAM,oEAAA,EAAqCN,MAArC,CAHP,GAIO,IAAAO,oEAAA,EAAqCP,MAArC,CAJP,GAKO,IAAAQ,wDAAA,EAA+BR,MAA/B,CALP;AAOH,CAhBM"}
|
@@ -4,27 +4,33 @@ Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
5
5
|
});
|
6
6
|
exports.createChangeRequestModelDefinition = exports.CHANGE_REQUEST_MODEL_ID = void 0;
|
7
|
+
|
7
8
|
var _utils = require("./utils");
|
9
|
+
|
8
10
|
const bodyField = () => (0, _utils.createModelField)({
|
9
11
|
label: "Body",
|
10
12
|
type: "rich-text",
|
11
13
|
parent: "changeRequest"
|
12
14
|
});
|
15
|
+
|
13
16
|
const titleField = () => (0, _utils.createModelField)({
|
14
17
|
label: "Title",
|
15
18
|
type: "text",
|
16
19
|
parent: "changeRequest"
|
17
20
|
});
|
21
|
+
|
18
22
|
const resolvedField = () => (0, _utils.createModelField)({
|
19
23
|
label: "Resolved",
|
20
24
|
type: "boolean",
|
21
25
|
parent: "changeRequest"
|
22
26
|
});
|
27
|
+
|
23
28
|
const mediaField = () => (0, _utils.createModelField)({
|
24
29
|
label: "Media",
|
25
30
|
type: "file",
|
26
31
|
parent: "changeRequest"
|
27
32
|
});
|
33
|
+
|
28
34
|
const stepField = () => (0, _utils.createModelField)({
|
29
35
|
label: "Step",
|
30
36
|
type: "text",
|
@@ -34,8 +40,10 @@ const stepField = () => (0, _utils.createModelField)({
|
|
34
40
|
name: "required"
|
35
41
|
}]
|
36
42
|
});
|
43
|
+
|
37
44
|
const CHANGE_REQUEST_MODEL_ID = "apwChangeRequestModelDefinition";
|
38
45
|
exports.CHANGE_REQUEST_MODEL_ID = CHANGE_REQUEST_MODEL_ID;
|
46
|
+
|
39
47
|
const createChangeRequestModelDefinition = () => {
|
40
48
|
return {
|
41
49
|
name: "APW - Change Request",
|
@@ -47,4 +55,5 @@ const createChangeRequestModelDefinition = () => {
|
|
47
55
|
isPrivate: true
|
48
56
|
};
|
49
57
|
};
|
58
|
+
|
50
59
|
exports.createChangeRequestModelDefinition = createChangeRequestModelDefinition;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["bodyField","createModelField","label","type","parent","titleField","resolvedField","mediaField","stepField","validation","message","name","CHANGE_REQUEST_MODEL_ID","createChangeRequestModelDefinition","modelId","titleFieldId","layout","fields","description","isPrivate"],"sources":["changeRequest.model.ts"],"sourcesContent":["import { createModelField } from \"./utils\";\nimport { WorkflowModelDefinition } from \"~/types\";\n\nconst bodyField = () =>\n createModelField({\n label: \"Body\",\n type: \"rich-text\",\n parent: \"changeRequest\"\n });\n\nconst titleField = () =>\n createModelField({\n label: \"Title\",\n type: \"text\",\n parent: \"changeRequest\"\n });\n\nconst resolvedField = () =>\n createModelField({\n label: \"Resolved\",\n type: \"boolean\",\n parent: \"changeRequest\"\n });\n\nconst mediaField = () =>\n createModelField({\n label: \"Media\",\n type: \"file\",\n parent: \"changeRequest\"\n });\n\nconst stepField = () =>\n createModelField({\n label: \"Step\",\n type: \"text\",\n parent: \"changeRequest\",\n validation: [\n {\n message: \"`step` field value is required in changeRequest.\",\n name: \"required\"\n }\n ]\n });\n\nexport const CHANGE_REQUEST_MODEL_ID = \"apwChangeRequestModelDefinition\";\n\nexport const createChangeRequestModelDefinition = (): WorkflowModelDefinition => {\n return {\n name: \"APW - Change Request\",\n modelId: CHANGE_REQUEST_MODEL_ID,\n titleFieldId: \"title\",\n layout: [\n [\"changeRequest_body\"],\n [\"changeRequest_title\"],\n [\"changeRequest_resolved\"],\n [\"changeRequest_media\"],\n [\"changeRequest_step\"]\n ],\n fields: [bodyField(), titleField(), resolvedField(), mediaField(), stepField()],\n description: \"\",\n isPrivate: true\n };\n};\n"],"mappings":"
|
1
|
+
{"version":3,"names":["bodyField","createModelField","label","type","parent","titleField","resolvedField","mediaField","stepField","validation","message","name","CHANGE_REQUEST_MODEL_ID","createChangeRequestModelDefinition","modelId","titleFieldId","layout","fields","description","isPrivate"],"sources":["changeRequest.model.ts"],"sourcesContent":["import { createModelField } from \"./utils\";\nimport { WorkflowModelDefinition } from \"~/types\";\n\nconst bodyField = () =>\n createModelField({\n label: \"Body\",\n type: \"rich-text\",\n parent: \"changeRequest\"\n });\n\nconst titleField = () =>\n createModelField({\n label: \"Title\",\n type: \"text\",\n parent: \"changeRequest\"\n });\n\nconst resolvedField = () =>\n createModelField({\n label: \"Resolved\",\n type: \"boolean\",\n parent: \"changeRequest\"\n });\n\nconst mediaField = () =>\n createModelField({\n label: \"Media\",\n type: \"file\",\n parent: \"changeRequest\"\n });\n\nconst stepField = () =>\n createModelField({\n label: \"Step\",\n type: \"text\",\n parent: \"changeRequest\",\n validation: [\n {\n message: \"`step` field value is required in changeRequest.\",\n name: \"required\"\n }\n ]\n });\n\nexport const CHANGE_REQUEST_MODEL_ID = \"apwChangeRequestModelDefinition\";\n\nexport const createChangeRequestModelDefinition = (): WorkflowModelDefinition => {\n return {\n name: \"APW - Change Request\",\n modelId: CHANGE_REQUEST_MODEL_ID,\n titleFieldId: \"title\",\n layout: [\n [\"changeRequest_body\"],\n [\"changeRequest_title\"],\n [\"changeRequest_resolved\"],\n [\"changeRequest_media\"],\n [\"changeRequest_step\"]\n ],\n fields: [bodyField(), titleField(), resolvedField(), mediaField(), stepField()],\n description: \"\",\n isPrivate: true\n };\n};\n"],"mappings":";;;;;;;AAAA;;AAGA,MAAMA,SAAS,GAAG,MACd,IAAAC,uBAAA,EAAiB;EACbC,KAAK,EAAE,MADM;EAEbC,IAAI,EAAE,WAFO;EAGbC,MAAM,EAAE;AAHK,CAAjB,CADJ;;AAOA,MAAMC,UAAU,GAAG,MACf,IAAAJ,uBAAA,EAAiB;EACbC,KAAK,EAAE,OADM;EAEbC,IAAI,EAAE,MAFO;EAGbC,MAAM,EAAE;AAHK,CAAjB,CADJ;;AAOA,MAAME,aAAa,GAAG,MAClB,IAAAL,uBAAA,EAAiB;EACbC,KAAK,EAAE,UADM;EAEbC,IAAI,EAAE,SAFO;EAGbC,MAAM,EAAE;AAHK,CAAjB,CADJ;;AAOA,MAAMG,UAAU,GAAG,MACf,IAAAN,uBAAA,EAAiB;EACbC,KAAK,EAAE,OADM;EAEbC,IAAI,EAAE,MAFO;EAGbC,MAAM,EAAE;AAHK,CAAjB,CADJ;;AAOA,MAAMI,SAAS,GAAG,MACd,IAAAP,uBAAA,EAAiB;EACbC,KAAK,EAAE,MADM;EAEbC,IAAI,EAAE,MAFO;EAGbC,MAAM,EAAE,eAHK;EAIbK,UAAU,EAAE,CACR;IACIC,OAAO,EAAE,kDADb;IAEIC,IAAI,EAAE;EAFV,CADQ;AAJC,CAAjB,CADJ;;AAaO,MAAMC,uBAAuB,GAAG,iCAAhC;;;AAEA,MAAMC,kCAAkC,GAAG,MAA+B;EAC7E,OAAO;IACHF,IAAI,EAAE,sBADH;IAEHG,OAAO,EAAEF,uBAFN;IAGHG,YAAY,EAAE,OAHX;IAIHC,MAAM,EAAE,CACJ,CAAC,oBAAD,CADI,EAEJ,CAAC,qBAAD,CAFI,EAGJ,CAAC,wBAAD,CAHI,EAIJ,CAAC,qBAAD,CAJI,EAKJ,CAAC,oBAAD,CALI,CAJL;IAWHC,MAAM,EAAE,CAACjB,SAAS,EAAV,EAAcK,UAAU,EAAxB,EAA4BC,aAAa,EAAzC,EAA6CC,UAAU,EAAvD,EAA2DC,SAAS,EAApE,CAXL;IAYHU,WAAW,EAAE,EAZV;IAaHC,SAAS,EAAE;EAbR,CAAP;AAeH,CAhBM"}
|
@@ -4,12 +4,15 @@ Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
5
5
|
});
|
6
6
|
exports.createCommentModelDefinition = exports.COMMENT_MODEL_ID = void 0;
|
7
|
+
|
7
8
|
var _utils = require("./utils");
|
9
|
+
|
8
10
|
const commentBody = () => (0, _utils.createModelField)({
|
9
11
|
label: "Body",
|
10
12
|
type: "rich-text",
|
11
13
|
parent: "comment"
|
12
14
|
});
|
15
|
+
|
13
16
|
const changeRequestRef = modelId => (0, _utils.createModelField)({
|
14
17
|
label: "Change Request",
|
15
18
|
type: "ref",
|
@@ -20,6 +23,7 @@ const changeRequestRef = modelId => (0, _utils.createModelField)({
|
|
20
23
|
}]
|
21
24
|
}
|
22
25
|
});
|
26
|
+
|
23
27
|
const stepField = () => (0, _utils.createModelField)({
|
24
28
|
label: "Step",
|
25
29
|
type: "text",
|
@@ -29,13 +33,16 @@ const stepField = () => (0, _utils.createModelField)({
|
|
29
33
|
name: "required"
|
30
34
|
}]
|
31
35
|
});
|
36
|
+
|
32
37
|
const mediaField = () => (0, _utils.createModelField)({
|
33
38
|
label: "Media",
|
34
39
|
type: "file",
|
35
40
|
parent: "comment"
|
36
41
|
});
|
42
|
+
|
37
43
|
const COMMENT_MODEL_ID = "apwCommentModelDefinition";
|
38
44
|
exports.COMMENT_MODEL_ID = COMMENT_MODEL_ID;
|
45
|
+
|
39
46
|
const createCommentModelDefinition = ({
|
40
47
|
modelId
|
41
48
|
}) => {
|
@@ -49,4 +56,5 @@ const createCommentModelDefinition = ({
|
|
49
56
|
isPrivate: true
|
50
57
|
};
|
51
58
|
};
|
59
|
+
|
52
60
|
exports.createCommentModelDefinition = createCommentModelDefinition;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["commentBody","createModelField","label","type","parent","changeRequestRef","modelId","settings","models","stepField","validation","message","name","mediaField","COMMENT_MODEL_ID","createCommentModelDefinition","titleFieldId","layout","fields","description","isPrivate"],"sources":["comment.model.ts"],"sourcesContent":["import { createModelField } from \"./utils\";\nimport { WorkflowModelDefinition } from \"~/types\";\n\nconst commentBody = () =>\n createModelField({\n label: \"Body\",\n type: \"rich-text\",\n parent: \"comment\"\n });\n\nconst changeRequestRef = (modelId: string) =>\n createModelField({\n label: \"Change Request\",\n type: \"ref\",\n parent: \"comment\",\n settings: {\n models: [\n {\n modelId\n }\n ]\n }\n });\n\nconst stepField = () =>\n createModelField({\n label: \"Step\",\n type: \"text\",\n parent: \"comment\",\n validation: [\n {\n message: \"`step` field value is required in comment.\",\n name: \"required\"\n }\n ]\n });\n\nconst mediaField = () =>\n createModelField({\n label: \"Media\",\n type: \"file\",\n parent: \"comment\"\n });\n\ninterface CreateCommentModelDefinitionParams {\n modelId: string;\n}\n\nexport const COMMENT_MODEL_ID = \"apwCommentModelDefinition\";\n\nexport const createCommentModelDefinition = ({\n modelId\n}: CreateCommentModelDefinitionParams): WorkflowModelDefinition => {\n return {\n name: \"APW - Comment\",\n modelId: COMMENT_MODEL_ID,\n titleFieldId: \"step\",\n layout: [[\"comment_body\"], [\"comment_changeRequest\"], [\"comment_step\"], [\"comment_media\"]],\n fields: [commentBody(), changeRequestRef(modelId), stepField(), mediaField()],\n description: \"\",\n isPrivate: true\n };\n};\n"],"mappings":"
|
1
|
+
{"version":3,"names":["commentBody","createModelField","label","type","parent","changeRequestRef","modelId","settings","models","stepField","validation","message","name","mediaField","COMMENT_MODEL_ID","createCommentModelDefinition","titleFieldId","layout","fields","description","isPrivate"],"sources":["comment.model.ts"],"sourcesContent":["import { createModelField } from \"./utils\";\nimport { WorkflowModelDefinition } from \"~/types\";\n\nconst commentBody = () =>\n createModelField({\n label: \"Body\",\n type: \"rich-text\",\n parent: \"comment\"\n });\n\nconst changeRequestRef = (modelId: string) =>\n createModelField({\n label: \"Change Request\",\n type: \"ref\",\n parent: \"comment\",\n settings: {\n models: [\n {\n modelId\n }\n ]\n }\n });\n\nconst stepField = () =>\n createModelField({\n label: \"Step\",\n type: \"text\",\n parent: \"comment\",\n validation: [\n {\n message: \"`step` field value is required in comment.\",\n name: \"required\"\n }\n ]\n });\n\nconst mediaField = () =>\n createModelField({\n label: \"Media\",\n type: \"file\",\n parent: \"comment\"\n });\n\ninterface CreateCommentModelDefinitionParams {\n modelId: string;\n}\n\nexport const COMMENT_MODEL_ID = \"apwCommentModelDefinition\";\n\nexport const createCommentModelDefinition = ({\n modelId\n}: CreateCommentModelDefinitionParams): WorkflowModelDefinition => {\n return {\n name: \"APW - Comment\",\n modelId: COMMENT_MODEL_ID,\n titleFieldId: \"step\",\n layout: [[\"comment_body\"], [\"comment_changeRequest\"], [\"comment_step\"], [\"comment_media\"]],\n fields: [commentBody(), changeRequestRef(modelId), stepField(), mediaField()],\n description: \"\",\n isPrivate: true\n };\n};\n"],"mappings":";;;;;;;AAAA;;AAGA,MAAMA,WAAW,GAAG,MAChB,IAAAC,uBAAA,EAAiB;EACbC,KAAK,EAAE,MADM;EAEbC,IAAI,EAAE,WAFO;EAGbC,MAAM,EAAE;AAHK,CAAjB,CADJ;;AAOA,MAAMC,gBAAgB,GAAIC,OAAD,IACrB,IAAAL,uBAAA,EAAiB;EACbC,KAAK,EAAE,gBADM;EAEbC,IAAI,EAAE,KAFO;EAGbC,MAAM,EAAE,SAHK;EAIbG,QAAQ,EAAE;IACNC,MAAM,EAAE,CACJ;MACIF;IADJ,CADI;EADF;AAJG,CAAjB,CADJ;;AAcA,MAAMG,SAAS,GAAG,MACd,IAAAR,uBAAA,EAAiB;EACbC,KAAK,EAAE,MADM;EAEbC,IAAI,EAAE,MAFO;EAGbC,MAAM,EAAE,SAHK;EAIbM,UAAU,EAAE,CACR;IACIC,OAAO,EAAE,4CADb;IAEIC,IAAI,EAAE;EAFV,CADQ;AAJC,CAAjB,CADJ;;AAaA,MAAMC,UAAU,GAAG,MACf,IAAAZ,uBAAA,EAAiB;EACbC,KAAK,EAAE,OADM;EAEbC,IAAI,EAAE,MAFO;EAGbC,MAAM,EAAE;AAHK,CAAjB,CADJ;;AAWO,MAAMU,gBAAgB,GAAG,2BAAzB;;;AAEA,MAAMC,4BAA4B,GAAG,CAAC;EACzCT;AADyC,CAAD,KAEuB;EAC/D,OAAO;IACHM,IAAI,EAAE,eADH;IAEHN,OAAO,EAAEQ,gBAFN;IAGHE,YAAY,EAAE,MAHX;IAIHC,MAAM,EAAE,CAAC,CAAC,cAAD,CAAD,EAAmB,CAAC,uBAAD,CAAnB,EAA8C,CAAC,cAAD,CAA9C,EAAgE,CAAC,eAAD,CAAhE,CAJL;IAKHC,MAAM,EAAE,CAAClB,WAAW,EAAZ,EAAgBK,gBAAgB,CAACC,OAAD,CAAhC,EAA2CG,SAAS,EAApD,EAAwDI,UAAU,EAAlE,CALL;IAMHM,WAAW,EAAE,EANV;IAOHC,SAAS,EAAE;EAPR,CAAP;AASH,CAZM"}
|
@@ -1,12 +1,16 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
4
|
+
|
4
5
|
Object.defineProperty(exports, "__esModule", {
|
5
6
|
value: true
|
6
7
|
});
|
7
8
|
exports.contentModelPluginFactory = void 0;
|
9
|
+
|
8
10
|
var _objectSpread2 = _interopRequireDefault(require("@babel/runtime/helpers/objectSpread2"));
|
11
|
+
|
9
12
|
var _apiHeadlessCms = require("@webiny/api-headless-cms");
|
13
|
+
|
10
14
|
const contentModelPluginFactory = params => {
|
11
15
|
const {
|
12
16
|
group,
|
@@ -20,4 +24,5 @@ const contentModelPluginFactory = params => {
|
|
20
24
|
tenant
|
21
25
|
}, modelDefinition));
|
22
26
|
};
|
27
|
+
|
23
28
|
exports.contentModelPluginFactory = contentModelPluginFactory;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["contentModelPluginFactory","params","group","locale","tenant","modelDefinition","createCmsModel"],"sources":["contentModelPluginFactory.ts"],"sourcesContent":["import { CmsModelPlugin, createCmsModel } from \"@webiny/api-headless-cms\";\nimport { CmsModel, CmsGroup } from \"@webiny/api-headless-cms/types\";\n\ninterface Params {\n group: Pick<CmsGroup, \"id\" | \"name\">;\n /**\n * Locale and tenant do not need to be defined.\n * In that case model is not bound to any locale or tenant.\n * You can bind it to locale, tenant, both or none.\n */\n locale?: string;\n tenant?: string;\n modelDefinition: Omit<CmsModel, \"locale\" | \"tenant\" | \"webinyVersion\" | \"group\">;\n}\n\nexport const contentModelPluginFactory = (params: Params): CmsModelPlugin => {\n const { group, locale, tenant, modelDefinition } = params;\n\n return createCmsModel({\n group,\n locale,\n tenant,\n ...modelDefinition\n });\n};\n"],"mappings":"
|
1
|
+
{"version":3,"names":["contentModelPluginFactory","params","group","locale","tenant","modelDefinition","createCmsModel"],"sources":["contentModelPluginFactory.ts"],"sourcesContent":["import { CmsModelPlugin, createCmsModel } from \"@webiny/api-headless-cms\";\nimport { CmsModel, CmsGroup } from \"@webiny/api-headless-cms/types\";\n\ninterface Params {\n group: Pick<CmsGroup, \"id\" | \"name\">;\n /**\n * Locale and tenant do not need to be defined.\n * In that case model is not bound to any locale or tenant.\n * You can bind it to locale, tenant, both or none.\n */\n locale?: string;\n tenant?: string;\n modelDefinition: Omit<CmsModel, \"locale\" | \"tenant\" | \"webinyVersion\" | \"group\">;\n}\n\nexport const contentModelPluginFactory = (params: Params): CmsModelPlugin => {\n const { group, locale, tenant, modelDefinition } = params;\n\n return createCmsModel({\n group,\n locale,\n tenant,\n ...modelDefinition\n });\n};\n"],"mappings":";;;;;;;;;;;AAAA;;AAeO,MAAMA,yBAAyB,GAAIC,MAAD,IAAoC;EACzE,MAAM;IAAEC,KAAF;IAASC,MAAT;IAAiBC,MAAjB;IAAyBC;EAAzB,IAA6CJ,MAAnD;EAEA,OAAO,IAAAK,8BAAA;IACHJ,KADG;IAEHC,MAFG;IAGHC;EAHG,GAIAC,eAJA,EAAP;AAMH,CATM"}
|
@@ -4,8 +4,11 @@ Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
5
5
|
});
|
6
6
|
exports.createContentReviewModelDefinition = exports.CONTENT_REVIEW_MODEL_ID = void 0;
|
7
|
+
|
7
8
|
var _utils = require("./utils");
|
9
|
+
|
8
10
|
var _workflow = require("./workflow.model");
|
11
|
+
|
9
12
|
const contentField = fields => (0, _utils.createModelField)({
|
10
13
|
label: "Content",
|
11
14
|
parent: "contentReview",
|
@@ -19,6 +22,7 @@ const contentField = fields => (0, _utils.createModelField)({
|
|
19
22
|
name: "required"
|
20
23
|
}]
|
21
24
|
});
|
25
|
+
|
22
26
|
const contentStatus = () => (0, _utils.createModelField)({
|
23
27
|
label: "Status",
|
24
28
|
fieldId: "reviewStatus",
|
@@ -42,6 +46,7 @@ const contentStatus = () => (0, _utils.createModelField)({
|
|
42
46
|
name: "required"
|
43
47
|
}]
|
44
48
|
});
|
49
|
+
|
45
50
|
const titleField = () => (0, _utils.createModelField)({
|
46
51
|
label: "Title",
|
47
52
|
type: "text",
|
@@ -51,6 +56,7 @@ const titleField = () => (0, _utils.createModelField)({
|
|
51
56
|
name: "required"
|
52
57
|
}]
|
53
58
|
});
|
59
|
+
|
54
60
|
const contentIdField = () => (0, _utils.createModelField)({
|
55
61
|
label: "Id",
|
56
62
|
type: "text",
|
@@ -60,6 +66,7 @@ const contentIdField = () => (0, _utils.createModelField)({
|
|
60
66
|
name: "required"
|
61
67
|
}]
|
62
68
|
});
|
69
|
+
|
63
70
|
const workflowIdField = () => (0, _utils.createModelField)({
|
64
71
|
label: "Workflow Id",
|
65
72
|
type: "text",
|
@@ -69,6 +76,7 @@ const workflowIdField = () => (0, _utils.createModelField)({
|
|
69
76
|
name: "required"
|
70
77
|
}]
|
71
78
|
});
|
79
|
+
|
72
80
|
const contentTypeField = () => (0, _utils.createModelField)({
|
73
81
|
label: "Type",
|
74
82
|
type: "text",
|
@@ -88,6 +96,7 @@ const contentTypeField = () => (0, _utils.createModelField)({
|
|
88
96
|
name: "required"
|
89
97
|
}]
|
90
98
|
});
|
99
|
+
|
91
100
|
const contentSettingsField = fields => (0, _utils.createModelField)({
|
92
101
|
label: "Settings",
|
93
102
|
parent: "contentReview Content",
|
@@ -97,31 +106,37 @@ const contentSettingsField = fields => (0, _utils.createModelField)({
|
|
97
106
|
fields
|
98
107
|
}
|
99
108
|
});
|
109
|
+
|
100
110
|
const contentSettingsModelIdField = () => (0, _utils.createModelField)({
|
101
111
|
label: "Model Id",
|
102
112
|
parent: "contentReview Settings",
|
103
113
|
type: "text"
|
104
114
|
});
|
115
|
+
|
105
116
|
const scheduledActionIdField = () => (0, _utils.createModelField)({
|
106
117
|
label: "Scheduled action Id",
|
107
118
|
type: "text",
|
108
119
|
parent: "contentReview Content"
|
109
120
|
});
|
121
|
+
|
110
122
|
const contentScheduledOnField = () => (0, _utils.createModelField)({
|
111
123
|
label: "Scheduled on",
|
112
124
|
type: "datetime",
|
113
125
|
parent: "contentReview Content"
|
114
126
|
});
|
127
|
+
|
115
128
|
const contentScheduledByField = () => (0, _utils.createModelField)({
|
116
129
|
label: "Scheduled by",
|
117
130
|
type: "text",
|
118
131
|
parent: "contentReview Content"
|
119
132
|
});
|
133
|
+
|
120
134
|
const contentPublishedByField = () => (0, _utils.createModelField)({
|
121
135
|
label: "Published by",
|
122
136
|
type: "text",
|
123
137
|
parent: "contentReview Content"
|
124
138
|
});
|
139
|
+
|
125
140
|
const stepStatusField = () => ({
|
126
141
|
multipleValues: false,
|
127
142
|
listValidation: [],
|
@@ -151,6 +166,7 @@ const stepStatusField = () => ({
|
|
151
166
|
storageId: "status",
|
152
167
|
fieldId: "status"
|
153
168
|
});
|
169
|
+
|
154
170
|
const stepPendingChangeRequests = () => (0, _utils.createModelField)({
|
155
171
|
label: "Pending change requests",
|
156
172
|
type: "number",
|
@@ -160,6 +176,7 @@ const stepPendingChangeRequests = () => (0, _utils.createModelField)({
|
|
160
176
|
name: "required"
|
161
177
|
}]
|
162
178
|
});
|
179
|
+
|
163
180
|
const stepTotalComments = () => (0, _utils.createModelField)({
|
164
181
|
label: "Total comments",
|
165
182
|
type: "number",
|
@@ -169,16 +186,19 @@ const stepTotalComments = () => (0, _utils.createModelField)({
|
|
169
186
|
name: "required"
|
170
187
|
}]
|
171
188
|
});
|
189
|
+
|
172
190
|
const latestCommentId = () => (0, _utils.createModelField)({
|
173
191
|
label: "Latest comment Id",
|
174
192
|
type: "text",
|
175
193
|
parent: "contentReview"
|
176
194
|
});
|
195
|
+
|
177
196
|
const stepSignOffProvidedOn = () => (0, _utils.createModelField)({
|
178
197
|
label: "Sign off provided on",
|
179
198
|
type: "datetime",
|
180
199
|
parent: "contentReview Step"
|
181
200
|
});
|
201
|
+
|
182
202
|
const stepSignOffProvidedBy = fields => (0, _utils.createModelField)({
|
183
203
|
label: "Sign off provided By",
|
184
204
|
type: "object",
|
@@ -188,16 +208,19 @@ const stepSignOffProvidedBy = fields => (0, _utils.createModelField)({
|
|
188
208
|
fields
|
189
209
|
}
|
190
210
|
});
|
211
|
+
|
191
212
|
const stepSignOffProvidedById = () => (0, _utils.createModelField)({
|
192
213
|
label: "Id",
|
193
214
|
type: "text",
|
194
215
|
parent: "contentReview Step"
|
195
216
|
});
|
217
|
+
|
196
218
|
const stepSignOffProvidedByDisplayName = () => (0, _utils.createModelField)({
|
197
219
|
label: "DisplayName",
|
198
220
|
type: "text",
|
199
221
|
parent: "contentReview Step"
|
200
222
|
});
|
223
|
+
|
201
224
|
const stepsField = fields => ({
|
202
225
|
id: "contentReview_steps",
|
203
226
|
label: "Steps",
|
@@ -216,8 +239,10 @@ const stepsField = fields => ({
|
|
216
239
|
enabled: false
|
217
240
|
}
|
218
241
|
});
|
242
|
+
|
219
243
|
const CONTENT_REVIEW_MODEL_ID = "apwContentReviewModelDefinition";
|
220
244
|
exports.CONTENT_REVIEW_MODEL_ID = CONTENT_REVIEW_MODEL_ID;
|
245
|
+
|
221
246
|
const createContentReviewModelDefinition = ({
|
222
247
|
reviewerModelId
|
223
248
|
}) => ({
|
@@ -229,4 +254,5 @@ const createContentReviewModelDefinition = ({
|
|
229
254
|
description: "",
|
230
255
|
isPrivate: true
|
231
256
|
});
|
257
|
+
|
232
258
|
exports.createContentReviewModelDefinition = createContentReviewModelDefinition;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["contentField","fields","createModelField","label","parent","type","multipleValues","settings","validation","message","name","contentStatus","fieldId","predefinedValues","enabled","values","value","titleField","contentIdField","workflowIdField","contentTypeField","contentSettingsField","contentSettingsModelIdField","scheduledActionIdField","contentScheduledOnField","contentScheduledByField","contentPublishedByField","stepStatusField","listValidation","renderer","id","storageId","stepPendingChangeRequests","stepTotalComments","latestCommentId","stepSignOffProvidedOn","stepSignOffProvidedBy","stepSignOffProvidedById","stepSignOffProvidedByDisplayName","stepsField","layout","map","field","CONTENT_REVIEW_MODEL_ID","createContentReviewModelDefinition","reviewerModelId","modelId","titleFieldId","stepTitleField","stepTypeField","stepIdField","stepReviewersField","description","isPrivate"],"sources":["contentReview.model.ts"],"sourcesContent":["import { createModelField } from \"./utils\";\nimport { stepTitleField, stepTypeField, stepIdField, stepReviewersField } from \"./workflow.model\";\nimport { CmsModelField } from \"@webiny/api-headless-cms/types\";\nimport { WorkflowModelDefinition } from \"~/types\";\n\nconst contentField = (fields: CmsModelField[]) =>\n createModelField({\n label: \"Content\",\n parent: \"contentReview\",\n type: \"object\",\n multipleValues: false,\n settings: { fields },\n validation: [\n {\n message: \"`content` field value is required in contentReview.\",\n name: \"required\"\n }\n ]\n });\n\nconst contentStatus = () =>\n createModelField({\n label: \"Status\",\n fieldId: \"reviewStatus\",\n parent: \"contentReview\",\n type: \"text\",\n predefinedValues: {\n enabled: true,\n values: [\n {\n label: \"Under review\",\n value: \"underReview\"\n },\n {\n label: \"Ready to be published\",\n value: \"readyToBePublished\"\n },\n {\n label: \"Published\",\n value: \"published\"\n }\n ]\n },\n validation: [\n {\n message: \"`reviewStatus` field value is required in contentReview.\",\n name: \"required\"\n }\n ]\n });\n\nconst titleField = () =>\n createModelField({\n label: \"Title\",\n type: \"text\",\n parent: \"contentReview\",\n validation: [\n {\n message: \"`title` field value is required in contentReview.\",\n name: \"required\"\n }\n ]\n });\n\nconst contentIdField = () =>\n createModelField({\n label: \"Id\",\n type: \"text\",\n parent: \"contentReview Content\",\n validation: [\n {\n message: \"`id` field value is required in contentReview Content.\",\n name: \"required\"\n }\n ]\n });\n\nconst workflowIdField = () =>\n createModelField({\n label: \"Workflow Id\",\n type: \"text\",\n parent: \"contentReview\",\n validation: [\n {\n message: \"`workflowId` field value is required in contentReview Content.\",\n name: \"required\"\n }\n ]\n });\n\nconst contentTypeField = () =>\n createModelField({\n label: \"Type\",\n type: \"text\",\n parent: \"contentReview Type\",\n predefinedValues: {\n enabled: true,\n values: [\n {\n label: \"Page\",\n value: \"page\"\n },\n { value: \"cms-entry\", label: \"CMS Entry\" }\n ]\n },\n validation: [\n {\n message: \"`type` field value is required in contentReview Type.\",\n name: \"required\"\n }\n ]\n });\n\nconst contentSettingsField = (fields: CmsModelField[]) =>\n createModelField({\n label: \"Settings\",\n parent: \"contentReview Content\",\n type: \"object\",\n multipleValues: false,\n settings: { fields }\n });\n\nconst contentSettingsModelIdField = () =>\n createModelField({\n label: \"Model Id\",\n parent: \"contentReview Settings\",\n type: \"text\"\n });\n\nconst scheduledActionIdField = () =>\n createModelField({\n label: \"Scheduled action Id\",\n type: \"text\",\n parent: \"contentReview Content\"\n });\n\nconst contentScheduledOnField = () =>\n createModelField({\n label: \"Scheduled on\",\n type: \"datetime\",\n parent: \"contentReview Content\"\n });\n\nconst contentScheduledByField = () =>\n createModelField({\n label: \"Scheduled by\",\n type: \"text\",\n parent: \"contentReview Content\"\n });\n\nconst contentPublishedByField = () =>\n createModelField({\n label: \"Published by\",\n type: \"text\",\n parent: \"contentReview Content\"\n });\n\nconst stepStatusField = (): CmsModelField => ({\n multipleValues: false,\n listValidation: [],\n renderer: {\n name: \"radio-buttons\"\n },\n predefinedValues: {\n enabled: true,\n values: [\n {\n value: \"done\",\n label: \"Steps done\"\n },\n {\n value: \"active\",\n label: \"Step active\"\n },\n {\n value: \"inactive\",\n label: \"Step inactive\"\n }\n ]\n },\n label: \"Status\",\n id: \"contentReview_steps_status\",\n type: \"text\",\n validation: [\n {\n message: \"`status` field value is required in contentReview steps status.\",\n name: \"required\"\n }\n ],\n storageId: \"status\",\n fieldId: \"status\"\n});\n\nconst stepPendingChangeRequests = () =>\n createModelField({\n label: \"Pending change requests\",\n type: \"number\",\n parent: \"contentReview Step\",\n validation: [\n {\n message: \"`pendingChangeRequests` field value is required in contentReview step.\",\n name: \"required\"\n }\n ]\n });\n\nconst stepTotalComments = () =>\n createModelField({\n label: \"Total comments\",\n type: \"number\",\n parent: \"contentReview Step\",\n validation: [\n {\n message: \"`totalComments` field value is required in contentReview step.\",\n name: \"required\"\n }\n ]\n });\n\nconst latestCommentId = () =>\n createModelField({\n label: \"Latest comment Id\",\n type: \"text\",\n parent: \"contentReview\"\n });\n\nconst stepSignOffProvidedOn = () =>\n createModelField({\n label: \"Sign off provided on\",\n type: \"datetime\",\n parent: \"contentReview Step\"\n });\n\nconst stepSignOffProvidedBy = (fields: CmsModelField[]) =>\n createModelField({\n label: \"Sign off provided By\",\n type: \"object\",\n parent: \"contentReview Step\",\n multipleValues: false,\n settings: { fields }\n });\n\nconst stepSignOffProvidedById = () =>\n createModelField({\n label: \"Id\",\n type: \"text\",\n parent: \"contentReview Step\"\n });\n\nconst stepSignOffProvidedByDisplayName = () =>\n createModelField({\n label: \"DisplayName\",\n type: \"text\",\n parent: \"contentReview Step\"\n });\n\nconst stepsField = (fields: CmsModelField[]): CmsModelField => ({\n id: \"contentReview_steps\",\n label: \"Steps\",\n type: \"object\",\n settings: {\n fields,\n layout: fields.map(field => [field.storageId])\n },\n listValidation: [],\n validation: [],\n fieldId: \"steps\",\n storageId: \"steps\",\n multipleValues: true,\n predefinedValues: {\n values: [],\n enabled: false\n }\n});\n\ninterface CreateContentReviewModelDefinitionParams {\n reviewerModelId: string;\n}\n\nexport const CONTENT_REVIEW_MODEL_ID = \"apwContentReviewModelDefinition\";\n\nexport const createContentReviewModelDefinition = ({\n reviewerModelId\n}: CreateContentReviewModelDefinitionParams): WorkflowModelDefinition => ({\n name: \"APW - Content Review\",\n modelId: CONTENT_REVIEW_MODEL_ID,\n titleFieldId: \"content\",\n layout: [\n [\"contentReview_title\"],\n [\"contentReview_content\"],\n [\"contentReview_reviewStatus\"],\n [\"contentReview_reviewRequestedBy\"],\n [\"contentReview_steps\"],\n [\"contentReview_changeRequested\"],\n [\"contentReview_latestCommentId\"],\n [\"contentReview_workflowId\"]\n ],\n fields: [\n titleField(),\n contentField([\n contentIdField(),\n contentTypeField(),\n contentSettingsField([contentSettingsModelIdField()]),\n contentScheduledOnField(),\n contentScheduledByField(),\n scheduledActionIdField(),\n contentPublishedByField()\n ]),\n contentStatus(),\n stepsField([\n stepTitleField(),\n stepTypeField(),\n stepIdField(),\n stepReviewersField(reviewerModelId),\n stepStatusField(),\n stepPendingChangeRequests(),\n stepTotalComments(),\n stepSignOffProvidedOn(),\n stepSignOffProvidedBy([stepSignOffProvidedById(), stepSignOffProvidedByDisplayName()])\n ]),\n latestCommentId(),\n workflowIdField()\n ],\n description: \"\",\n isPrivate: true\n});\n"],"mappings":";;;;;;AAAA;AACA;AAIA,MAAMA,YAAY,GAAIC,MAAuB,IACzC,IAAAC,uBAAgB,EAAC;EACbC,KAAK,EAAE,SAAS;EAChBC,MAAM,EAAE,eAAe;EACvBC,IAAI,EAAE,QAAQ;EACdC,cAAc,EAAE,KAAK;EACrBC,QAAQ,EAAE;IAAEN;EAAO,CAAC;EACpBO,UAAU,EAAE,CACR;IACIC,OAAO,EAAE,qDAAqD;IAC9DC,IAAI,EAAE;EACV,CAAC;AAET,CAAC,CAAC;AAEN,MAAMC,aAAa,GAAG,MAClB,IAAAT,uBAAgB,EAAC;EACbC,KAAK,EAAE,QAAQ;EACfS,OAAO,EAAE,cAAc;EACvBR,MAAM,EAAE,eAAe;EACvBC,IAAI,EAAE,MAAM;EACZQ,gBAAgB,EAAE;IACdC,OAAO,EAAE,IAAI;IACbC,MAAM,EAAE,CACJ;MACIZ,KAAK,EAAE,cAAc;MACrBa,KAAK,EAAE;IACX,CAAC,EACD;MACIb,KAAK,EAAE,uBAAuB;MAC9Ba,KAAK,EAAE;IACX,CAAC,EACD;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BAA+B,CAAC,EACjC,CAAC,+BAA+B,CAAC,EACjC,CAAC,0BAA0B,CAAC,CAC/B;EACDvC,MAAM,EAAE,CACJgB,UAAU,EAAE,EACZjB,YAAY,CAAC,CACTkB,cAAc,EAAE,EAChBE,gBAAgB,EAAE,EAClBC,oBAAoB,CAAC,CAACC,2BAA2B,EAAE,CAAC,CAAC,EACrDE,uBAAuB,EAAE,EACzBC,uBAAuB,EAAE,EACzBF,sBAAsB,EAAE,EACxBG,uBAAuB,EAAE,CAC5B,CAAC,EACFf,aAAa,EAAE,EACf4B,UAAU,CAAC,CACP,IAAAS,wBAAc,GAAE,EAChB,IAAAC,uBAAa,GAAE,EACf,IAAAC,qBAAW,GAAE,EACb,IAAAC,4BAAkB,EAACN,eAAe,CAAC,EACnClB,eAAe,EAAE,EACjBK,yBAAyB,EAAE,EAC3BC,iBAAiB,EAAE,EACnBE,qBAAqB,EAAE,EACvBC,qBAAqB,CAAC,CAACC,uBAAuB,EAAE,EAAEC,gCAAgC,EAAE,CAAC,CAAC,CACzF,CAAC,EACFJ,eAAe,EAAE,EACjBf,eAAe,EAAE,CACpB;EACDiC,WAAW,EAAE,EAAE;EACfC,SAAS,EAAE;AACf,CAAC,CAAC;AAAC"}
|
1
|
+
{"version":3,"names":["contentField","fields","createModelField","label","parent","type","multipleValues","settings","validation","message","name","contentStatus","fieldId","predefinedValues","enabled","values","value","titleField","contentIdField","workflowIdField","contentTypeField","contentSettingsField","contentSettingsModelIdField","scheduledActionIdField","contentScheduledOnField","contentScheduledByField","contentPublishedByField","stepStatusField","listValidation","renderer","id","storageId","stepPendingChangeRequests","stepTotalComments","latestCommentId","stepSignOffProvidedOn","stepSignOffProvidedBy","stepSignOffProvidedById","stepSignOffProvidedByDisplayName","stepsField","layout","map","field","CONTENT_REVIEW_MODEL_ID","createContentReviewModelDefinition","reviewerModelId","modelId","titleFieldId","stepTitleField","stepTypeField","stepIdField","stepReviewersField","description","isPrivate"],"sources":["contentReview.model.ts"],"sourcesContent":["import { createModelField } from \"./utils\";\nimport { stepTitleField, stepTypeField, stepIdField, stepReviewersField } from \"./workflow.model\";\nimport { CmsModelField } from \"@webiny/api-headless-cms/types\";\nimport { WorkflowModelDefinition } from \"~/types\";\n\nconst contentField = (fields: CmsModelField[]) =>\n createModelField({\n label: \"Content\",\n parent: \"contentReview\",\n type: \"object\",\n multipleValues: false,\n settings: { fields },\n validation: [\n {\n message: \"`content` field value is required in contentReview.\",\n name: \"required\"\n }\n ]\n });\n\nconst contentStatus = () =>\n createModelField({\n label: \"Status\",\n fieldId: \"reviewStatus\",\n parent: \"contentReview\",\n type: \"text\",\n predefinedValues: {\n enabled: true,\n values: [\n {\n label: \"Under review\",\n value: \"underReview\"\n },\n {\n label: \"Ready to be published\",\n value: \"readyToBePublished\"\n },\n {\n label: \"Published\",\n value: \"published\"\n }\n ]\n },\n validation: [\n {\n message: \"`reviewStatus` field value is required in contentReview.\",\n name: \"required\"\n }\n ]\n });\n\nconst titleField = () =>\n createModelField({\n label: \"Title\",\n type: \"text\",\n parent: \"contentReview\",\n validation: [\n {\n message: \"`title` field value is required in contentReview.\",\n name: \"required\"\n }\n ]\n });\n\nconst contentIdField = () =>\n createModelField({\n label: \"Id\",\n type: \"text\",\n parent: \"contentReview Content\",\n validation: [\n {\n message: \"`id` field value is required in contentReview Content.\",\n name: \"required\"\n }\n ]\n });\n\nconst workflowIdField = () =>\n createModelField({\n label: \"Workflow Id\",\n type: \"text\",\n parent: \"contentReview\",\n validation: [\n {\n message: \"`workflowId` field value is required in contentReview Content.\",\n name: \"required\"\n }\n ]\n });\n\nconst contentTypeField = () =>\n createModelField({\n label: \"Type\",\n type: \"text\",\n parent: \"contentReview Type\",\n predefinedValues: {\n enabled: true,\n values: [\n {\n label: \"Page\",\n value: \"page\"\n },\n { value: \"cms-entry\", label: \"CMS Entry\" }\n ]\n },\n validation: [\n {\n message: \"`type` field value is required in contentReview Type.\",\n name: \"required\"\n }\n ]\n });\n\nconst contentSettingsField = (fields: CmsModelField[]) =>\n createModelField({\n label: \"Settings\",\n parent: \"contentReview Content\",\n type: \"object\",\n multipleValues: false,\n settings: { fields }\n });\n\nconst contentSettingsModelIdField = () =>\n createModelField({\n label: \"Model Id\",\n parent: \"contentReview Settings\",\n type: \"text\"\n });\n\nconst scheduledActionIdField = () =>\n createModelField({\n label: \"Scheduled action Id\",\n type: \"text\",\n parent: \"contentReview Content\"\n });\n\nconst contentScheduledOnField = () =>\n createModelField({\n label: \"Scheduled on\",\n type: \"datetime\",\n parent: \"contentReview Content\"\n });\n\nconst contentScheduledByField = () =>\n createModelField({\n label: \"Scheduled by\",\n type: \"text\",\n parent: \"contentReview Content\"\n });\n\nconst contentPublishedByField = () =>\n createModelField({\n label: \"Published by\",\n type: \"text\",\n parent: \"contentReview Content\"\n });\n\nconst stepStatusField = (): CmsModelField => ({\n multipleValues: false,\n listValidation: [],\n renderer: {\n name: \"radio-buttons\"\n },\n predefinedValues: {\n enabled: true,\n values: [\n {\n value: \"done\",\n label: \"Steps done\"\n },\n {\n value: \"active\",\n label: \"Step active\"\n },\n {\n value: \"inactive\",\n label: \"Step inactive\"\n }\n ]\n },\n label: \"Status\",\n id: \"contentReview_steps_status\",\n type: \"text\",\n validation: [\n {\n message: \"`status` field value is required in contentReview steps status.\",\n name: \"required\"\n }\n ],\n storageId: \"status\",\n fieldId: \"status\"\n});\n\nconst stepPendingChangeRequests = () =>\n createModelField({\n label: \"Pending change requests\",\n type: \"number\",\n parent: \"contentReview Step\",\n validation: [\n {\n message: \"`pendingChangeRequests` field value is required in contentReview step.\",\n name: \"required\"\n }\n ]\n });\n\nconst stepTotalComments = () =>\n createModelField({\n label: \"Total comments\",\n type: \"number\",\n parent: \"contentReview Step\",\n validation: [\n {\n message: \"`totalComments` field value is required in contentReview step.\",\n name: \"required\"\n }\n ]\n });\n\nconst latestCommentId = () =>\n createModelField({\n label: \"Latest comment Id\",\n type: \"text\",\n parent: \"contentReview\"\n });\n\nconst stepSignOffProvidedOn = () =>\n createModelField({\n label: \"Sign off provided on\",\n type: \"datetime\",\n parent: \"contentReview Step\"\n });\n\nconst stepSignOffProvidedBy = (fields: CmsModelField[]) =>\n createModelField({\n label: \"Sign off provided By\",\n type: \"object\",\n parent: \"contentReview Step\",\n multipleValues: false,\n settings: { fields }\n });\n\nconst stepSignOffProvidedById = () =>\n createModelField({\n label: \"Id\",\n type: \"text\",\n parent: \"contentReview Step\"\n });\n\nconst stepSignOffProvidedByDisplayName = () =>\n createModelField({\n label: \"DisplayName\",\n type: \"text\",\n parent: \"contentReview Step\"\n });\n\nconst stepsField = (fields: CmsModelField[]): CmsModelField => ({\n id: \"contentReview_steps\",\n label: \"Steps\",\n type: \"object\",\n settings: {\n fields,\n layout: fields.map(field => [field.storageId])\n },\n listValidation: [],\n validation: [],\n fieldId: \"steps\",\n storageId: \"steps\",\n multipleValues: true,\n predefinedValues: {\n values: [],\n enabled: false\n }\n});\n\ninterface CreateContentReviewModelDefinitionParams {\n reviewerModelId: string;\n}\n\nexport const CONTENT_REVIEW_MODEL_ID = \"apwContentReviewModelDefinition\";\n\nexport const createContentReviewModelDefinition = ({\n reviewerModelId\n}: CreateContentReviewModelDefinitionParams): WorkflowModelDefinition => ({\n name: \"APW - Content Review\",\n modelId: CONTENT_REVIEW_MODEL_ID,\n titleFieldId: \"content\",\n layout: [\n [\"contentReview_title\"],\n [\"contentReview_content\"],\n [\"contentReview_reviewStatus\"],\n [\"contentReview_reviewRequestedBy\"],\n [\"contentReview_steps\"],\n [\"contentReview_changeRequested\"],\n [\"contentReview_latestCommentId\"],\n [\"contentReview_workflowId\"]\n ],\n fields: [\n titleField(),\n contentField([\n contentIdField(),\n contentTypeField(),\n contentSettingsField([contentSettingsModelIdField()]),\n contentScheduledOnField(),\n contentScheduledByField(),\n scheduledActionIdField(),\n contentPublishedByField()\n ]),\n contentStatus(),\n stepsField([\n stepTitleField(),\n stepTypeField(),\n stepIdField(),\n stepReviewersField(reviewerModelId),\n stepStatusField(),\n stepPendingChangeRequests(),\n stepTotalComments(),\n stepSignOffProvidedOn(),\n stepSignOffProvidedBy([stepSignOffProvidedById(), stepSignOffProvidedByDisplayName()])\n ]),\n latestCommentId(),\n workflowIdField()\n ],\n description: \"\",\n isPrivate: true\n});\n"],"mappings":";;;;;;;AAAA;;AACA;;AAIA,MAAMA,YAAY,GAAIC,MAAD,IACjB,IAAAC,uBAAA,EAAiB;EACbC,KAAK,EAAE,SADM;EAEbC,MAAM,EAAE,eAFK;EAGbC,IAAI,EAAE,QAHO;EAIbC,cAAc,EAAE,KAJH;EAKbC,QAAQ,EAAE;IAAEN;EAAF,CALG;EAMbO,UAAU,EAAE,CACR;IACIC,OAAO,EAAE,qDADb;IAEIC,IAAI,EAAE;EAFV,CADQ;AANC,CAAjB,CADJ;;AAeA,MAAMC,aAAa,GAAG,MAClB,IAAAT,uBAAA,EAAiB;EACbC,KAAK,EAAE,QADM;EAEbS,OAAO,EAAE,cAFI;EAGbR,MAAM,EAAE,eAHK;EAIbC,IAAI,EAAE,MAJO;EAKbQ,gBAAgB,EAAE;IACdC,OAAO,EAAE,IADK;IAEdC,MAAM,EAAE,CACJ;MACIZ,KAAK,EAAE,cADX;MAEIa,KAAK,EAAE;IAFX,CADI,EAKJ;MACIb,KAAK,EAAE,uBADX;MAEIa,KAAK,EAAE;IAFX,CALI,EASJ;MACIb,KAAK,EAAE,WADX;MAEIa,KAAK,EAAE;IAFX,CATI;EAFM,CALL;EAsBbR,UAAU,EAAE,CACR;IACIC,OAAO,EAAE,0DADb;IAEIC,IAAI,EAAE;EAFV,CADQ;AAtBC,CAAjB,CADJ;;AA+BA,MAAMO,UAAU,GAAG,MACf,IAAAf,uBAAA,EAAiB;EACbC,KAAK,EAAE,OADM;EAEbE,IAAI,EAAE,MAFO;EAGbD,MAAM,EAAE,eAHK;EAIbI,UAAU,EAAE,CACR;IACIC,OAAO,EAAE,mDADb;IAEIC,IAAI,EAAE;EAFV,CADQ;AAJC,CAAjB,CADJ;;AAaA,MAAMQ,cAA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