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

System-wide dynamic search fields #2711

Open
7 tasks
adrianthedev opened this issue Apr 21, 2024 · 6 comments
Open
7 tasks

System-wide dynamic search fields #2711

adrianthedev opened this issue Apr 21, 2024 · 6 comments
Labels
Back end DSL-related Enhancement Not necessarily a feature, but something has improved Field Front end Stale exempt

Comments

@adrianthedev
Copy link
Collaborator

adrianthedev commented Apr 21, 2024

Feature

We need a better story around searchable, and dynamic "multi-select" fields.

Places we need to think about this

Possible solutions

Related issues

Current workarounds

Using the tags field or a custom one.

@adrianthedev adrianthedev changed the title Searchable belongs_to as a default option System-wide dynamic search fields Apr 21, 2024
Copy link
Contributor

This issue has been marked as stale because there was no activity for the past 15 days.

@github-actions github-actions bot added the Stale label May 10, 2024
@Paul-Bob Paul-Bob removed the Stale label May 10, 2024
Copy link
Contributor

This issue has been marked as stale because there was no activity for the past 15 days.

@rctneil
Copy link
Contributor

rctneil commented Jul 8, 2024

@adrianthedev Thanks for merging my suggestion with this one.

I did have a go at using the tags field last night instead of text, but was getting an error and i think it was to do with it having trouble joining the value from the database with the array of suggestions from my model method.

Not got any code on me right now but i'll look this evening and post a complete issue if needed, but if you have any suggestions for how to use the tags field instead of text to allow a suggestion list that would be incredible!

@adrianthedev
Copy link
Collaborator Author

I don't have a tutorial but that's achievable using mode: :select and fetch_values_from.

@rctneil
Copy link
Contributor

rctneil commented Jul 8, 2024

Ah, I don't think i can use that as it looks to save the value as an id. I need to keep the text field as a text field storing it as a text value, but with an auto-complete or auto suggestion of other values in the same field on other records.

@Paul-Bob
Copy link
Contributor

Paul-Bob commented Jul 9, 2024

update_using helps in this scenario, you can format the input before it's saved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Back end DSL-related Enhancement Not necessarily a feature, but something has improved Field Front end Stale exempt
Projects
Status: No status
Development

No branches or pull requests

3 participants