Class

InvestigationController

InvestigationController()

Investigation Controller Handles investigation-related HTTP requests

Constructor

# new InvestigationController()

View Source controllers/investigation.controller.js, line 52

Methods

# async static cloneInvestigation(req, res, _next) → {Promise.<void>}

Clone an investigation.

Parameters:
Name Type Description
req ICloneInvestigationRequest

Express request with the investigation identifier to clone.

res Response

Express response used to return the cloned investigation.

_next NextFunction

Express next function (unused).

View Source controllers/investigation.controller.js, line 431

Resolves when the response has been sent.

Promise.<void>

# async static createInvestigation(req, res) → {Promise.<void>}

Create a new investigation.

Parameters:
Name Type Description
req ICreateInvestigationRequest

Express request with investigation payload and user context.

res Response

Express response used to return the created investigation.

View Source controllers/investigation.controller.js, line 59

Resolves when the response has been sent.

Promise.<void>

# async static deleteInvestigation(req, res, _next) → {Promise.<void>}

Delete an investigation and its related chat history.

Parameters:
Name Type Description
req IAuthenticatedRequest

Express request with the investigation identifier to remove.

res Response

Express response used to confirm the deletion result.

_next NextFunction

Express next function (unused).

View Source controllers/investigation.controller.js, line 363

Resolves when the response has been sent.

Promise.<void>

# async static getFieldHistory(req, res, _next) → {Promise.<void>}

Get history for a specific field.

Parameters:
Name Type Description
req IAuthenticatedRequest

Express request containing investigation ID and field path.

res Response

Express response used to return the field history.

_next NextFunction

Express next function (unused).

View Source controllers/investigation.controller.js, line 504

Resolves when the response has been sent.

Promise.<void>

# async static getInvestigation(req, res, _next) → {Promise.<void>}

Get a single investigation by ID.

Parameters:
Name Type Description
req IAuthenticatedRequest

Express request containing the investigation identifier.

res Response

Express response used to return the investigation.

_next NextFunction

Express next function (unused).

View Source controllers/investigation.controller.js, line 204

Resolves when the response has been sent.

Promise.<void>

# static getInvestigationFormat(req, res, _next) → {void}

Get investigation schema format.

Parameters:
Name Type Description
req IAuthenticatedRequest

Express request.

res Response

Express response used to return the schema format.

_next NextFunction

Express next function (unused).

View Source controllers/investigation.controller.js, line 409

void

# async static getInvestigationVersions(req, res, _next) → {Promise.<void>}

Get investigation versions.

Parameters:
Name Type Description
req IAuthenticatedRequest

Express request with the investigation identifier to get versions.

res Response

Express response used to return the investigation versions.

_next NextFunction

Express next function (unused).

View Source controllers/investigation.controller.js, line 548

Resolves when the response has been sent.

Promise.<void>

# async static getInvestigations(req, res) → {Promise.<void>}

Get investigations with pagination, grouped by curriculum.

Parameters:
Name Type Description
req IAuthenticatedRequest

Express request containing validated query parameters.

res Response

Express response used to return the investigations list and pagination metadata.

View Source controllers/investigation.controller.js, line 126

Resolves when the response has been sent.

Promise.<void>

# async static redoInvestigation(req, res, _next) → {Promise.<void>}

Redo an investigation.

Parameters:
Name Type Description
req IAuthenticatedRequest

Express request with the investigation identifier to redo.

res Response

Express response used to return the redone investigation.

_next NextFunction

Express next function (unused).

View Source controllers/investigation.controller.js, line 624

Resolves when the response has been sent.

Promise.<void>

# async static regenerateOtherFields(req, res, _next) → {Promise.<void>}

Regenerate other fields based on a specific field.

Parameters:
Name Type Description
req IAuthenticatedRequest

Express request containing investigation ID and field name.

res Response

Express response used to return the updated investigation.

_next NextFunction

Express next function (unused).

View Source controllers/investigation.controller.js, line 733

Resolves when the response has been sent.

Promise.<void>

# async static resolveContradiction(req, res, _next) → {Promise.<void>}

Resolve contradiction.

Parameters:
Name Type Description
req IAuthenticatedRequest

Express request with the investigation identifier to redo.

res Response

Express response used to return the investigation with resolved contradiction.

_next NextFunction

Express next function (unused).

View Source controllers/investigation.controller.js, line 664

Resolves when the response has been sent.

Promise.<void>

# async static undoInvestigation(req, res, _next) → {Promise.<void>}

Undo an investigation.

Parameters:
Name Type Description
req IAuthenticatedRequest

Express request with the investigation identifier to undo.

res Response

Express response used to return the undone investigation.

_next NextFunction

Express next function (unused).

View Source controllers/investigation.controller.js, line 584

Resolves when the response has been sent.

Promise.<void>

# async static updateInvestigation(req, res, _next) → {Promise.<void>}

Update an investigation.

Parameters:
Name Type Description
req IUpdateInvestigationRequest

Express request with update payload and params.

res Response

Express response used to return the updated investigation.

_next NextFunction

Express next function (unused).

View Source controllers/investigation.controller.js, line 251

Resolves when the response has been sent.

Promise.<void>