-
Notifications
You must be signed in to change notification settings - Fork 284
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
custom_func with input(datepicker) instead of select #409
Comments
custom_func was design for single column search, but now when I think of it you can use the third argument |
Thanks for the quick reply! I was planning of using the rowValues. the problem I face when using the 'custom_func' is there is no option of any other arguments beside the select-box while I need an input field - which i can configure as datepicker. For example, if a user wants to search the date '30/08/2017' the date will then be evaluated for each row in the table to see if it falls between any pair of dates e.g. 20/08/2017 & 26/09/2017 = true. i simple cant provide the user with a input field to select the date '30/08/2017' as the auto-generated select-box most probably have '20/08/2017' as an option which result in false. Maybe i miss something about the option of providing the argument from another field. |
my question to you is - does the |
Perfect! will give a try now and let you know. Nevertheless, it would be great to see a single datepicker that search between two columns with dates, thanks again! |
Update. Unfortunately i was unable to specific the function from inside datepicker 'onSelect' as it missing the needed arguments (columnVal, rowValues) while inti i use the following code: yadcf.init(t, [{ Now if i use these settings with datepicker option: It is expected that the data in 'columnVal' & 'rowValues' is empty \ not exist. |
@THPUG that wasn't what I meant, never mind, I will try to add the date_custom_func filter |
Thanks @vedmack. I will be happy to understand what you meant to do as im using you plugin a lot - knowing its true capabilities will be very helpful. |
…tion, filter_type: "date_custom_func", #409
filter_type: "date_custom_func" @0.9.2.beta.13 , go party and let me know if something is missing... |
Hi Daniel, thank you very much for your affort! I got this error message when trying to init the new filter: Of course i've garbed the new version 0.9.2.beta.13. UPDATE 1. UPDATE 2. |
Wanted to share my solution with everyone in case you need it: The bellow code will add a filter container, init the yadcf plugin & evaluate column 0 VS 1 //date range search container //Init yadcf (t = my datatable)
|
Found another bug in this version. After initial the first time using: filter_type: "date_custom_func" - next datatable im loading regardless the use of yadcf will not load with error:
|
@THPUG please provide a test case (page) for the "another bug" |
I am also encountering this bug! It appears when I use 'date_range'. It does not appear with the other types of filters |
Im currently using only 'date_range' & 'date_custom_func'. Moreover, when trying to clear the datepicker input using the 'x' button - nothing occur. |
Hi @vedmack Do you know when this gonna be fixed? |
@THPUG fix for the reset button will be committed in the following days, as to the other issues - I will be able to help you only after test case |
Thanks for a great tool! we use a lot in our project!
I want to implement a custom function where a single input (datepicker) will evaluate if the given date is between 2 dates which are in 2 different columns in my table.
If true - only the rows where the given date is between will be shown.
Unfortunately the only form element available is auto-generated box.
The text was updated successfully, but these errors were encountered: