-
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.
- Loading branch information
Showing
28 changed files
with
193 additions
and
149 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
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
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
2 changes: 1 addition & 1 deletion
2
...nty-server/src/modules/workflow/workflow-executor/interfaces/workflow-action.interface.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
40 changes: 0 additions & 40 deletions
40
packages/twenty-server/src/modules/workflow/workflow-executor/types/workflow-action.type.ts
This file was deleted.
Oops, something went wrong.
48 changes: 0 additions & 48 deletions
48
...twenty-server/src/modules/workflow/workflow-executor/types/workflow-step-settings.type.ts
This file was deleted.
Oops, something went wrong.
12 changes: 12 additions & 0 deletions
12
...server/src/modules/workflow/workflow-executor/workflow-actions/code/code-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 |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import { Module } from '@nestjs/common'; | ||
|
||
import { ServerlessFunctionModule } from 'src/engine/metadata-modules/serverless-function/serverless-function.module'; | ||
import { ScopedWorkspaceContextFactory } from 'src/engine/twenty-orm/factories/scoped-workspace-context.factory'; | ||
import { CodeWorkflowAction } from 'src/modules/workflow/workflow-executor/workflow-actions/code/code.workflow-action'; | ||
|
||
@Module({ | ||
imports: [ServerlessFunctionModule], | ||
providers: [ScopedWorkspaceContextFactory, CodeWorkflowAction], | ||
exports: [CodeWorkflowAction], | ||
}) | ||
export class CodeActionModule {} |
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
7 changes: 7 additions & 0 deletions
7
...workflow/workflow-executor/workflow-actions/code/types/workflow-code-action-input.type.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,7 @@ | ||
export type WorkflowCodeActionInput = { | ||
serverlessFunctionId: string; | ||
serverlessFunctionVersion: string; | ||
serverlessFunctionInput: { | ||
[key: string]: any; | ||
}; | ||
}; |
6 changes: 6 additions & 0 deletions
6
...kflow/workflow-executor/workflow-actions/code/types/workflow-code-action-settings.type.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,6 @@ | ||
import { WorkflowCodeActionInput } from 'src/modules/workflow/workflow-executor/workflow-actions/code/types/workflow-code-action-input.type'; | ||
import { BaseWorkflowActionSettings } from 'src/modules/workflow/workflow-executor/workflow-actions/types/workflow-action-settings.type'; | ||
|
||
export type WorkflowCodeActionSettings = BaseWorkflowActionSettings & { | ||
input: WorkflowCodeActionInput; | ||
}; |
4 changes: 4 additions & 0 deletions
4
.../workflow/workflow-executor/workflow-actions/create-record/create-record-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 |
---|---|---|
@@ -0,0 +1,4 @@ | ||
import { Module } from '@nestjs/common'; | ||
|
||
@Module({}) | ||
export class CreateRecordActionModule {} |
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
6 changes: 6 additions & 0 deletions
6
...executor/workflow-actions/create-record/types/workflow-create-record-action-input.type.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,6 @@ | ||
type ObjectRecord = Record<string, any>; | ||
|
||
export type WorkflowCreateRecordActionInput = { | ||
objectName: string; | ||
objectRecord: ObjectRecord; | ||
}; |
6 changes: 6 additions & 0 deletions
6
...cutor/workflow-actions/create-record/types/workflow-create-record-action-settings.type.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,6 @@ | ||
import { WorkflowCreateRecordActionInput } from 'src/modules/workflow/workflow-executor/workflow-actions/create-record/types/workflow-create-record-action-input.type'; | ||
import { BaseWorkflowActionSettings } from 'src/modules/workflow/workflow-executor/workflow-actions/types/workflow-action-settings.type'; | ||
|
||
export type WorkflowCreateRecordActionSettings = BaseWorkflowActionSettings & { | ||
input: WorkflowCreateRecordActionInput; | ||
}; |
8 changes: 4 additions & 4 deletions
8
...ender/exceptions/mail-sender.exception.ts → ...exceptions/send-email-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 |
---|---|---|
@@ -1,13 +1,13 @@ | ||
import { CustomException } from 'src/utils/custom-exception'; | ||
|
||
export class MailSenderException extends CustomException { | ||
code: MailSenderExceptionCode; | ||
constructor(message: string, code: MailSenderExceptionCode) { | ||
export class SendEmailActionException extends CustomException { | ||
code: SendEmailActionExceptionCode; | ||
constructor(message: string, code: SendEmailActionExceptionCode) { | ||
super(message, code); | ||
} | ||
} | ||
|
||
export enum MailSenderExceptionCode { | ||
export enum SendEmailActionExceptionCode { | ||
PROVIDER_NOT_SUPPORTED = 'PROVIDER_NOT_SUPPORTED', | ||
CONNECTED_ACCOUNT_NOT_FOUND = 'CONNECTED_ACCOUNT_NOT_FOUND', | ||
} |
17 changes: 17 additions & 0 deletions
17
...dules/workflow/workflow-executor/workflow-actions/mail-sender/send-email-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 |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import { Module } from '@nestjs/common'; | ||
|
||
import { ScopedWorkspaceContextFactory } from 'src/engine/twenty-orm/factories/scoped-workspace-context.factory'; | ||
import { OAuth2ClientManagerModule } from 'src/modules/connected-account/oauth2-client-manager/oauth2-client-manager.module'; | ||
import { GmailClientProvider } from 'src/modules/messaging/message-import-manager/drivers/gmail/providers/gmail-client.provider'; | ||
import { SendEmailWorkflowAction } from 'src/modules/workflow/workflow-executor/workflow-actions/mail-sender/send-email.workflow-action'; | ||
|
||
@Module({ | ||
imports: [OAuth2ClientManagerModule], | ||
providers: [ | ||
GmailClientProvider, | ||
ScopedWorkspaceContextFactory, | ||
SendEmailWorkflowAction, | ||
], | ||
exports: [SendEmailWorkflowAction], | ||
}) | ||
export class SendEmailActionModule {} |
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
6 changes: 6 additions & 0 deletions
6
...flow-executor/workflow-actions/mail-sender/types/workflow-send-email-action-input.type.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,6 @@ | ||
export type WorkflowSendEmailActionInput = { | ||
connectedAccountId: string; | ||
email: string; | ||
subject?: string; | ||
body?: string; | ||
}; |
6 changes: 6 additions & 0 deletions
6
...w-executor/workflow-actions/mail-sender/types/workflow-send-email-action-settings.type.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,6 @@ | ||
import { WorkflowSendEmailActionInput } from 'src/modules/workflow/workflow-executor/workflow-actions/mail-sender/types/workflow-send-email-action-input.type'; | ||
import { BaseWorkflowActionSettings } from 'src/modules/workflow/workflow-executor/workflow-actions/types/workflow-action-settings.type'; | ||
|
||
export type WorkflowSendEmailActionSettings = BaseWorkflowActionSettings & { | ||
input: WorkflowSendEmailActionInput; | ||
}; |
File renamed without changes.
Oops, something went wrong.