Skip to content

feat: add editing support for citext data type in table editor#17666

Merged
ivasilov merged 8 commits intosupabase:masterfrom
kishanhitk:add-support-for-editing-citext-type-columns
Sep 29, 2023
Merged

feat: add editing support for citext data type in table editor#17666
ivasilov merged 8 commits intosupabase:masterfrom
kishanhitk:add-support-for-editing-citext-type-columns

Conversation

@kishanhitk
Copy link
Copy Markdown
Contributor

What kind of change does this PR introduce?

feature

What is the current behavior?

Columns of citext are not editable, as the current logic assumes it to be an enum.

image

Fixes: #17451

What is the new behavior?

Columns of citext are treated as text columns, and are editable as text.

image

Additional context

@vercel
Copy link
Copy Markdown

vercel bot commented Sep 23, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 29, 2023 10:47am
studio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 29, 2023 10:47am
studio-self-hosted ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 29, 2023 10:47am
studio-staging ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 29, 2023 10:47am
zone-www-dot-com ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 29, 2023 10:47am
1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
ui-storybook ⬜️ Ignored (Inspect) Visit Preview Sep 29, 2023 10:47am

@vercel
Copy link
Copy Markdown

vercel bot commented Sep 23, 2023

@kishanhitk is attempting to deploy a commit to the Supabase Team on Vercel.

A member of the Team first needs to authorize it.

@kishanhitk kishanhitk marked this pull request as ready for review September 23, 2023 07:29
@kishanhitk kishanhitk requested a review from a team as a code owner September 23, 2023 07:29
Copy link
Copy Markdown
Member

@ivasilov ivasilov left a comment

Choose a reason for hiding this comment

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

hey @kishanhitk, instead of expanding isTextColumn, can you define a new function isCiTextColumn and add in the if-else chain beneath isTextColumn? I think that approach is clearer.

@kishanhitk
Copy link
Copy Markdown
Contributor Author

kishanhitk commented Sep 25, 2023

Thanks @ivasilov,
I have made the suggested changes. I also added citext as one of the possible types in ColumnType.
Does it look good now?

@ivasilov
Copy link
Copy Markdown
Member

@kishanhitk Thank you for your contribution. Merging.

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.

Editing of citext field in studio broken

2 participants