summaryrefslogtreecommitdiff
path: root/res/gui/EventInfoPage.qml
diff options
context:
space:
mode:
authorOrangerot <purple@orangerot.dev>2024-08-16 23:40:38 +0200
committerOrangerot <purple@orangerot.dev>2024-08-16 23:40:38 +0200
commitb93da90caecc1f7c5ab5c187f508af4d9ceac070 (patch)
treeadf8f10708ea066584989cad2605f80d7e3d8c2f /res/gui/EventInfoPage.qml
parent100e73ec28dbc1f307c540cbd4b5a04dfe5922f8 (diff)
fix(EventInfoPage): show comptitor statisticssteru-backend
Diffstat (limited to 'res/gui/EventInfoPage.qml')
-rw-r--r--res/gui/EventInfoPage.qml30
1 files changed, 20 insertions, 10 deletions
diff --git a/res/gui/EventInfoPage.qml b/res/gui/EventInfoPage.qml
index 6c46a7f..2934931 100644
--- a/res/gui/EventInfoPage.qml
+++ b/res/gui/EventInfoPage.qml
@@ -4,8 +4,8 @@ import QtQuick.Controls
Page {
id: root
- property string eventName
- property list<QtObject> competitors
+ required property string eventName
+ required property list<QtObject> competitors
header: ToolBar {
ToolButton {
@@ -31,17 +31,27 @@ Page {
bottomMargin: 48
rightMargin: 48
spacing: 20
- model: eventName
+ model: competitors
delegate: ItemDelegate {
- text: "sadly not working..."
+ required property string name
+ required property string noc
+ required property string mark
+ required property string statistic
+ required property string gold
+ required property string silver
+ required property string bronze
width: listView.width - listView.leftMargin - listView.rightMargin
- height: avatar.implicitHeight + 32
- leftPadding: avatar.implicitWidth + 32
-
- Image {
- id: avatar
- // source: "images/" + modelData.replace(" ", "_") + ".png"
+ height: 32
+ Text {
+ anchors.left: parent.left
+ text: name + " (" + noc + ")"
+ }
+ Text {
+ anchors.right: parent.right
+ horizontalAlignment: Text.AlignRight
+ text: mark + " " + statistic + " | " + gold + "🥇 " + silver + "🥈 " + bronze + "🥉"
}
+
}
}