cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - When posting, your subject should be specific and summarize your question. Here are some additional tips on asking a great question. X

Date picker localisation issue

khayes1
13-Aquamarine

Date picker localisation issue

Hi,

currently experiencing an issue with localisation with the date picker. It appears that the calendar displays incorrectly in French (and possibly other languages which I haven't checked).

The issue is that the days of the week are a mismatch with the actual calendar below. The reason for this is that in French the days of the week start with Monday ('Lu') where as in English they start with Sunday ('Su'). The actual calender days are always arranged as if the first column is Sunday.

 

english.JPGfrench.JPG

Presumably there is an array of strings somewhere, but I am not able to find it to modify it. Does anyone have a solution for this, or has seen this issue also?

 

Thanks,

K

 

1 ACCEPTED SOLUTION

Accepted Solutions
khayes1
13-Aquamarine
(To:khayes1)

Okay, so I have found the localistion token which is used for the date picker short day names which can be found in the localisation tables.

token = datepickerDayNamesMin

 

some useful info can be found here

http://support.ptc.com/help/thingworx_hc/thingworx_8_hc/en/index.html#page/ThingWorx/Help/Mashup_Builder/Widgets/LocalizingtheDateTimePickerWidget.html

 

 

View solution in original post

6 REPLIES 6
slangley
23-Emerald II
(To:khayes1)

Hi @khayes1.

 

Which version of ThingWorx are you running?  We tested this on 8.4.2 and observed the expected behavior.

 

Regards.

 

--Sharon

khayes1
13-Aquamarine
(To:slangley)

Hi Sharon,

thanks for the reply. The versions that we run are 8.2.4 & 8.2.8. Maybe it has been fixed in the later versions.

 

Thanks,

K

 

khayes1
13-Aquamarine
(To:khayes1)

Okay, so I have found the localistion token which is used for the date picker short day names which can be found in the localisation tables.

token = datepickerDayNamesMin

 

some useful info can be found here

http://support.ptc.com/help/thingworx_hc/thingworx_8_hc/en/index.html#page/ThingWorx/Help/Mashup_Builder/Widgets/LocalizingtheDateTimePickerWidget.html

 

 

PEHOWE
16-Pearl
(To:khayes1)

Hello @khayes1 ,

   The link shows the documentation for “Localizing the Date Time Picker Widget”, and the configuration variable “datepickerDayNamesMin” has the short abbreviations for the days of the week starting on Sunday.

 

What is the next property setting? The “datepickerFirstDay” identifies what day is the first day of the week. What value do you have sent in your environment? To have the week start on Monday it should be set to 1.

 

khayes1
13-Aquamarine
(To:PEHOWE)

It is the zero based index (as a string 0-6) into the datepickerDayNamesMin array. You use it to set the day of the week you want the first column of the calendar part of the date picker widget to be. I think it uses the array above, but haven't checked it out, it could be done on the international standard which I think has Monday as the first day of the week.

 

eg. if your datepickerDayNamesMin  token was 'Su,Mo,Tu,We,Th,Fr,Sa' and you set your datepickerFirstDay token to '2'  the first column in your date picker calendar would be 'Tuesday' for that particular language.

khayes1
13-Aquamarine
(To:PEHOWE)

Sorry, didn't read your post correctly, thought you were asking what it was for, seems you were telling me :-)

Top Tags