files: reorganize imports, remove print lines

This commit is contained in:
2025-09-22 09:42:15 +02:00
parent 7079b4d47f
commit c4be1d8bfa
23 changed files with 127 additions and 110 deletions

View File

@@ -10,8 +10,9 @@ import hashlib
from PySide6 import QtCore, QtWidgets
from src.backend.database import Database
from src.backend.admin_console import AdminCommands
from src.backend.database import Database
class Ui_Dialog(object):
def setupUi(self, Dialog):
@@ -64,13 +65,11 @@ class Ui_Dialog(object):
def login(self):
username = self.lineEdit.text()
password = self.lineEdit_2.text()
print(type(username), password)
# print(type(username), password)
# Assuming 'Database' is a class to interact with your database
db = Database()
db = Database()
hashed_password = hashlib.sha256(
password.encode()
).hexdigest()
hashed_password = hashlib.sha256(password.encode()).hexdigest()
if len(db.getUsers()) == 0:
AdminCommands().create_admin()
self.lresult = 1 # Indicate successful login