Code refactoring. Add support genres and actors to routes

This commit is contained in:
2024-06-26 23:13:47 +04:00
parent fc3bcc343d
commit b9e22fcc4c
28 changed files with 545 additions and 250 deletions

View File

@@ -2,14 +2,14 @@
from asyncio import run as aiorun
import typer
import database
from database import Database
cli = typer.Typer()
@cli.command(name="create")
def create_database(): aiorun(database.create_all())
def create_database(): aiorun(Database.create_all())
@cli.command(name="drop")
def drop_database(): aiorun(database.drop_all())
def drop_database(): aiorun(Database.drop_all())
@cli.command(name="recreate")
def recreate_database(): aiorun(database.recreate_all())
def recreate_database(): aiorun(Database.recreate_all())