@probo/n8n-nodes-probo 0.165.3 → 0.166.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/nodes/Probo/Probo.node.js +5 -0
- package/dist/nodes/Probo/Probo.node.js.map +1 -1
- package/dist/nodes/Probo/actions/document/archive.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/archive.operation.js +46 -0
- package/dist/nodes/Probo/actions/document/archive.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/cancelSignature.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/cancelSignature.operation.js +39 -0
- package/dist/nodes/Probo/actions/document/cancelSignature.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/create.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/create.operation.js +191 -0
- package/dist/nodes/Probo/actions/document/create.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/createDraftVersion.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/createDraftVersion.operation.js +52 -0
- package/dist/nodes/Probo/actions/document/createDraftVersion.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/delete.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/delete.operation.js +37 -0
- package/dist/nodes/Probo/actions/document/delete.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/deleteDraftVersion.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/deleteDraftVersion.operation.js +37 -0
- package/dist/nodes/Probo/actions/document/deleteDraftVersion.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/get.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/get.operation.js +46 -0
- package/dist/nodes/Probo/actions/document/get.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/getAll.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/getAll.operation.js +92 -0
- package/dist/nodes/Probo/actions/document/getAll.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/getAllSignatures.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/getAllSignatures.operation.js +95 -0
- package/dist/nodes/Probo/actions/document/getAllSignatures.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/getAllVersions.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/getAllVersions.operation.js +96 -0
- package/dist/nodes/Probo/actions/document/getAllVersions.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/getSignature.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/getSignature.operation.js +49 -0
- package/dist/nodes/Probo/actions/document/getSignature.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/getVersion.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/getVersion.operation.js +50 -0
- package/dist/nodes/Probo/actions/document/getVersion.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/index.d.ts +24 -0
- package/dist/nodes/Probo/actions/document/index.js +242 -0
- package/dist/nodes/Probo/actions/document/index.js.map +1 -0
- package/dist/nodes/Probo/actions/document/publishMajorVersion.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/publishMajorVersion.operation.js +79 -0
- package/dist/nodes/Probo/actions/document/publishMajorVersion.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/publishMinorVersion.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/publishMinorVersion.operation.js +79 -0
- package/dist/nodes/Probo/actions/document/publishMinorVersion.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/requestApproval.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/requestApproval.operation.js +79 -0
- package/dist/nodes/Probo/actions/document/requestApproval.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/requestSignature.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/requestSignature.operation.js +68 -0
- package/dist/nodes/Probo/actions/document/requestSignature.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/sendSigningNotifications.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/sendSigningNotifications.operation.js +37 -0
- package/dist/nodes/Probo/actions/document/sendSigningNotifications.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/unarchive.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/unarchive.operation.js +46 -0
- package/dist/nodes/Probo/actions/document/unarchive.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/update.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/update.operation.js +87 -0
- package/dist/nodes/Probo/actions/document/update.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/updateVersion.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/updateVersion.operation.js +123 -0
- package/dist/nodes/Probo/actions/document/updateVersion.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/document/voidApproval.operation.d.ts +3 -0
- package/dist/nodes/Probo/actions/document/voidApproval.operation.js +55 -0
- package/dist/nodes/Probo/actions/document/voidApproval.operation.js.map +1 -0
- package/dist/nodes/Probo/actions/index.js +2 -0
- package/dist/nodes/Probo/actions/index.js.map +1 -1
- package/dist/package.json +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const GenericFunctions_1 = require("../../GenericFunctions");
|
|
6
|
+
exports.description = [
|
|
7
|
+
{
|
|
8
|
+
displayName: 'Document ID',
|
|
9
|
+
name: 'documentId',
|
|
10
|
+
type: 'string',
|
|
11
|
+
displayOptions: {
|
|
12
|
+
show: {
|
|
13
|
+
resource: ['document'],
|
|
14
|
+
operation: ['publishMajorVersion'],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
default: '',
|
|
18
|
+
description: 'The ID of the document',
|
|
19
|
+
required: true,
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
displayName: 'Changelog',
|
|
23
|
+
name: 'changelog',
|
|
24
|
+
type: 'string',
|
|
25
|
+
typeOptions: {
|
|
26
|
+
rows: 4,
|
|
27
|
+
},
|
|
28
|
+
displayOptions: {
|
|
29
|
+
show: {
|
|
30
|
+
resource: ['document'],
|
|
31
|
+
operation: ['publishMajorVersion'],
|
|
32
|
+
},
|
|
33
|
+
},
|
|
34
|
+
default: '',
|
|
35
|
+
description: 'The changelog for this version',
|
|
36
|
+
},
|
|
37
|
+
];
|
|
38
|
+
async function execute(itemIndex) {
|
|
39
|
+
const documentId = this.getNodeParameter('documentId', itemIndex);
|
|
40
|
+
const changelog = this.getNodeParameter('changelog', itemIndex, '');
|
|
41
|
+
const query = `
|
|
42
|
+
mutation PublishMajorDocumentVersion($input: PublishMajorDocumentVersionInput!) {
|
|
43
|
+
publishMajorDocumentVersion(input: $input) {
|
|
44
|
+
document {
|
|
45
|
+
id
|
|
46
|
+
status
|
|
47
|
+
trustCenterVisibility
|
|
48
|
+
currentPublishedMajor
|
|
49
|
+
currentPublishedMinor
|
|
50
|
+
createdAt
|
|
51
|
+
updatedAt
|
|
52
|
+
}
|
|
53
|
+
documentVersion {
|
|
54
|
+
id
|
|
55
|
+
title
|
|
56
|
+
major
|
|
57
|
+
minor
|
|
58
|
+
status
|
|
59
|
+
content
|
|
60
|
+
changelog
|
|
61
|
+
classification
|
|
62
|
+
documentType
|
|
63
|
+
publishedAt
|
|
64
|
+
createdAt
|
|
65
|
+
updatedAt
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
`;
|
|
70
|
+
const input = { documentId };
|
|
71
|
+
if (changelog)
|
|
72
|
+
input.changelog = changelog;
|
|
73
|
+
const responseData = await GenericFunctions_1.proboApiRequest.call(this, query, { input });
|
|
74
|
+
return {
|
|
75
|
+
json: responseData,
|
|
76
|
+
pairedItem: { item: itemIndex },
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
//# sourceMappingURL=publishMajorVersion.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"publishMajorVersion.operation.js","sourceRoot":"","sources":["../../../../../nodes/Probo/actions/document/publishMajorVersion.operation.ts"],"names":[],"mappings":";;;AAkDA,0BA8CC;AAjFD,6DAAyD;AAE5C,QAAA,WAAW,GAAsB;IAC7C;QACC,WAAW,EAAE,aAAa;QAC1B,IAAI,EAAE,YAAY;QAClB,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,UAAU,CAAC;gBACtB,SAAS,EAAE,CAAC,qBAAqB,CAAC;aAClC;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,wBAAwB;QACrC,QAAQ,EAAE,IAAI;KACd;IACD;QACC,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,QAAQ;QACd,WAAW,EAAE;YACZ,IAAI,EAAE,CAAC;SACP;QACD,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,UAAU,CAAC;gBACtB,SAAS,EAAE,CAAC,qBAAqB,CAAC;aAClC;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,gCAAgC;KAC7C;CACD,CAAC;AAEK,KAAK,UAAU,OAAO,CAE5B,SAAiB;IAEjB,MAAM,UAAU,GAAG,IAAI,CAAC,gBAAgB,CAAC,YAAY,EAAE,SAAS,CAAW,CAAC;IAC5E,MAAM,SAAS,GAAG,IAAI,CAAC,gBAAgB,CAAC,WAAW,EAAE,SAAS,EAAE,EAAE,CAAW,CAAC;IAE9E,MAAM,KAAK,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA4Bb,CAAC;IAEF,MAAM,KAAK,GAA4B,EAAE,UAAU,EAAE,CAAC;IACtD,IAAI,SAAS;QAAE,KAAK,CAAC,SAAS,GAAG,SAAS,CAAC;IAE3C,MAAM,YAAY,GAAG,MAAM,kCAAe,CAAC,IAAI,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;IAExE,OAAO;QACN,IAAI,EAAE,YAAY;QAClB,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;KAC/B,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const GenericFunctions_1 = require("../../GenericFunctions");
|
|
6
|
+
exports.description = [
|
|
7
|
+
{
|
|
8
|
+
displayName: 'Document ID',
|
|
9
|
+
name: 'documentId',
|
|
10
|
+
type: 'string',
|
|
11
|
+
displayOptions: {
|
|
12
|
+
show: {
|
|
13
|
+
resource: ['document'],
|
|
14
|
+
operation: ['publishMinorVersion'],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
default: '',
|
|
18
|
+
description: 'The ID of the document',
|
|
19
|
+
required: true,
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
displayName: 'Changelog',
|
|
23
|
+
name: 'changelog',
|
|
24
|
+
type: 'string',
|
|
25
|
+
typeOptions: {
|
|
26
|
+
rows: 4,
|
|
27
|
+
},
|
|
28
|
+
displayOptions: {
|
|
29
|
+
show: {
|
|
30
|
+
resource: ['document'],
|
|
31
|
+
operation: ['publishMinorVersion'],
|
|
32
|
+
},
|
|
33
|
+
},
|
|
34
|
+
default: '',
|
|
35
|
+
description: 'The changelog for this version',
|
|
36
|
+
},
|
|
37
|
+
];
|
|
38
|
+
async function execute(itemIndex) {
|
|
39
|
+
const documentId = this.getNodeParameter('documentId', itemIndex);
|
|
40
|
+
const changelog = this.getNodeParameter('changelog', itemIndex, '');
|
|
41
|
+
const query = `
|
|
42
|
+
mutation PublishMinorDocumentVersion($input: PublishMinorDocumentVersionInput!) {
|
|
43
|
+
publishMinorDocumentVersion(input: $input) {
|
|
44
|
+
document {
|
|
45
|
+
id
|
|
46
|
+
status
|
|
47
|
+
trustCenterVisibility
|
|
48
|
+
currentPublishedMajor
|
|
49
|
+
currentPublishedMinor
|
|
50
|
+
createdAt
|
|
51
|
+
updatedAt
|
|
52
|
+
}
|
|
53
|
+
documentVersion {
|
|
54
|
+
id
|
|
55
|
+
title
|
|
56
|
+
major
|
|
57
|
+
minor
|
|
58
|
+
status
|
|
59
|
+
content
|
|
60
|
+
changelog
|
|
61
|
+
classification
|
|
62
|
+
documentType
|
|
63
|
+
publishedAt
|
|
64
|
+
createdAt
|
|
65
|
+
updatedAt
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
`;
|
|
70
|
+
const input = { documentId };
|
|
71
|
+
if (changelog)
|
|
72
|
+
input.changelog = changelog;
|
|
73
|
+
const responseData = await GenericFunctions_1.proboApiRequest.call(this, query, { input });
|
|
74
|
+
return {
|
|
75
|
+
json: responseData,
|
|
76
|
+
pairedItem: { item: itemIndex },
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
//# sourceMappingURL=publishMinorVersion.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"publishMinorVersion.operation.js","sourceRoot":"","sources":["../../../../../nodes/Probo/actions/document/publishMinorVersion.operation.ts"],"names":[],"mappings":";;;AAkDA,0BA8CC;AAjFD,6DAAyD;AAE5C,QAAA,WAAW,GAAsB;IAC7C;QACC,WAAW,EAAE,aAAa;QAC1B,IAAI,EAAE,YAAY;QAClB,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,UAAU,CAAC;gBACtB,SAAS,EAAE,CAAC,qBAAqB,CAAC;aAClC;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,wBAAwB;QACrC,QAAQ,EAAE,IAAI;KACd;IACD;QACC,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,QAAQ;QACd,WAAW,EAAE;YACZ,IAAI,EAAE,CAAC;SACP;QACD,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,UAAU,CAAC;gBACtB,SAAS,EAAE,CAAC,qBAAqB,CAAC;aAClC;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,gCAAgC;KAC7C;CACD,CAAC;AAEK,KAAK,UAAU,OAAO,CAE5B,SAAiB;IAEjB,MAAM,UAAU,GAAG,IAAI,CAAC,gBAAgB,CAAC,YAAY,EAAE,SAAS,CAAW,CAAC;IAC5E,MAAM,SAAS,GAAG,IAAI,CAAC,gBAAgB,CAAC,WAAW,EAAE,SAAS,EAAE,EAAE,CAAW,CAAC;IAE9E,MAAM,KAAK,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA4Bb,CAAC;IAEF,MAAM,KAAK,GAA4B,EAAE,UAAU,EAAE,CAAC;IACtD,IAAI,SAAS;QAAE,KAAK,CAAC,SAAS,GAAG,SAAS,CAAC;IAE3C,MAAM,YAAY,GAAG,MAAM,kCAAe,CAAC,IAAI,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;IAExE,OAAO;QACN,IAAI,EAAE,YAAY;QAClB,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;KAC/B,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const GenericFunctions_1 = require("../../GenericFunctions");
|
|
6
|
+
exports.description = [
|
|
7
|
+
{
|
|
8
|
+
displayName: 'Document ID',
|
|
9
|
+
name: 'documentId',
|
|
10
|
+
type: 'string',
|
|
11
|
+
displayOptions: {
|
|
12
|
+
show: {
|
|
13
|
+
resource: ['document'],
|
|
14
|
+
operation: ['requestApproval'],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
default: '',
|
|
18
|
+
description: 'The ID of the document',
|
|
19
|
+
required: true,
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
displayName: 'Approver IDs',
|
|
23
|
+
name: 'approverIds',
|
|
24
|
+
type: 'string',
|
|
25
|
+
displayOptions: {
|
|
26
|
+
show: {
|
|
27
|
+
resource: ['document'],
|
|
28
|
+
operation: ['requestApproval'],
|
|
29
|
+
},
|
|
30
|
+
},
|
|
31
|
+
default: '',
|
|
32
|
+
description: 'Comma-separated list of approver profile IDs',
|
|
33
|
+
required: true,
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
displayName: 'Changelog',
|
|
37
|
+
name: 'changelog',
|
|
38
|
+
type: 'string',
|
|
39
|
+
typeOptions: {
|
|
40
|
+
rows: 4,
|
|
41
|
+
},
|
|
42
|
+
displayOptions: {
|
|
43
|
+
show: {
|
|
44
|
+
resource: ['document'],
|
|
45
|
+
operation: ['requestApproval'],
|
|
46
|
+
},
|
|
47
|
+
},
|
|
48
|
+
default: '',
|
|
49
|
+
description: 'The changelog for this version',
|
|
50
|
+
},
|
|
51
|
+
];
|
|
52
|
+
async function execute(itemIndex) {
|
|
53
|
+
const documentId = this.getNodeParameter('documentId', itemIndex);
|
|
54
|
+
const approverIds = this.getNodeParameter('approverIds', itemIndex);
|
|
55
|
+
const changelog = this.getNodeParameter('changelog', itemIndex, '');
|
|
56
|
+
const query = `
|
|
57
|
+
mutation RequestDocumentVersionApproval($input: RequestDocumentVersionApprovalInput!) {
|
|
58
|
+
requestDocumentVersionApproval(input: $input) {
|
|
59
|
+
approvalQuorum {
|
|
60
|
+
id
|
|
61
|
+
createdAt
|
|
62
|
+
updatedAt
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
`;
|
|
67
|
+
const input = {
|
|
68
|
+
documentId,
|
|
69
|
+
approverIds: approverIds.split(',').map(id => id.trim()).filter(Boolean),
|
|
70
|
+
};
|
|
71
|
+
if (changelog)
|
|
72
|
+
input.changelog = changelog;
|
|
73
|
+
const responseData = await GenericFunctions_1.proboApiRequest.call(this, query, { input });
|
|
74
|
+
return {
|
|
75
|
+
json: responseData,
|
|
76
|
+
pairedItem: { item: itemIndex },
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
//# sourceMappingURL=requestApproval.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"requestApproval.operation.js","sourceRoot":"","sources":["../../../../../nodes/Probo/actions/document/requestApproval.operation.ts"],"names":[],"mappings":";;;AAgEA,0BAgCC;AAjFD,6DAAyD;AAE5C,QAAA,WAAW,GAAsB;IAC7C;QACC,WAAW,EAAE,aAAa;QAC1B,IAAI,EAAE,YAAY;QAClB,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,UAAU,CAAC;gBACtB,SAAS,EAAE,CAAC,iBAAiB,CAAC;aAC9B;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,wBAAwB;QACrC,QAAQ,EAAE,IAAI;KACd;IACD;QACC,WAAW,EAAE,cAAc;QAC3B,IAAI,EAAE,aAAa;QACnB,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,UAAU,CAAC;gBACtB,SAAS,EAAE,CAAC,iBAAiB,CAAC;aAC9B;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,8CAA8C;QAC3D,QAAQ,EAAE,IAAI;KACd;IACD;QACC,WAAW,EAAE,WAAW;QACxB,IAAI,EAAE,WAAW;QACjB,IAAI,EAAE,QAAQ;QACd,WAAW,EAAE;YACZ,IAAI,EAAE,CAAC;SACP;QACD,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,UAAU,CAAC;gBACtB,SAAS,EAAE,CAAC,iBAAiB,CAAC;aAC9B;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,gCAAgC;KAC7C;CACD,CAAC;AAEK,KAAK,UAAU,OAAO,CAE5B,SAAiB;IAEjB,MAAM,UAAU,GAAG,IAAI,CAAC,gBAAgB,CAAC,YAAY,EAAE,SAAS,CAAW,CAAC;IAC5E,MAAM,WAAW,GAAG,IAAI,CAAC,gBAAgB,CAAC,aAAa,EAAE,SAAS,CAAW,CAAC;IAC9E,MAAM,SAAS,GAAG,IAAI,CAAC,gBAAgB,CAAC,WAAW,EAAE,SAAS,EAAE,EAAE,CAAW,CAAC;IAE9E,MAAM,KAAK,GAAG;;;;;;;;;;EAUb,CAAC;IAEF,MAAM,KAAK,GAA4B;QACtC,UAAU;QACV,WAAW,EAAE,WAAW,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,IAAI,EAAE,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC;KACxE,CAAC;IACF,IAAI,SAAS;QAAE,KAAK,CAAC,SAAS,GAAG,SAAS,CAAC;IAE3C,MAAM,YAAY,GAAG,MAAM,kCAAe,CAAC,IAAI,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;IAExE,OAAO;QACN,IAAI,EAAE,YAAY;QAClB,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;KAC/B,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const GenericFunctions_1 = require("../../GenericFunctions");
|
|
6
|
+
exports.description = [
|
|
7
|
+
{
|
|
8
|
+
displayName: 'Document Version ID',
|
|
9
|
+
name: 'documentVersionId',
|
|
10
|
+
type: 'string',
|
|
11
|
+
displayOptions: {
|
|
12
|
+
show: {
|
|
13
|
+
resource: ['document'],
|
|
14
|
+
operation: ['requestSignature'],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
default: '',
|
|
18
|
+
description: 'The ID of the document version',
|
|
19
|
+
required: true,
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
displayName: 'Signatory ID',
|
|
23
|
+
name: 'signatoryId',
|
|
24
|
+
type: 'string',
|
|
25
|
+
displayOptions: {
|
|
26
|
+
show: {
|
|
27
|
+
resource: ['document'],
|
|
28
|
+
operation: ['requestSignature'],
|
|
29
|
+
},
|
|
30
|
+
},
|
|
31
|
+
default: '',
|
|
32
|
+
description: 'The profile ID of the signatory',
|
|
33
|
+
required: true,
|
|
34
|
+
},
|
|
35
|
+
];
|
|
36
|
+
async function execute(itemIndex) {
|
|
37
|
+
const documentVersionId = this.getNodeParameter('documentVersionId', itemIndex);
|
|
38
|
+
const signatoryId = this.getNodeParameter('signatoryId', itemIndex);
|
|
39
|
+
const query = `
|
|
40
|
+
mutation RequestSignature($input: RequestSignatureInput!) {
|
|
41
|
+
requestSignature(input: $input) {
|
|
42
|
+
documentVersionSignatureEdge {
|
|
43
|
+
node {
|
|
44
|
+
id
|
|
45
|
+
state
|
|
46
|
+
signedAt
|
|
47
|
+
requestedAt
|
|
48
|
+
createdAt
|
|
49
|
+
updatedAt
|
|
50
|
+
signedBy {
|
|
51
|
+
id
|
|
52
|
+
fullName
|
|
53
|
+
primaryEmailAddress
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
`;
|
|
60
|
+
const responseData = await GenericFunctions_1.proboApiRequest.call(this, query, {
|
|
61
|
+
input: { documentVersionId, signatoryId },
|
|
62
|
+
});
|
|
63
|
+
return {
|
|
64
|
+
json: responseData,
|
|
65
|
+
pairedItem: { item: itemIndex },
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
//# sourceMappingURL=requestSignature.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"requestSignature.operation.js","sourceRoot":"","sources":["../../../../../nodes/Probo/actions/document/requestSignature.operation.ts"],"names":[],"mappings":";;;AAgDA,0BAqCC;AAtED,6DAAyD;AAE5C,QAAA,WAAW,GAAsB;IAC7C;QACC,WAAW,EAAE,qBAAqB;QAClC,IAAI,EAAE,mBAAmB;QACzB,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,UAAU,CAAC;gBACtB,SAAS,EAAE,CAAC,kBAAkB,CAAC;aAC/B;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,gCAAgC;QAC7C,QAAQ,EAAE,IAAI;KACd;IACD;QACC,WAAW,EAAE,cAAc;QAC3B,IAAI,EAAE,aAAa;QACnB,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,UAAU,CAAC;gBACtB,SAAS,EAAE,CAAC,kBAAkB,CAAC;aAC/B;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,iCAAiC;QAC9C,QAAQ,EAAE,IAAI;KACd;CACD,CAAC;AAEK,KAAK,UAAU,OAAO,CAE5B,SAAiB;IAEjB,MAAM,iBAAiB,GAAG,IAAI,CAAC,gBAAgB,CAAC,mBAAmB,EAAE,SAAS,CAAW,CAAC;IAC1F,MAAM,WAAW,GAAG,IAAI,CAAC,gBAAgB,CAAC,aAAa,EAAE,SAAS,CAAW,CAAC;IAE9E,MAAM,KAAK,GAAG;;;;;;;;;;;;;;;;;;;;EAoBb,CAAC;IAEF,MAAM,YAAY,GAAG,MAAM,kCAAe,CAAC,IAAI,CAAC,IAAI,EAAE,KAAK,EAAE;QAC5D,KAAK,EAAE,EAAE,iBAAiB,EAAE,WAAW,EAAE;KACzC,CAAC,CAAC;IAEH,OAAO;QACN,IAAI,EAAE,YAAY;QAClB,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;KAC/B,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const GenericFunctions_1 = require("../../GenericFunctions");
|
|
6
|
+
exports.description = [
|
|
7
|
+
{
|
|
8
|
+
displayName: 'Organization ID',
|
|
9
|
+
name: 'organizationId',
|
|
10
|
+
type: 'string',
|
|
11
|
+
displayOptions: {
|
|
12
|
+
show: {
|
|
13
|
+
resource: ['document'],
|
|
14
|
+
operation: ['sendSigningNotifications'],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
default: '',
|
|
18
|
+
description: 'The ID of the organization',
|
|
19
|
+
required: true,
|
|
20
|
+
},
|
|
21
|
+
];
|
|
22
|
+
async function execute(itemIndex) {
|
|
23
|
+
const organizationId = this.getNodeParameter('organizationId', itemIndex);
|
|
24
|
+
const query = `
|
|
25
|
+
mutation SendSigningNotifications($input: SendSigningNotificationsInput!) {
|
|
26
|
+
sendSigningNotifications(input: $input) {
|
|
27
|
+
success
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
`;
|
|
31
|
+
const responseData = await GenericFunctions_1.proboApiRequest.call(this, query, { input: { organizationId } });
|
|
32
|
+
return {
|
|
33
|
+
json: responseData,
|
|
34
|
+
pairedItem: { item: itemIndex },
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
//# sourceMappingURL=sendSigningNotifications.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sendSigningNotifications.operation.js","sourceRoot":"","sources":["../../../../../nodes/Probo/actions/document/sendSigningNotifications.operation.ts"],"names":[],"mappings":";;;AAkCA,0BAoBC;AAvCD,6DAAyD;AAE5C,QAAA,WAAW,GAAsB;IAC7C;QACC,WAAW,EAAE,iBAAiB;QAC9B,IAAI,EAAE,gBAAgB;QACtB,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,UAAU,CAAC;gBACtB,SAAS,EAAE,CAAC,0BAA0B,CAAC;aACvC;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,4BAA4B;QACzC,QAAQ,EAAE,IAAI;KACd;CACD,CAAC;AAEK,KAAK,UAAU,OAAO,CAE5B,SAAiB;IAEjB,MAAM,cAAc,GAAG,IAAI,CAAC,gBAAgB,CAAC,gBAAgB,EAAE,SAAS,CAAW,CAAC;IAEpF,MAAM,KAAK,GAAG;;;;;;EAMb,CAAC;IAEF,MAAM,YAAY,GAAG,MAAM,kCAAe,CAAC,IAAI,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,EAAE,cAAc,EAAE,EAAE,CAAC,CAAC;IAE5F,OAAO;QACN,IAAI,EAAE,YAAY;QAClB,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;KAC/B,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const GenericFunctions_1 = require("../../GenericFunctions");
|
|
6
|
+
exports.description = [
|
|
7
|
+
{
|
|
8
|
+
displayName: 'Document ID',
|
|
9
|
+
name: 'documentId',
|
|
10
|
+
type: 'string',
|
|
11
|
+
displayOptions: {
|
|
12
|
+
show: {
|
|
13
|
+
resource: ['document'],
|
|
14
|
+
operation: ['unarchive'],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
default: '',
|
|
18
|
+
description: 'The ID of the document to unarchive',
|
|
19
|
+
required: true,
|
|
20
|
+
},
|
|
21
|
+
];
|
|
22
|
+
async function execute(itemIndex) {
|
|
23
|
+
const documentId = this.getNodeParameter('documentId', itemIndex);
|
|
24
|
+
const query = `
|
|
25
|
+
mutation UnarchiveDocument($input: UnarchiveDocumentInput!) {
|
|
26
|
+
unarchiveDocument(input: $input) {
|
|
27
|
+
document {
|
|
28
|
+
id
|
|
29
|
+
status
|
|
30
|
+
trustCenterVisibility
|
|
31
|
+
currentPublishedMajor
|
|
32
|
+
currentPublishedMinor
|
|
33
|
+
archivedAt
|
|
34
|
+
createdAt
|
|
35
|
+
updatedAt
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
`;
|
|
40
|
+
const responseData = await GenericFunctions_1.proboApiRequest.call(this, query, { input: { documentId } });
|
|
41
|
+
return {
|
|
42
|
+
json: responseData,
|
|
43
|
+
pairedItem: { item: itemIndex },
|
|
44
|
+
};
|
|
45
|
+
}
|
|
46
|
+
//# sourceMappingURL=unarchive.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"unarchive.operation.js","sourceRoot":"","sources":["../../../../../nodes/Probo/actions/document/unarchive.operation.ts"],"names":[],"mappings":";;;AAkCA,0BA6BC;AAhDD,6DAAyD;AAE5C,QAAA,WAAW,GAAsB;IAC7C;QACC,WAAW,EAAE,aAAa;QAC1B,IAAI,EAAE,YAAY;QAClB,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,UAAU,CAAC;gBACtB,SAAS,EAAE,CAAC,WAAW,CAAC;aACxB;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,qCAAqC;QAClD,QAAQ,EAAE,IAAI;KACd;CACD,CAAC;AAEK,KAAK,UAAU,OAAO,CAE5B,SAAiB;IAEjB,MAAM,UAAU,GAAG,IAAI,CAAC,gBAAgB,CAAC,YAAY,EAAE,SAAS,CAAW,CAAC;IAE5E,MAAM,KAAK,GAAG;;;;;;;;;;;;;;;EAeb,CAAC;IAEF,MAAM,YAAY,GAAG,MAAM,kCAAe,CAAC,IAAI,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,EAAE,UAAU,EAAE,EAAE,CAAC,CAAC;IAExF,OAAO;QACN,IAAI,EAAE,YAAY;QAClB,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;KAC/B,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const GenericFunctions_1 = require("../../GenericFunctions");
|
|
6
|
+
exports.description = [
|
|
7
|
+
{
|
|
8
|
+
displayName: 'Document ID',
|
|
9
|
+
name: 'documentId',
|
|
10
|
+
type: 'string',
|
|
11
|
+
displayOptions: {
|
|
12
|
+
show: {
|
|
13
|
+
resource: ['document'],
|
|
14
|
+
operation: ['update'],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
default: '',
|
|
18
|
+
description: 'The ID of the document to update',
|
|
19
|
+
required: true,
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
displayName: 'Update Fields',
|
|
23
|
+
name: 'updateFields',
|
|
24
|
+
type: 'collection',
|
|
25
|
+
placeholder: 'Add Field',
|
|
26
|
+
default: {},
|
|
27
|
+
displayOptions: {
|
|
28
|
+
show: {
|
|
29
|
+
resource: ['document'],
|
|
30
|
+
operation: ['update'],
|
|
31
|
+
},
|
|
32
|
+
},
|
|
33
|
+
options: [
|
|
34
|
+
{
|
|
35
|
+
displayName: 'Trust Center Visibility',
|
|
36
|
+
name: 'trustCenterVisibility',
|
|
37
|
+
type: 'options',
|
|
38
|
+
options: [
|
|
39
|
+
{ name: 'None', value: 'NONE' },
|
|
40
|
+
{ name: 'Private', value: 'PRIVATE' },
|
|
41
|
+
{ name: 'Public', value: 'PUBLIC' },
|
|
42
|
+
],
|
|
43
|
+
default: 'NONE',
|
|
44
|
+
description: 'The trust center visibility of the document',
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
displayName: 'Default Approver IDs',
|
|
48
|
+
name: 'defaultApproverIds',
|
|
49
|
+
type: 'string',
|
|
50
|
+
default: '',
|
|
51
|
+
description: 'Comma-separated list of default approver profile IDs',
|
|
52
|
+
},
|
|
53
|
+
],
|
|
54
|
+
},
|
|
55
|
+
];
|
|
56
|
+
async function execute(itemIndex) {
|
|
57
|
+
const documentId = this.getNodeParameter('documentId', itemIndex);
|
|
58
|
+
const updateFields = this.getNodeParameter('updateFields', itemIndex, {});
|
|
59
|
+
const query = `
|
|
60
|
+
mutation UpdateDocument($input: UpdateDocumentInput!) {
|
|
61
|
+
updateDocument(input: $input) {
|
|
62
|
+
document {
|
|
63
|
+
id
|
|
64
|
+
status
|
|
65
|
+
trustCenterVisibility
|
|
66
|
+
currentPublishedMajor
|
|
67
|
+
currentPublishedMinor
|
|
68
|
+
archivedAt
|
|
69
|
+
createdAt
|
|
70
|
+
updatedAt
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
`;
|
|
75
|
+
const input = { id: documentId };
|
|
76
|
+
if (updateFields.trustCenterVisibility !== undefined)
|
|
77
|
+
input.trustCenterVisibility = updateFields.trustCenterVisibility;
|
|
78
|
+
if (updateFields.defaultApproverIds !== undefined && updateFields.defaultApproverIds !== '') {
|
|
79
|
+
input.defaultApproverIds = updateFields.defaultApproverIds.split(',').map(id => id.trim()).filter(Boolean);
|
|
80
|
+
}
|
|
81
|
+
const responseData = await GenericFunctions_1.proboApiRequest.call(this, query, { input });
|
|
82
|
+
return {
|
|
83
|
+
json: responseData,
|
|
84
|
+
pairedItem: { item: itemIndex },
|
|
85
|
+
};
|
|
86
|
+
}
|
|
87
|
+
//# sourceMappingURL=update.operation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"update.operation.js","sourceRoot":"","sources":["../../../../../nodes/Probo/actions/document/update.operation.ts"],"names":[],"mappings":";;;AAoEA,0BAuCC;AA5FD,6DAAyD;AAE5C,QAAA,WAAW,GAAsB;IAC7C;QACC,WAAW,EAAE,aAAa;QAC1B,IAAI,EAAE,YAAY;QAClB,IAAI,EAAE,QAAQ;QACd,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,UAAU,CAAC;gBACtB,SAAS,EAAE,CAAC,QAAQ,CAAC;aACrB;SACD;QACD,OAAO,EAAE,EAAE;QACX,WAAW,EAAE,kCAAkC;QAC/C,QAAQ,EAAE,IAAI;KACd;IACD;QACC,WAAW,EAAE,eAAe;QAC5B,IAAI,EAAE,cAAc;QACpB,IAAI,EAAE,YAAY;QAClB,WAAW,EAAE,WAAW;QACxB,OAAO,EAAE,EAAE;QACX,cAAc,EAAE;YACf,IAAI,EAAE;gBACL,QAAQ,EAAE,CAAC,UAAU,CAAC;gBACtB,SAAS,EAAE,CAAC,QAAQ,CAAC;aACrB;SACD;QACD,OAAO,EAAE;YACR;gBACC,WAAW,EAAE,yBAAyB;gBACtC,IAAI,EAAE,uBAAuB;gBAC7B,IAAI,EAAE,SAAS;gBACf,OAAO,EAAE;oBACR,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE;oBAC/B,EAAE,IAAI,EAAE,SAAS,EAAE,KAAK,EAAE,SAAS,EAAE;oBACrC,EAAE,IAAI,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE;iBACnC;gBACD,OAAO,EAAE,MAAM;gBACf,WAAW,EAAE,6CAA6C;aAC1D;YACD;gBACC,WAAW,EAAE,sBAAsB;gBACnC,IAAI,EAAE,oBAAoB;gBAC1B,IAAI,EAAE,QAAQ;gBACd,OAAO,EAAE,EAAE;gBACX,WAAW,EAAE,sDAAsD;aACnE;SACD;KACD;CACD,CAAC;AAEK,KAAK,UAAU,OAAO,CAE5B,SAAiB;IAEjB,MAAM,UAAU,GAAG,IAAI,CAAC,gBAAgB,CAAC,YAAY,EAAE,SAAS,CAAW,CAAC;IAC5E,MAAM,YAAY,GAAG,IAAI,CAAC,gBAAgB,CAAC,cAAc,EAAE,SAAS,EAAE,EAAE,CAGvE,CAAC;IAEF,MAAM,KAAK,GAAG;;;;;;;;;;;;;;;EAeb,CAAC;IAEF,MAAM,KAAK,GAA4B,EAAE,EAAE,EAAE,UAAU,EAAE,CAAC;IAC1D,IAAI,YAAY,CAAC,qBAAqB,KAAK,SAAS;QAAE,KAAK,CAAC,qBAAqB,GAAG,YAAY,CAAC,qBAAqB,CAAC;IACvH,IAAI,YAAY,CAAC,kBAAkB,KAAK,SAAS,IAAI,YAAY,CAAC,kBAAkB,KAAK,EAAE,EAAE,CAAC;QAC7F,KAAK,CAAC,kBAAkB,GAAG,YAAY,CAAC,kBAAkB,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,IAAI,EAAE,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;IAC5G,CAAC;IAED,MAAM,YAAY,GAAG,MAAM,kCAAe,CAAC,IAAI,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,CAAC,CAAC;IAExE,OAAO;QACN,IAAI,EAAE,YAAY;QAClB,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE;KAC/B,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.description = void 0;
|
|
4
|
+
exports.execute = execute;
|
|
5
|
+
const GenericFunctions_1 = require("../../GenericFunctions");
|
|
6
|
+
exports.description = [
|
|
7
|
+
{
|
|
8
|
+
displayName: 'Document Version ID',
|
|
9
|
+
name: 'documentVersionId',
|
|
10
|
+
type: 'string',
|
|
11
|
+
displayOptions: {
|
|
12
|
+
show: {
|
|
13
|
+
resource: ['document'],
|
|
14
|
+
operation: ['updateVersion'],
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
default: '',
|
|
18
|
+
description: 'The ID of the document version to update',
|
|
19
|
+
required: true,
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
displayName: 'Update Fields',
|
|
23
|
+
name: 'updateFields',
|
|
24
|
+
type: 'collection',
|
|
25
|
+
placeholder: 'Add Field',
|
|
26
|
+
default: {},
|
|
27
|
+
displayOptions: {
|
|
28
|
+
show: {
|
|
29
|
+
resource: ['document'],
|
|
30
|
+
operation: ['updateVersion'],
|
|
31
|
+
},
|
|
32
|
+
},
|
|
33
|
+
options: [
|
|
34
|
+
{
|
|
35
|
+
displayName: 'Title',
|
|
36
|
+
name: 'title',
|
|
37
|
+
type: 'string',
|
|
38
|
+
default: '',
|
|
39
|
+
description: 'The title of the document version',
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
displayName: 'Content',
|
|
43
|
+
name: 'content',
|
|
44
|
+
type: 'string',
|
|
45
|
+
typeOptions: {
|
|
46
|
+
rows: 6,
|
|
47
|
+
},
|
|
48
|
+
default: '',
|
|
49
|
+
description: 'The content of the document in markdown format',
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
displayName: 'Classification',
|
|
53
|
+
name: 'classification',
|
|
54
|
+
type: 'options',
|
|
55
|
+
options: [
|
|
56
|
+
{ name: 'Confidential', value: 'CONFIDENTIAL' },
|
|
57
|
+
{ name: 'Internal', value: 'INTERNAL' },
|
|
58
|
+
{ name: 'Public', value: 'PUBLIC' },
|
|
59
|
+
{ name: 'Secret', value: 'SECRET' },
|
|
60
|
+
],
|
|
61
|
+
default: 'INTERNAL',
|
|
62
|
+
description: 'The classification of the document',
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
displayName: 'Document Type',
|
|
66
|
+
name: 'documentType',
|
|
67
|
+
type: 'options',
|
|
68
|
+
options: [
|
|
69
|
+
{ name: 'Governance', value: 'GOVERNANCE' },
|
|
70
|
+
{ name: 'Other', value: 'OTHER' },
|
|
71
|
+
{ name: 'Plan', value: 'PLAN' },
|
|
72
|
+
{ name: 'Policy', value: 'POLICY' },
|
|
73
|
+
{ name: 'Procedure', value: 'PROCEDURE' },
|
|
74
|
+
{ name: 'Record', value: 'RECORD' },
|
|
75
|
+
{ name: 'Register', value: 'REGISTER' },
|
|
76
|
+
{ name: 'Report', value: 'REPORT' },
|
|
77
|
+
{ name: 'Template', value: 'TEMPLATE' },
|
|
78
|
+
],
|
|
79
|
+
default: 'POLICY',
|
|
80
|
+
description: 'The type of the document',
|
|
81
|
+
},
|
|
82
|
+
],
|
|
83
|
+
},
|
|
84
|
+
];
|
|
85
|
+
async function execute(itemIndex) {
|
|
86
|
+
const documentVersionId = this.getNodeParameter('documentVersionId', itemIndex);
|
|
87
|
+
const updateFields = this.getNodeParameter('updateFields', itemIndex, {});
|
|
88
|
+
const query = `
|
|
89
|
+
mutation UpdateDocumentVersion($input: UpdateDocumentVersionInput!) {
|
|
90
|
+
updateDocumentVersion(input: $input) {
|
|
91
|
+
documentVersion {
|
|
92
|
+
id
|
|
93
|
+
title
|
|
94
|
+
major
|
|
95
|
+
minor
|
|
96
|
+
status
|
|
97
|
+
content
|
|
98
|
+
changelog
|
|
99
|
+
classification
|
|
100
|
+
documentType
|
|
101
|
+
publishedAt
|
|
102
|
+
createdAt
|
|
103
|
+
updatedAt
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
`;
|
|
108
|
+
const input = { documentVersionId };
|
|
109
|
+
if (updateFields.title !== undefined)
|
|
110
|
+
input.title = updateFields.title;
|
|
111
|
+
if (updateFields.content !== undefined)
|
|
112
|
+
input.content = updateFields.content;
|
|
113
|
+
if (updateFields.classification !== undefined)
|
|
114
|
+
input.classification = updateFields.classification;
|
|
115
|
+
if (updateFields.documentType !== undefined)
|
|
116
|
+
input.documentType = updateFields.documentType;
|
|
117
|
+
const responseData = await GenericFunctions_1.proboApiRequest.call(this, query, { input });
|
|
118
|
+
return {
|
|
119
|
+
json: responseData,
|
|
120
|
+
pairedItem: { item: itemIndex },
|
|
121
|
+
};
|
|
122
|
+
}
|
|
123
|
+
//# sourceMappingURL=updateVersion.operation.js.map
|