-
Notifications
You must be signed in to change notification settings - Fork 2
Closed
Description
Overview
Create a reusable function for archiving a node. Archiving should prevent a node from being used as the start of a match in the relevant queries without requiring the deletion of the node or its relationships. This allows us to maintain history without affecting the functionality of the app.
Track as part of Falcor Route creation.
Function Signature
function (
nodeLabel : string,
nodeId : string,
userId : string
) : Observable<object>
Spec
GIVEN:
- a node in the database with no incoming relationships;
WHEN provided:
- a label on the node;
- the ID of the node to archive;
- the ID of the user performing this action;
THEN:
- the function should set the following properties on the node:
{
archived: true,
archived_at: now(),
archiver: userId,
}
WHEN:
- the node has inbound relationships;
THEN:
- the function should archive all inbound relationships per the rules of Neo4j Helper: Relationship Archiver #11.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels