twenty/packages
Baptiste Devessier e49acae851
Visualize Workflows (#6697)
## Features

- Fetch a workflow and display it in a tree with the React Flow library
- The nodes are positioned by an algorithm
- The feature is put behind a feature flag. The `/workflow/:id` route is
disabled if the flag is off.
- I started implementing a right drawer. That's a big WIP and it will be
finished in another PR.

## How to test this feature

1. Create a workflow instance in the database through a GraphQL query.
See below for instructions.
2. After enabling the feature flag, you should be able to see the
workflow you created in the workflows list. To visualize the workflow,
go to the `/workflow/:id` page where the id is the id of the workflow.
See the video for a quick way to do so.

```gql
// First
mutation createWorkflow($data: WorkflowCreateInput!) {
  createWorkflow(data: $data) {
    id
  }
}

// Result
{
  "data": {
    "name": "test"
  }
}

// Second
mutation createWorkflowVersion($data: WorkflowVersionCreateInput!) {
  createWorkflowVersion (data: $data) {
    id
  }
}

// Result
{
  "data": {
    "name": "v1",
    "trigger": {
  "name": "trigger",
"displayName": "New or Updated Row",
"type": "DATABASE_EVENT",
"settings": {
"eventName": "company.created",
"triggerName": "Company Created"
},
  "nextAction": {
    "name": "step_1",
    "displayName": "Code",
    "type": "CODE",
    "valid": true,
    "settings": {
      "serverlessFunctionId": "function_id",
      "errorHandlingOptions": {
        "retryOnFailure": {
          "value": false
        },
        "continueOnFailure": {
          "value": false
        }
      }
    }
  }
},
"workflowId": "workflow_id"
  }
}
```


https://github.com/user-attachments/assets/42bbd98c-5e13-447c-9307-461a18ac2195
2024-08-23 17:50:13 +02:00
..
twenty-chrome-extension Improve performance twenty orm (#6691) 2024-08-20 19:42:02 +02:00
twenty-docker Lumosviridi v20 kubernetes updates (#6356) 2024-08-08 13:55:45 +02:00
twenty-e2e-testing feat(e2e): twenty-e2e-testing with playwright (#6539) 2024-08-14 17:23:32 +02:00
twenty-emails Bump version to 0.23.2 2024-08-21 15:39:55 +02:00
twenty-front Visualize Workflows (#6697) 2024-08-23 17:50:13 +02:00
twenty-postgres Upgrade pg graphql version to 1.5.6 (#5937) 2024-06-18 17:34:16 +02:00
twenty-server Fix serverless save when name empty (#6720) 2024-08-23 17:34:31 +02:00
twenty-ui Visualize Workflows (#6697) 2024-08-23 17:50:13 +02:00
twenty-utils Fix docs build in CI (#5826) 2024-06-11 19:06:37 +02:00
twenty-website Bump version to 0.23.2 2024-08-21 15:39:55 +02:00
twenty-zapier [Fix] Remove usage of deprecated FieldMetadata type probability (#6279) 2024-07-16 11:36:10 +02:00