Use ORM for applicants
This commit is contained in:
@@ -1,26 +1,34 @@
|
||||
import QtQuick
|
||||
import QtQuick.Controls
|
||||
import QtQuick.Layouts
|
||||
import TeroStyle
|
||||
|
||||
Item {
|
||||
property var employee
|
||||
property int row
|
||||
ColumnLayout {
|
||||
property int row: -1
|
||||
|
||||
anchors.fill: parent
|
||||
spacing: Dimensions.l
|
||||
|
||||
onRowChanged: {
|
||||
employee = employee_model.fetchApplicant(row);
|
||||
if (row !== -1) {
|
||||
applicantForm.setValue(applicantModel.applicant(row))
|
||||
}
|
||||
}
|
||||
|
||||
ColumnLayout {
|
||||
Label {
|
||||
text: qsTr("Ausgewählter Mitarbeiter ") + row
|
||||
}
|
||||
Label {
|
||||
text: employee.postcode ?? ""
|
||||
}
|
||||
Button {
|
||||
text: qsTr("Mitarbeiter zeigen")
|
||||
ApplicantForm {
|
||||
id: applicantForm
|
||||
|
||||
onClicked: contentStack.pop()
|
||||
Layout.alignment: Qt.AlignTop
|
||||
Layout.fillHeight: true
|
||||
Layout.verticalStretchFactor: 1
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
spacing: Dimensions.l
|
||||
|
||||
Button {
|
||||
text: qsTr("Als Mitarbeiter:in Einstellen")
|
||||
icon.source: "qrc:/images/InboxArrowDown.svg"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user