User header instead of columnlayout to better add widgets to top of listview.

This commit is contained in:
2020-07-23 14:48:51 -04:00
parent edb48c6802
commit 51d3945c0b

View File

@@ -272,23 +272,26 @@ Kirigami.ApplicationWindow {
router.pushRoute({"route": "addrecord", "data": serviceId});
}
}
/*Layouts.ColumnLayout {
anchors.fill: parent
ListView {
id: serviceView
Layouts.Layout.fillHeight: true
Layouts.Layout.fillWidth: true
model: recordModel
headerPositioning: ListView.OverlayHeader
header: Kirigami.ListSectionHeader {
z: 9997
contentItem: Layouts.ColumnLayout {
Kirigami.InlineMessage {
Layouts.Layout.fillWidth: true
Layouts.Layout.leftMargin: 10
Layouts.Layout.rightMargin: 10
z: 9997
type: Kirigami.MessageType.Information
id: oilMessage
showCloseButton: false
Component.onCompleted: {
//TODO: check if oil change is needed.
}
}*/
ListView {
id: serviceView
model: recordModel
}
}
}
delegate: Kirigami.SwipeListItem {
contentItem: Layouts.ColumnLayout {
Kirigami.Heading {
@@ -327,7 +330,6 @@ Kirigami.ApplicationWindow {
]
}
}
//}
}
}
}