-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding update / delete / find actions Update and delete are not really different than creation. Find uses the same logique as for graphql filters. Expected formats are: Filter ``` { "and": [ { "name": { "eq": "salut" } }, { "employees": { "eq": "0" } } ] } ``` Order `[ { "name": 'AscNullsFirst' } ]`
- Loading branch information
Showing
6 changed files
with
313 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
...workflow-executor/workflow-actions/record-crud/exceptions/record-crud-action.exception.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import { CustomException } from 'src/utils/custom-exception'; | ||
|
||
export class RecordCRUDActionException extends CustomException { | ||
code: RecordCRUDActionExceptionCode; | ||
constructor(message: string, code: RecordCRUDActionExceptionCode) { | ||
super(message, code); | ||
} | ||
} | ||
|
||
export enum RecordCRUDActionExceptionCode { | ||
INVALID_REQUEST = 'INVALID_REQUEST', | ||
RECORD_NOT_FOUND = 'RECORD_NOT_FOUND', | ||
} |
5 changes: 4 additions & 1 deletion
5
...ules/workflow/workflow-executor/workflow-actions/record-crud/record-crud-action.module.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,12 @@ | ||
import { Module } from '@nestjs/common'; | ||
|
||
import { ScopedWorkspaceContextFactory } from 'src/engine/twenty-orm/factories/scoped-workspace-context.factory'; | ||
import { WorkspaceCacheStorageModule } from 'src/engine/workspace-cache-storage/workspace-cache-storage.module'; | ||
import { RecordCRUDWorkflowAction } from 'src/modules/workflow/workflow-executor/workflow-actions/record-crud/record-crud.workflow-action'; | ||
|
||
@Module({ | ||
providers: [RecordCRUDWorkflowAction], | ||
imports: [WorkspaceCacheStorageModule], | ||
providers: [RecordCRUDWorkflowAction, ScopedWorkspaceContextFactory], | ||
exports: [RecordCRUDWorkflowAction], | ||
}) | ||
export class RecordCRUDActionModule {} |
Oops, something went wrong.