notebookvb
This commit is contained in:
@@ -18,6 +18,15 @@ def get_medicus_connection():
|
||||
return fdb.connect(dsn=dsn, user="SYSDBA", password="masterkey", charset="win1250")
|
||||
|
||||
|
||||
def get_medicus_db():
|
||||
"""Vrátí MedicusDB instanci s připojením podle názvu počítače."""
|
||||
conn = get_medicus_connection()
|
||||
instance = object.__new__(MedicusDB)
|
||||
instance.conn = conn
|
||||
instance.cur = conn.cursor()
|
||||
return instance
|
||||
|
||||
|
||||
class MedicusDB:
|
||||
|
||||
def __init__(self, host, db_path, user="SYSDBA", password="masterkey", charset="WIN1250"):
|
||||
|
||||
Reference in New Issue
Block a user