mistic100 / mistic100/jQuery-QueryBuilder
chosen-selectpicker + unique-filter = javascript error
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 1.7k
- Forks
- 544
- PR merge metrics
- No merged PRs in 30d
Description
I started using QueryBuilder as a starting point for a custom control I am working on.
It's working great and I have been able to do most of what I hoped, however I justed noticed a problem with using
chosen-selectpicker + unique-filter
I created a little demo (based on someone elses demo) to illustrate the problem.
https://codepen.io/jakeb16/pen/bGLRjPQ
If you click "add a rule:" then change the first rule Name to Category (you shouldn’t even be able to do this since category is marked as unique)
You get the JavaScript error (Uncaught UndefinedFilterError: Undefined filter "null")
If you remove the chosen-selectpicker plugin it works fine.
I'll look and see if I can figure out what's causing this but thought I would post to see if anyone else has an idea.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the CodePen reproduction and compare the behavior with and without the chosen-selectpicker plugin. Trace how the unique-filter handles changing the first rule to Category, then verify that the JavaScript error is gone and Category cannot be selected when the fix is complete.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, jquery
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100