Created login functinality

This commit is contained in:
2024-01-02 22:22:14 +00:00
parent b26bd1a228
commit e0b04d13f6
9 changed files with 89 additions and 79 deletions

View File

@@ -1,4 +1,5 @@
from abc import ABC, abstractmethod
from typing import Mapping, Any
import sqlite3
class DatabaseController(ABC):
@@ -14,6 +15,12 @@ class DatabaseController(ABC):
self._conn.close()
print(e)
def new_instance(self, of: type, with_fields: Mapping[str, Any]):
obj = of.__new__(of)
for attr, value in with_fields.items():
setattr(obj, attr, value)
return obj
@abstractmethod
def create(self):
pass