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

Support Emails and Phones in Spreadsheet import #7312

Merged
merged 2 commits into from
Sep 28, 2024
Merged

Conversation

charlesBochet
Copy link
Member

This is a fast follow on v0.30 release:

  • removing phone (deprecated PHONE field type) search from command menu. I could have replaced it by a phone (PHONES field type) search but as we are about to release the new search in v0.31 it does not seem to worse the investment
  • supporting EMAILS and PHONES field types in spreadsheet import

Note: while working on Spreadsheet import I found the code quite complex and with areas having duplicated code. It does not seem to be a high priority as I was able to maintain it at a low cost but it's not a peaceful code surface to navigate!

@charlesBochet charlesBochet merged commit c2a8cd0 into main Sep 28, 2024
5 of 9 checks passed
@charlesBochet charlesBochet deleted the v0.30-patch branch September 28, 2024 14:11
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

This PR enhances spreadsheet import functionality by adding support for EMAILS and PHONES field types, while also removing deprecated phone search from the command menu.

  • Added support for EMAILS and PHONES in CompositeFieldImportLabels.ts and useBuildAvailableFieldsForImport.ts
  • Updated buildRecordFromImportedStructuredRow.ts to process email and phone data during import
  • Removed 'phone' filter from people search in CommandMenu.tsx
  • Added TODO in sanitizeRecordInput.ts for implementing field value validation
  • Identified potential for code refactoring in spreadsheet import functionality to reduce complexity and duplication

5 file(s) reviewed, 1 comment(s)
Edit PR Review Bot Settings

@@ -155,6 +156,42 @@ export const useBuildAvailableFieldsForImport = () => {
fieldMetadataItem.label,
),
});
} else if (fieldMetadataItem.type === FieldMetadataType.Emails) {
Copy link
Contributor

Choose a reason for hiding this comment

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

style: Consider extracting this repeated logic into a separate function to reduce duplication

harshit078 pushed a commit to harshit078/twenty that referenced this pull request Oct 14, 2024
This is a fast follow on v0.30 release:
- removing phone (deprecated PHONE field type) search from command menu.
I could have replaced it by a phone (PHONES field type) search but as we
are about to release the new search in v0.31 it does not seem to worse
the investment
- supporting EMAILS and PHONES field types in spreadsheet import

Note: while working on Spreadsheet import I found the code quite complex
and with areas having duplicated code. It does not seem to be a high
priority as I was able to maintain it at a low cost but it's not a
peaceful code surface to navigate!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant