Script is using here-string <<< which is not supported by sh, using bash
instead
Also removing "sh" from the command to actually use the bash from the
shebang
- In the `formatFieldMetadataValue` function, allow people to call
TypeORM's `save()` method with unserialized JSON data.
- Create an `overrideWorkflowDraftVersion` mutation that takes a
workflow id and the id of the workflow version to use as the new draft
- If no draft exists yet, create one
- If a draft already exists, deactivate its serverless functions
- Duplicate every step. For serverless function steps, it includes
duplicating the functions
- Save the data of the step in DB
- Call the `overrideWorkflowDraftVersion` mutation in the old workflow
header and in the new Cmd+K actions
- I chose to not update the Apollo cache manually as the information of
the new draft are going to be automatically fetched once the user lands
on the workflow's show page. Note that we redirect the user to this page
after overriding the draft version.
Replaced user-based parameterization with workspace-focused logic across
seed scripts, mocks, and billing services. Removed redundant `user`
references and standardized to `workspace` to align with updated
business rules. Adjusted mock data and tests to reflect these changes.
Fix https://github.com/twentyhq/twenty/issues/9295
tooltips are currently instantaneous. let's add some delay for better
user experience
After investigation, it looks like the open property prevents delays
from happening. Swithcing to hidden property
See https://discord.com/channels/1130383047699738754/1324678408684306486
- Fixed click outside for kanban not working (changed strategy)
- Tried a different approach for setting the context menu position
- Fixes https://github.com/twentyhq/twenty/issues/9336
There was a bug when selecting all records on the index page.
This was due to the fact that
`WorkflowRunRecordActionMenuEntrySetterEffect` was mounted when it
shouldn't have been.
"'TODO'" is the default value from the database and must be escaped in
the frontend. The issue was revealed by the "status" field of Tasks but
it would have been the same for the others
fix#9210
Fixes https://github.com/twentyhq/twenty/issues/8970
The context menu wasn't working because of wrong architecture with the
Dropdown component, as it's a unique behavior (no clickable component
and portal) it also required refactoring a bit the Dropdown component.
- Context menu now uses a portal
- Fixed dropdown offset without clickable component (now using a
fallback anchor component)
- Fixed React array key props
As a follow-up of https://github.com/twentyhq/twenty/pull/9304, we are
here creating a migration to run at the next release, aiming at adding
the new aggregate operation options (CountEmpty, CountNotEmpty, ...,
PercentEmpty, PercentNotEmpty) to the enums on View and ViewField's
aggregateOperations fields.
---------
Co-authored-by: Lucas Bordeau <bordeau.lucas@gmail.com>
This PR fixes all followup that @Bonapara add on Discord.
- [x] When no group by is set, clicking on group by should open the
"field selection" menu
- [x] When closed, chevron should be "chevron-right" instead of
"chevron-up"
- [x] Sort : Add ability to switch from alphabetical to manual when
moving a option in sort alphabetical
- [x] Add subtext for group by and sort
- [x] Group by menu display bug
- [x] Changing the sort should not close the menu
- [x] Group by Activation -> shows empty state + is slow
- [x] Switching from Kanban view Settings to Table Options menu displays
an empty menu
- [x] Unnecessary spacing under groups
- [x] When no "select" are set on an object, redirect the user directly
to the new Select field page
- [x] Sort : Default should be manual
- [x] Hidding "no value" displays all options and remove the "hide empty
group" toggle
- [x] Hide Empty group option disappeared
- [x] Group by should not be persisted on "Locked/Main view" (**For now
we just disable the group by on main view**)
- [x] Hide Empty group should not be activated by default on
Opportunities Kanban view
- [ ] Animate the group opening/closing (**We'll be done later**)
Performance improvement:
https://github.com/user-attachments/assets/fd2acf66-0e56-45d0-8b2f-99c62e57d6f7https://github.com/user-attachments/assets/80f1a2e1-9f77-4923-b85d-acb9cad96886
Also fix#9036
---------
Co-authored-by: Lucas Bordeau <bordeau.lucas@gmail.com>
## Context
Following this https://github.com/twentyhq/twenty/issues/4199
This has not been fully implemented, after 5months of dead code I'm
removing the feature for the time being until we re-prioritise the
feature (unlikely during these next 6 months) to keep the codebase a bit
cleaner (no need to maintain dead features)
Feel free to reopen / revert this PR once feature is ready
## Test
locally after importing emails
## Context
2 issues here:
- We use a metadata repository find method without providing a
workspaceId: In practice this is not an issue in this specific part but
let's avoid that pattern
- await this.workspaceService.deleteWorkspace(workspaceId); deletes
almost everything, emitting an event on workspaceMember could
potentially bring issues and not much values imho
### Summary
This pull request addresses the issue described in #9232, where
attempting to delete a user account results in a `TypeError: Cannot read
properties of undefined (reading 'dataSourceService')`.
### Changes Made
- Fixed the `this` context issue in the `deleteUserFromWorkspace` method
by ensuring it is correctly bound.
- Updated the `deleteUser` method to use a bound function when calling
`deleteUserFromWorkspace`.
### Linked Issue
This pull request fixes#9232.
### Additional Notes
- Please review the changes carefully to ensure no unintended side
effects in the user or workspace deletion process.
- Suggestions for further improvement are welcome.
---------
Co-authored-by: Lucas Bordeau <bordeau.lucas@gmail.com>
Co-authored-by: Weiko <corentin@twenty.com>
Closes#9260
- Refactored multiple record actions and no selection record actions to
use config file
- Simplified actions registration logic
- Updated tests
fixes#9298
fix issue where Kanban view creation text shows "Companies" instead of
current object type.
Changes:
- Made text dynamic in ViewPickerContentCreateMode
- Now displays correct object name
---------
Co-authored-by: Félix Malfait <felix@twenty.com>
The DX is not great when you need to do a lot of database
resets/command.
Should we disable Typescript validation to speed things up? With this
and caching database:reset takes 1min instead of 2 on my machine.
See also: https://github.com/typeorm/typeorm/issues/4136
And #9291 / #9293
---------
Co-authored-by: Lucas Bordeau <bordeau.lucas@gmail.com>
**Solves**
[ https://github.com/twentyhq/private-issues/issues/211 ]
**TLDR:**
Add a command that fetches the plans product, meters and price in stripe
and whrites it to the DataBase. For now it fetches only active products.
**In order to test**
- Set IS_BILLING_ENABLED=true
- Run `npx nx database:reset twenty-server` if you don't have the
billing tables in your data base schema
- run `npx nx run twenty-server:command billing:sync-plans-data -v`
---------
Co-authored-by: Félix Malfait <felix.malfait@gmail.com>
Closes#9277
## Summary of Changes
- Updated the file-download functionality to use the `saveAs` method
from the `file-saver` library, ensuring a more reliable and consistent
implementation.
- Removed redundant tests to streamline the test suite and reduce
maintenance overhead.
## Testing Performed
- [x] Verified that exporting the view to a CSV file works as expected.
fixes#9265
#### Summary
The menu options appear in black color in dark mode, making text hard to
read because there is very little contrast between text and background.
#### Solution
Added `color: ${({ theme }) => theme.font.color.secondary};` to the
dropdown menu container, so the menu options inherit the correct text
color from their containers.
### Screenshots

Set the default cache policy to 'cache-and-network' to make sure user
get more fresh data without refreshing the browser. Better for workspace
with several users working at the same time.
It will put more load on the server...
Note: I don't think the previous setting was taken into account
<img width="829" alt="Screenshot 2024-12-31 at 10 59 56"
src="https://github.com/user-attachments/assets/30ea74be-0907-422f-8e84-6c352d379337"
/>