X-Git-Url: https://www.flypig.org.uk/git/?p=harbour-pedalo.git;a=blobdiff_plain;f=qml%2Fpages%2FJourneyList.qml;h=8c6998f0422e454b3aba131e1be6d784fce5559d;hp=9d84129e10a2630c0e8e979286aef01f30a1ac48;hb=e917baa52e7157c7c41424527c3881c22ff65588;hpb=0108947ead4cc9e0ff23fee82db2fb1fd7cb2dad diff --git a/qml/pages/JourneyList.qml b/qml/pages/JourneyList.qml index 9d84129..8c6998f 100644 --- a/qml/pages/JourneyList.qml +++ b/qml/pages/JourneyList.qml @@ -10,7 +10,7 @@ Page { SilicaListView { id: listView - model: 20 + model: journeymodel anchors.fill: parent header: PageHeader { title: qsTr("Journey list") @@ -24,17 +24,17 @@ Page { Label { width: columnwidth / 3.0 - text: qsTr("Item") + " " + index + text: Qt.formatDate(journeymodel.epochToDate(start), "d MMM yyyy") color: delegate.highlighted ? Theme.highlightColor : Theme.primaryColor } Label { width: columnwidth / 3.0 - text: qsTr("1 May 2018") + text: Qt.formatTime(journeymodel.epochToTime(start), "hh:mm") color: delegate.highlighted ? Theme.highlightColor : Theme.primaryColor } Label { width: columnwidth / 3.0 - text: qsTr("20 mins") + text: parseInt(duration / (60 * 60)) + ":" + (parseInt(duration / 60) % 60) color: delegate.highlighted ? Theme.highlightColor : Theme.primaryColor } }