Add audit start and end dates to audits
ISO audits often span a window distinct from certificate validity. Store optional audit_start_date and audit_end_date on the audit record and expose them through GraphQL, MCP, CLI, n8n, and console. Signed-off-by: Cursor Agent <cursoragent@cursor.com> Co-authored-by: Bryan FRIMIN <bryan@frimin.fr>
This commit is contained in:
committed by
Bryan Frimin
parent
dcb7ffa945
commit
fe215efbd1
@@ -113,6 +113,20 @@ export const description: INodeProperties[] = [
|
||||
default: '',
|
||||
description: 'The end date of the audit validity period',
|
||||
},
|
||||
{
|
||||
displayName: 'Audit Start Date',
|
||||
name: 'auditStartDate',
|
||||
type: 'dateTime',
|
||||
default: '',
|
||||
description: 'The start date of the audit engagement',
|
||||
},
|
||||
{
|
||||
displayName: 'Audit End Date',
|
||||
name: 'auditEndDate',
|
||||
type: 'dateTime',
|
||||
default: '',
|
||||
description: 'The end date of the audit engagement',
|
||||
},
|
||||
],
|
||||
},
|
||||
];
|
||||
@@ -128,6 +142,8 @@ export async function execute(
|
||||
state?: string;
|
||||
validFrom?: string;
|
||||
validUntil?: string;
|
||||
auditStartDate?: string;
|
||||
auditEndDate?: string;
|
||||
};
|
||||
|
||||
const query = `
|
||||
@@ -140,6 +156,8 @@ export async function execute(
|
||||
state
|
||||
validFrom
|
||||
validUntil
|
||||
auditStartDate
|
||||
auditEndDate
|
||||
reportUrl
|
||||
compliancePortalVisibility
|
||||
createdAt
|
||||
@@ -158,6 +176,8 @@ export async function execute(
|
||||
if (additionalFields.state) input.state = additionalFields.state;
|
||||
if (additionalFields.validFrom) input.validFrom = additionalFields.validFrom;
|
||||
if (additionalFields.validUntil) input.validUntil = additionalFields.validUntil;
|
||||
if (additionalFields.auditStartDate) input.auditStartDate = additionalFields.auditStartDate;
|
||||
if (additionalFields.auditEndDate) input.auditEndDate = additionalFields.auditEndDate;
|
||||
|
||||
const responseData = await proboApiRequest.call(this, query, { input });
|
||||
|
||||
|
||||
@@ -53,6 +53,8 @@ export async function execute(
|
||||
state
|
||||
validFrom
|
||||
validUntil
|
||||
auditStartDate
|
||||
auditEndDate
|
||||
reportUrl
|
||||
compliancePortalVisibility
|
||||
createdAt
|
||||
|
||||
@@ -53,6 +53,8 @@ export async function execute(
|
||||
state
|
||||
validFrom
|
||||
validUntil
|
||||
auditStartDate
|
||||
auditEndDate
|
||||
reportUrl
|
||||
compliancePortalVisibility
|
||||
createdAt
|
||||
|
||||
@@ -88,6 +88,8 @@ export async function execute(
|
||||
state
|
||||
validFrom
|
||||
validUntil
|
||||
auditStartDate
|
||||
auditEndDate
|
||||
reportUrl
|
||||
compliancePortalVisibility
|
||||
createdAt
|
||||
|
||||
@@ -99,6 +99,20 @@ export const description: INodeProperties[] = [
|
||||
default: '',
|
||||
description: 'The end date of the audit validity period',
|
||||
},
|
||||
{
|
||||
displayName: 'Audit Start Date',
|
||||
name: 'auditStartDate',
|
||||
type: 'dateTime',
|
||||
default: '',
|
||||
description: 'The start date of the audit engagement',
|
||||
},
|
||||
{
|
||||
displayName: 'Audit End Date',
|
||||
name: 'auditEndDate',
|
||||
type: 'dateTime',
|
||||
default: '',
|
||||
description: 'The end date of the audit engagement',
|
||||
},
|
||||
],
|
||||
},
|
||||
];
|
||||
@@ -113,6 +127,8 @@ export async function execute(
|
||||
state?: string;
|
||||
validFrom?: string;
|
||||
validUntil?: string;
|
||||
auditStartDate?: string;
|
||||
auditEndDate?: string;
|
||||
};
|
||||
|
||||
const query = `
|
||||
@@ -124,6 +140,8 @@ export async function execute(
|
||||
state
|
||||
validFrom
|
||||
validUntil
|
||||
auditStartDate
|
||||
auditEndDate
|
||||
reportUrl
|
||||
compliancePortalVisibility
|
||||
createdAt
|
||||
@@ -138,6 +156,8 @@ export async function execute(
|
||||
if (updateFields.state) input.state = updateFields.state;
|
||||
if (updateFields.validFrom) input.validFrom = updateFields.validFrom;
|
||||
if (updateFields.validUntil) input.validUntil = updateFields.validUntil;
|
||||
if (updateFields.auditStartDate) input.auditStartDate = updateFields.auditStartDate;
|
||||
if (updateFields.auditEndDate) input.auditEndDate = updateFields.auditEndDate;
|
||||
|
||||
const responseData = await proboApiRequest.call(this, query, { input });
|
||||
|
||||
|
||||
@@ -74,6 +74,8 @@ export async function execute(
|
||||
state
|
||||
validFrom
|
||||
validUntil
|
||||
auditStartDate
|
||||
auditEndDate
|
||||
reportUrl
|
||||
compliancePortalVisibility
|
||||
createdAt
|
||||
|
||||
Reference in New Issue
Block a user