-
Notifications
You must be signed in to change notification settings - Fork 272
Add Select (dropdown) column type to tables #602
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Dev -> Main - Bugfixes
|
Name | Link |
---|---|
🔨 Latest commit | 1cd00c2 |
FalkWolsky
FalkWolsky
previously approved these changes
Jan 8, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you million times! What a valuable contribution!
@FalkWolsky
FalkWolsky
dismissed
their stale review
January 8, 2024 16:20
The base branch was changed.
👷 Deploy request for lowcoder-test pending review.Visit the deploys page to approve it
|
FalkWolsky
FalkWolsky
approved these changes
Jan 8, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you very much for this valuable contribution!!
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.
Hello! I've been playing around with Lowcoder, and I wanted to have dropdowns in editable table columns, as requested in #412. I couldn't find it, so I quickly threw this together.
Let me know if any more changes are needed! I tried to touch similar files to those touched by d92f917, which added the Number column type, so hopefully not too many things have been forgotten.
Proposed changes
This PR adds a new Select column type to tables. It's specifically intended to allow inline edits to present a dropdown so users get some guidance on the allowed values, instead of a simple text field.
Example: the following screenshots show a Table component with its standard data (10 users with an ID, name, date and department). However, the Department column (which is usually a Text column) has been changed to a Select column and marked as Editable:
image
image
When editing a user's Department (by double-clicking that cell), it transforms into a dropdown:
image
Of course, clicking on the dropdown displays the available choices:
image
Once a different choice has been selected (and the cell unfocused), the cell is marked as having pending changes:
image
Saving the table emits an event which has the changed cell as part of the table's
changeSet
, where it would be handled as any other change. This notification is triggered on the Save Changes event of the table, and it prints{{table.changeSet}}
:image
Types of changes
Checklist