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:
Cursor Agent
2026-07-28 14:35:36 +00:00
committed by Bryan Frimin
parent dcb7ffa945
commit fe215efbd1
25 changed files with 385 additions and 28 deletions

View File

@@ -47,6 +47,8 @@ export const auditNodeQuery = graphql`
name
validFrom
validUntil
auditStartDate
auditEndDate
reportFile {
id
fileName
@@ -91,6 +93,8 @@ export const createAuditMutation = graphql`
name
validFrom
validUntil
auditStartDate
auditEndDate
reportFile {
id
fileName
@@ -117,6 +121,8 @@ export const updateAuditMutation = graphql`
name
validFrom
validUntil
auditStartDate
auditEndDate
reportFile {
id
fileName
@@ -186,6 +192,8 @@ export const useCreateAudit = (connectionId: string) => {
name?: string | null;
validFrom?: string;
validUntil?: string;
auditStartDate?: string;
auditEndDate?: string;
reportKey?: string;
state?: string;
file?: File | null;
@@ -205,6 +213,8 @@ export const useCreateAudit = (connectionId: string) => {
name: input.name,
validFrom: input.validFrom,
validUntil: input.validUntil,
auditStartDate: input.auditStartDate,
auditEndDate: input.auditEndDate,
reportKey: input.reportKey,
state: input.state || "NOT_STARTED",
file: input.file ? null : undefined,
@@ -226,6 +236,8 @@ export const useUpdateAudit = () => {
name?: string | null;
validFrom?: string | null;
validUntil?: string | null;
auditStartDate?: string | null;
auditEndDate?: string | null;
state?: string;
}) => {
if (!input.id) {