Yes, by default, the Bold BI® date picker widget sets the time range from 12:00 AM of the start date to 11:30 PM of the end date.
To customize this behavior, you can use expressions in your data source to adjust the time range logic. For example, you can create a calculated field that shifts the time window based on your requirements.
Here’s a sample expression
Expression 1: (Using the date column field)
CASE
WHEN DATEPART(HOUR, [Sales_Date]) > 14 OR (DATEPART(HOUR, [Sales_Date]) = 14 AND DATEPART(MINUTE, [Sales_Date]) >= 20)
THEN DATEADD(DAY, 1, [Sales_Date])
ELSE [Sales_Date]
END
Note: Here, [Sales_Date] is the date type column in the data source.
Expression 2: (Using the current date and time)
CASE
WHEN DATEPART(HOUR, CURRENT_TIMESTAMP) > 14 OR (DATEPART(HOUR, CURRENT_TIMESTAMP) = 14 AND DATEPART(MINUTE, CURRENT_TIMESTAMP) >= 20)
THEN DATEADD(DAY, 1, CURRENT_TIMESTAMP)
ELSE CURRENT_TIMESTAMP
END
This logic checks if the time is after 2:20 PM and shifts the date accordingly. You can modify the time conditions to suit your specific range (e.g., 8:00 AM to 7:59 AM next day).