Announcement
Collapse
No announcement yet.
X
-
We've documented DateUtil.getDayNames() and corrected the framework default value for dayNames, which did indeed have 8 entries (since 2013!) - however, note that dayNames should never be set to 8 entries at runtime, because the framework should always load a locale, and the locale files set it to an array of 7 values.
-
isc.DateUtil.dayNames array has 8 entries? Sunday is duplicated.
UPDATE to the original posting below:
OK, so we discovered that we can achieve the behaviour that we wanted, including ui language translation, by calling the function:
Code:isc.DateUtil.getDayNames()
https://smartclient.com/smartclient-...eUtil.dayNames
Ideally, the Reference could be updated but that's a just a little detail.
Thanks
modules-debug\ISC_Core.js
Version v13.0p_2023-12-06/LGPL Development Only (2023-12-06)
Line: 22204
Code:dayNames: ["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],
Is this in error or "by design"?
These names also remain in English, even when the SmartClient UI is running under another language (ie when other descriptors in the SmartClient library are showing in a different language). Again, is this as expected?
We have some custom functionality showing a days-of-the-week selector, so it would be neat and tidy to use dayNames for that.
Many thanks
Last edited by DaveC; 31 May 2024, 05:43. Reason: We have found a solution to the problem ourselves, using the un-documented isc.DateUtil.getDayNames()Tags: None
Leave a comment: