fix #LINQT-1500 date time in local time zone

This commit is contained in:
Gaelle Braud 2024-12-26 18:02:56 +01:00
parent cae5372e97
commit e42d90f9ee
2 changed files with 4 additions and 4 deletions

View file

@ -152,10 +152,10 @@ ListView {
property var itemGui: $modelData
// Do not use itemAtIndex because of caching items. Using getAt ensure to have a GUI
property var previousConfInfoGui : mainItem.model.getAt(index-1)
property var dateTime: itemGui.core ? itemGui.core.dateTimeUtc : UtilsCpp.getCurrentDateTime()
property var dateTime: itemGui.core ? itemGui.core.dateTime : UtilsCpp.getCurrentDateTime()
property string day : UtilsCpp.toDateDayNameString(dateTime)
property string dateString: UtilsCpp.toDateString(dateTime)
property string previousDateString: previousConfInfoGui ? UtilsCpp.toDateString(previousConfInfoGui.core ? previousConfInfoGui.core.dateTimeUtc : UtilsCpp.getCurrentDateTimeUtc()) : ''
property string previousDateString: previousConfInfoGui ? UtilsCpp.toDateString(previousConfInfoGui.core ? previousConfInfoGui.core.dateTime : UtilsCpp.getCurrentDateTime()) : ''
property bool isFirst : ListView.previousSection !== ListView.section
property int topOffset: (dateDay.visible && !isFirst? 8 * DefaultStyle.dp : 0)
property var endDateTime: itemGui.core ? itemGui.core.endDateTime : UtilsCpp.getCurrentDateTime()

View file

@ -718,8 +718,8 @@ AbstractMainPage {
}
Text {
text: mainItem.selectedConference
? UtilsCpp.toDateString(mainItem.selectedConference.core?.dateTimeUtc)
+ " | " + UtilsCpp.toDateHourString(mainItem.selectedConference.core?.dateTimeUtc)
? UtilsCpp.toDateString(mainItem.selectedConference.core?.dateTime)
+ " | " + UtilsCpp.toDateHourString(mainItem.selectedConference.core?.dateTime)
+ " - "
+ UtilsCpp.toDateHourString(mainItem.selectedConference.core?.endDateTime)
: ''