Closed samcov closed 2 years ago
That is not the way I intended it to work. It is a good idea though. To set the filter value you must use "addCondition".
Wait, if you save the 'valUrl', can you then do the following?
$('#sonarioFilter').structFilter('addCondition',"filters=1&field-0=Gender&operator-0=eq&value-0=male&label=Gender%20equals%20%22male%22%20");
It is possible but I didn't do it. You will have parse the url and generate a JSON object to pass to the method.
Can do, thanks!
BTW, was there a reason you didn't do a "<=" and ">=" for numbers?
I wanted to keep the list of operator short. Maybe I should have added it.
No problem!
Excuse my bad manners, I forgot to mention that I just love what you've done here.
Thanks for the prompt responses!
Thank you. No worry. I enjoy getting feedback on my work. Unfortunately I do not have much time to spend on my side projects right now so I can't commit to new features. Also, I moved to React in my full time job so I'm slowly forgetting my jQuery...
No problem, I can work around all of my issues... Thanks!
I get the filter url: let filterUrlFormat = $('#sonarioFilter').structFilter('valUrl');
Then I try to set the filter, but it fails to do anything: $('#sonarioFilter').structFilter('valUrl',"filters=1&field-0=Gender&operator-0=eq&value-0=male&label=Gender%20equals%20%22male%22%20");
Is there something I'm missing?