- Issue created by @sunlix
- 🇩🇪Germany sunlix Wesel
I digged a little bit into it.
I think the main problem is that if
custom
is the only allowed value in theduration_increments
you can't setcustom
for thedefault_duration
. It will be casted to0
because the config schema requires integer.By that in the smart_date.js the
setInitialDuration
function hide the end date and end time field.
This hiding is intended for non custom values. Butduration
can't be initially set tocustom
due to the integer casting fordefault_duration
- 🇨🇦Canada mandclu
I don't really understand the custom behaviour here. Should the widget treat "custom" as zero (for the sake of automatically calculating the end date based on the start but then allow the user to change the end to whatever they want?
- 🇩🇪Germany sunlix Wesel
Hey @mandclu,
thank you for your response.
Yes we are interpreting 'custom' as "The user choose what ever he want as end date/time".
Insmart_date
4.1 with 'custom' no end date / time calculation was done and if 'custom' was the only value provided the 'duration' field was not displayed. This was our use case with it.So yes, from my perspective, your interpretation is right. :-)