Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deleting a column on google spreadsheet messes with the data #13652

Conversation

adrinr
Copy link
Collaborator

@adrinr adrinr commented May 9, 2024

Description

Currently, deleting a column deletes the header cell but not the full column. Because of this, deleting data mixes the order of the columns. We don't want to delete the data as these data might not be created by budibase. Because of this, we will only drop the BB reference but keeping the references in the actual sheet. Adding the deleted column back will backpopulate it in BB.

Also fixing a bug that allowed spamming the create/edit column submit, causing strange errors.
https://github.com/Budibase/budibase/assets/15987277/f6a6f5b5-08ec-4c99-b27e-5dc888fb49db

Addresses

App Export

  • If possible, attach an app export file along with your request template to make QA testing easier, with minimal setup.

Launchcontrol

Fixing broken data on google sheet column deletion

Copy link

linear bot commented May 9, 2024

@adrinr adrinr marked this pull request as ready for review May 9, 2024 17:58
@adrinr adrinr requested a review from a team as a code owner May 9, 2024 17:58
@adrinr adrinr requested review from samwho and mike12345567 and removed request for a team May 9, 2024 17:58
expect(sheet.setHeaderRow).toHaveBeenCalledWith(["name"])

// No undefined are sent
expect((sheet.setHeaderRow as any).mock.calls[0][0]).toHaveLength(1)
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure what this was meant to do, as it was already asserted on the previous lines

Copy link
Collaborator

@samwho samwho left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Took me a little while to get my head around why this worked but I see it now. Great PR, love the typing improvements.

@adrinr adrinr enabled auto-merge May 10, 2024 14:13
@adrinr adrinr merged commit 938e44b into master May 13, 2024
10 checks passed
@adrinr adrinr deleted the budi-8222/deleting-a-column-on-google-spreadsheet-messes-with-the-data branch May 13, 2024 11:15
@github-actions github-actions bot locked and limited conversation to collaborators May 13, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants