Here are the latest changes to the core code and tests that should allow DatePicker to run smoothly.
NB: Filter interaction where the source is data in the datetime format will be implemented separately.
Relevant description
Added temporal selector DatePicker for Filter and Parameter.
DatePicker is a single model, but based on value of argument range will either return dmc.DatePicker or dmc.DateRangePicker. Default value of range is True and the model will return dmc.DateRangePicker if range is not provided, or if the selector is not defined.
Options where DateRangePicker is returned:
User does not define the Filter.selector but filter column is datetime dtype.
User defines vm.DatePicker as Filter.selector without specifying range argument or by setting range=True
Option where DatePicker is returned:
User defines vm.DatePicker as Filter.selector and sets vm.DatePickerrange argument as False.
vm.DatePicker.value supported format are all inputs that could be translated to datetime.date. See more here
Screenshot
Notice
[x] I acknowledge and agree that, by checking this box and clicking "Submit Pull Request":
I submit this contribution under the Apache 2.0 license and represent that I am entitled to do so on behalf of myself, my employer, or relevant third parties, as applicable.
I certify that (a) this contribution is my original creation and / or (b) to the extent it is not my original creation, I am authorized to submit this contribution on behalf of the original creator(s) or their licensees.
I certify that the use of this contribution as authorized by the Apache 2.0 license does not violate the intellectual property rights of anyone else.
I have not referenced individuals, products or companies in any commits, directly or indirectly.
I have not added data or restricted code in any commits, directly or indirectly.
Description
Here are the latest changes to the core code and tests that should allow DatePicker to run smoothly. NB: Filter interaction where the source is data in the datetime format will be implemented separately.
Relevant description
Added temporal selector
DatePicker
forFilter
andParameter
.DatePicker is a single model, but based on value of argument
range
will either returndmc.DatePicker
ordmc.DateRangePicker
. Default value ofrange
isTrue
and the model will returndmc.DateRangePicker
if range is not provided, or if the selector is not defined.Options where
DateRangePicker
is returned:Filter.selector
but filtercolumn
isdatetime
dtype.vm.DatePicker
asFilter.selector
without specifyingrange
argument or by settingrange=True
Option where
DatePicker
is returned:vm.DatePicker
asFilter.selector
and setsvm.DatePicker
range
argument asFalse
.vm.DatePicker.value
supported format are all inputs that could be translated todatetime.date
. See more hereScreenshot
Notice
[x] I acknowledge and agree that, by checking this box and clicking "Submit Pull Request":