summaryrefslogtreecommitdiff
path: root/gui/qml/LoginDialog.qml
blob: fbe5ce12c5b7e8de14bcd4d808030d6181d351ed (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
import QtQuick 2.0
import QtQuick.Dialogs 1.2
import QtQuick.Controls 1.4

Dialog {
    standardButtons: StandardButton.Ok
    title: "Login"
    Column {
        anchors.fill: parent
        Text {
            text: "Log in with your library credentials"
        }
        TextField {
            id: username
            placeholderText: "patron id"
        }
        TextField {
            id: password
            placeholderText: "password"
            echoMode: TextInput.PasswordEchoOnEdit
        }
    }

    visible: false
    //visible: ctx.showLogin == true
    //onAccepted: backend.login(username.text, password.text)
    onRejected: backend.quit()  // TODO: it doesn't close
}