ui change, bugfix

This commit is contained in:
WorldTeacher
2024-09-11 15:59:28 +02:00
parent 05fe6a1af0
commit a8c2277870
5 changed files with 110 additions and 133 deletions

View File

@@ -21,12 +21,9 @@ class Ui_Dialog(object):
self.institution_name = QtWidgets.QLineEdit(parent=Dialog)
self.institution_name.setObjectName("institution_name")
self.formLayout.setWidget(0, QtWidgets.QFormLayout.ItemRole.FieldRole, self.institution_name)
self.label_2 = QtWidgets.QLabel(parent=Dialog)
self.label_2.setObjectName("label_2")
self.formLayout.setWidget(1, QtWidgets.QFormLayout.ItemRole.LabelRole, self.label_2)
self.label_3 = QtWidgets.QLabel(parent=Dialog)
self.label_3.setObjectName("label_3")
self.formLayout.setWidget(3, QtWidgets.QFormLayout.ItemRole.LabelRole, self.label_3)
self.formLayout.setWidget(5, QtWidgets.QFormLayout.ItemRole.LabelRole, self.label_3)
self.databasesettings = QtWidgets.QGridLayout()
self.databasesettings.setObjectName("databasesettings")
self.database_name = QtWidgets.QLineEdit(parent=Dialog)
@@ -56,27 +53,15 @@ class Ui_Dialog(object):
self.btn_select_database_backupLocation = QtWidgets.QToolButton(parent=Dialog)
self.btn_select_database_backupLocation.setObjectName("btn_select_database_backupLocation")
self.databasesettings.addWidget(self.btn_select_database_backupLocation, 2, 2, 1, 1)
self.formLayout.setLayout(3, QtWidgets.QFormLayout.ItemRole.FieldRole, self.databasesettings)
self.label_7 = QtWidgets.QLabel(parent=Dialog)
self.label_7.setObjectName("label_7")
self.formLayout.setWidget(2, QtWidgets.QFormLayout.ItemRole.LabelRole, self.label_7)
self.default_loan_duration = QtWidgets.QSpinBox(parent=Dialog)
self.default_loan_duration.setProperty("value", 7)
self.default_loan_duration.setObjectName("default_loan_duration")
self.formLayout.setWidget(1, QtWidgets.QFormLayout.ItemRole.FieldRole, self.default_loan_duration)
self.delete_inactive_user_duration = QtWidgets.QSpinBox(parent=Dialog)
self.delete_inactive_user_duration.setMaximum(9999)
self.delete_inactive_user_duration.setProperty("value", 365)
self.delete_inactive_user_duration.setObjectName("delete_inactive_user_duration")
self.formLayout.setWidget(2, QtWidgets.QFormLayout.ItemRole.FieldRole, self.delete_inactive_user_duration)
self.formLayout.setLayout(5, QtWidgets.QFormLayout.ItemRole.FieldRole, self.databasesettings)
self.buttonBox = QtWidgets.QDialogButtonBox(parent=Dialog)
self.buttonBox.setOrientation(QtCore.Qt.Orientation.Horizontal)
self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.StandardButton.Cancel|QtWidgets.QDialogButtonBox.StandardButton.Discard|QtWidgets.QDialogButtonBox.StandardButton.Ok)
self.buttonBox.setObjectName("buttonBox")
self.formLayout.setWidget(5, QtWidgets.QFormLayout.ItemRole.FieldRole, self.buttonBox)
self.formLayout.setWidget(7, QtWidgets.QFormLayout.ItemRole.FieldRole, self.buttonBox)
self.label_9 = QtWidgets.QLabel(parent=Dialog)
self.label_9.setObjectName("label_9")
self.formLayout.setWidget(4, QtWidgets.QFormLayout.ItemRole.LabelRole, self.label_9)
self.formLayout.setWidget(6, QtWidgets.QFormLayout.ItemRole.LabelRole, self.label_9)
self.gridLayout = QtWidgets.QGridLayout()
self.gridLayout.setObjectName("gridLayout")
self.btn_select_report_path = QtWidgets.QToolButton(parent=Dialog)
@@ -106,7 +91,36 @@ class Ui_Dialog(object):
self.report_day.addItem("")
self.report_day.addItem("")
self.gridLayout.addWidget(self.report_day, 0, 1, 1, 1)
self.formLayout.setLayout(4, QtWidgets.QFormLayout.ItemRole.FieldRole, self.gridLayout)
self.formLayout.setLayout(6, QtWidgets.QFormLayout.ItemRole.FieldRole, self.gridLayout)
self.horizontalLayout = QtWidgets.QHBoxLayout()
self.horizontalLayout.setObjectName("horizontalLayout")
self.delete_inactive_user_duration = QtWidgets.QSpinBox(parent=Dialog)
self.delete_inactive_user_duration.setMaximum(9999)
self.delete_inactive_user_duration.setProperty("value", 365)
self.delete_inactive_user_duration.setObjectName("delete_inactive_user_duration")
self.horizontalLayout.addWidget(self.delete_inactive_user_duration)
self.label_12 = QtWidgets.QLabel(parent=Dialog)
self.label_12.setMaximumSize(QtCore.QSize(43, 16777215))
self.label_12.setObjectName("label_12")
self.horizontalLayout.addWidget(self.label_12)
self.formLayout.setLayout(3, QtWidgets.QFormLayout.ItemRole.FieldRole, self.horizontalLayout)
self.label_7 = QtWidgets.QLabel(parent=Dialog)
self.label_7.setObjectName("label_7")
self.formLayout.setWidget(3, QtWidgets.QFormLayout.ItemRole.LabelRole, self.label_7)
self.horizontalLayout_2 = QtWidgets.QHBoxLayout()
self.horizontalLayout_2.setObjectName("horizontalLayout_2")
self.default_loan_duration = QtWidgets.QSpinBox(parent=Dialog)
self.default_loan_duration.setProperty("value", 7)
self.default_loan_duration.setObjectName("default_loan_duration")
self.horizontalLayout_2.addWidget(self.default_loan_duration)
self.label_13 = QtWidgets.QLabel(parent=Dialog)
self.label_13.setMaximumSize(QtCore.QSize(43, 16777215))
self.label_13.setObjectName("label_13")
self.horizontalLayout_2.addWidget(self.label_13)
self.formLayout.setLayout(1, QtWidgets.QFormLayout.ItemRole.FieldRole, self.horizontalLayout_2)
self.label_2 = QtWidgets.QLabel(parent=Dialog)
self.label_2.setObjectName("label_2")
self.formLayout.setWidget(1, QtWidgets.QFormLayout.ItemRole.LabelRole, self.label_2)
self.retranslateUi(Dialog)
self.buttonBox.accepted.connect(Dialog.accept) # type: ignore
@@ -123,7 +137,6 @@ class Ui_Dialog(object):
_translate = QtCore.QCoreApplication.translate
Dialog.setWindowTitle(_translate("Dialog", "Dialog"))
self.label.setText(_translate("Dialog", "Name der Einrichtung"))
self.label_2.setText(_translate("Dialog", "Leihdauer in Tagen"))
self.label_3.setText(_translate("Dialog", "Datenbank"))
self.label_4.setText(_translate("Dialog", "Speicherort"))
self.label_6.setText(_translate("Dialog", "Sicherungspfad"))
@@ -131,8 +144,6 @@ class Ui_Dialog(object):
self.btn_select_database_path.setText(_translate("Dialog", "..."))
self.btn_select_database_name.setText(_translate("Dialog", "..."))
self.btn_select_database_backupLocation.setText(_translate("Dialog", "..."))
self.label_7.setText(_translate("Dialog", "Inaktive Nutzer\n"
"Löschen nach"))
self.label_9.setText(_translate("Dialog", "Bericht"))
self.btn_select_report_path.setText(_translate("Dialog", "..."))
self.check_generate_report.setText(_translate("Dialog", "Bericht erstellen"))
@@ -143,3 +154,8 @@ class Ui_Dialog(object):
self.report_day.setItemText(2, _translate("Dialog", "Mittwoch"))
self.report_day.setItemText(3, _translate("Dialog", "Donnerstag"))
self.report_day.setItemText(4, _translate("Dialog", "Freitag"))
self.label_12.setText(_translate("Dialog", "Tage(n)"))
self.label_7.setText(_translate("Dialog", "Inaktive Nutzer\n"
"Löschen nach"))
self.label_13.setText(_translate("Dialog", "Tage(n)"))
self.label_2.setText(_translate("Dialog", "Leihdauer"))