Files
BiblioGame/app/api/cruds/library/create.py
2026-02-13 13:35:18 +01:00

15 lines
400 B
Python

from sqlalchemy.orm import Session
from ....schema.library.library import Library
import logging
logger = logging.getLogger(__name__)
def create(session:Session, library:Library):
logger.debug("Add Library")
session.add(library)
logger.debug("Added Library")
session.commit()
logger.debug("Committed Library")
session.refresh(library)
logger.debug("Rerfreshed Library")