You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Click any predefined ranges after the datepicker loaded. Suppose it was RESET.
Now make a custom selection of date. You will see that chosenLabel equals RESET. The property for some reason stores the value from previous selection. It is not logical. I'm making a brand new custom range selection, but the property is equal previous selection. This is what I don't expect and my code on custom date selection gives wrong result because of that.
How to reset chosenLabel on every new apply event? Or at least how to set chosenLabel to null on custom range selection, so that it is reset from previous value?
Or even more specifically: How to figure out that a custom date range is selected at the moment, not a preset? Because as you just saw, checking chosenLabel gives wrong result.
The text was updated successfully, but these errors were encountered:
wzup
changed the title
Missing chosenLabel property in production after code uglify
chosenLabel property is null in production after code uglify
Jan 27, 2017
wzup
changed the title
chosenLabel property is null in production after code uglify
chosenLabel property becomes null in production after code uglify
Jan 27, 2017
wzup
changed the title
chosenLabel property becomes null in production after code uglify
chosenLabel property is not reset on new apply event and stores value of previous selection
Jan 27, 2017
How to reset
chosenLabel
on every newapply
event?Here is a use case.
Given
DateRangePicker
settings forreset
range:And
onEvent
method looks like this. Look atpicker.chosenLabel.toLowerCase()
line:Ranges:
Steps to reproduce the issue:
RESET
.chosenLabel
equalsRESET
. The property for some reason stores the value from previous selection. It is not logical. I'm making a brand new custom range selection, but the property is equal previous selection. This is what I don't expect and my code on custom date selection gives wrong result because of that.How to reset
chosenLabel
on every newapply
event? Or at least how to setchosenLabel
tonull
on custom range selection, so that it is reset from previous value?Or even more specifically:
How to figure out that a custom date range is selected at the moment, not a preset? Because as you just saw, checking
chosenLabel
gives wrong result.The text was updated successfully, but these errors were encountered: