Problem with date time variable

Stimulsoft Reports.JS discussion
Post Reply
peter.sulo
Posts: 11
Joined: Thu Jun 20, 2024 2:33 pm

Problem with date time variable

Post by peter.sulo »

Hello, I have found a problem when selecting date from date picker.
Version: 2024.3.5
OS: Windows
Web browser (Chrome, Edge, Firefox) language: Czech

I have attached simple demo.
On the first run of report, everything works fine, the date displayed is the same as in date picker.
screenshot_ok.png
screenshot_ok.png (16.33 KiB) Viewed 2990 times
When the date or time in date picker is changed and the time is > 12:00, it is displayed incorrectly in the report. It shows 12 hours less.
screenshot_error.png
screenshot_error.png (16.36 KiB) Viewed 2990 times
It happens only if web browser's language is Czech. In other languages like English, Slovak it works OK.

Thank you for quick fix.
Attachments
Report.mrt
(1.55 KiB) Downloaded 212 times
Max Shamanov
Posts: 975
Joined: Tue Sep 07, 2021 10:11 am

Re: Problem with date time variable

Post by Max Shamanov »

Hello,

We require more time to investigate the issue thoroughly.
We will let you know when we get any result.

Thank you.
Max Shamanov
Posts: 975
Joined: Tue Sep 07, 2021 10:11 am

Re: Problem with date time variable

Post by Max Shamanov »

Hello,

The best solution to display the date in all browsers and with the same time is to specify the localisation of the report.
Specify the Culture-Czech property and the time will always be displayed the same way, regardless of browser settings.

Thank you.
Attachments
Report (49).mrt
(2.62 KiB) Downloaded 208 times
peter.sulo
Posts: 11
Joined: Thu Jun 20, 2024 2:33 pm

Re: Problem with date time variable

Post by peter.sulo »

Hello,

I tested the example you provided, but it behaves the same.
After initial load of the report, the date is displayed correctly.
screen1.png
screen1.png (16.67 KiB) Viewed 2892 times
Then I changed time to 18:13:16 and the display is wrong.
screen2.png
screen2.png (16.5 KiB) Viewed 2892 times
It is even more visible when culture of the report is set to English. The displayed value is 6:13:16 AM instead of PM.
screen3.png
screen3.png (16.94 KiB) Viewed 2892 times
This happens only if those mentioned browsers are in Czech language regardless of report's culture.
It's not only matter of display.
I have also tried using the variable as a parameter in sql query and it behaves the same. Instead of PM I get AM value and result of query is wrong.
Max Shamanov
Posts: 975
Joined: Tue Sep 07, 2021 10:11 am

Re: Problem with date time variable

Post by Max Shamanov »

Hello,

We require more time to investigate the issue thoroughly.
We will let you know when we get any result.

Thank you.
Max Shamanov
Posts: 975
Joined: Tue Sep 07, 2021 10:11 am

Re: Problem with date time variable

Post by Max Shamanov »

Hello.

We have reproduced the issue and need some time to make an improvement.
We will let you know when we get any results.

Thank you.
#15503
Max Shamanov
Posts: 975
Joined: Tue Sep 07, 2021 10:11 am

Re: Problem with date time variable

Post by Max Shamanov »

Hello.

We have made an improvement.
Please, check our next build when it will be available.

Thank you.
Post Reply