quasar icon indicating copy to clipboard operation
quasar copied to clipboard

[Request] Datetime Range: fixed-range prop

Open spectrolite opened this issue 9 years ago • 2 comments

Following #640 this is a request with a larger scope

Extend the Datetime Range component UI to accept a fixed-range prop, that automatically sets to = from + fixedRange as soon as the start date is picked. Obviously we'd like range-size to take any arbitrary or even dynamic value.

spectrolite avatar Jul 28 '17 14:07 spectrolite

this gitter excerpt contains some useful info on this and the related #759 ... Laurent @spectrolite 16:22 @JCharante fortnight :fixed-range=14 atm i assume fixed-range would take its value in days but really it should be able to take hours or minutes or weeks as well

John @JCharante 16:24 @spectrolite so :fixed-range=“14d"

Laurent @spectrolite 16:24 i actually don’t see any unit i would not include, from minutes to years.

John @JCharante 16:24 but for fortnight support, you have to specify the starting day of week but how do you know if the fortnight started on the recent fooday, or the past fooday?

Laurent @spectrolite 16:25 u make a good point, short codes would be useful too

John @JCharante 16:28 weeks are special in the sense that it has a day of the week to start on, but for any other unit of time you can't specify a day of the week to start on, so you would have to do specify an origin point, and then the datetime picker would have to calculate the ranges based off of the origin point

Laurent @spectrolite 16:28 ms s m h d w y (1. month clashes with min, and 2. a month does not really define a precise time) ...

spectrolite avatar Jul 28 '17 15:07 spectrolite

This is obsolete as of v0.15. Datetime ranges can be fully customised by using two QDatetimes side by side.

rstoenescu avatar Mar 03 '18 03:03 rstoenescu