mirror of
https://github.com/StepanovPlaton/torrent_backend.git
synced 2026-04-03 20:30:38 +04:00
Add audiobooks
This commit is contained in:
26
database/models/audiobooks.py
Normal file
26
database/models/audiobooks.py
Normal file
@@ -0,0 +1,26 @@
|
||||
from sqlalchemy import Column, ForeignKey, Integer, String
|
||||
|
||||
from ..database import Base
|
||||
|
||||
|
||||
class Audiobook(Base):
|
||||
__tablename__ = "audiobooks"
|
||||
|
||||
id = Column(Integer, primary_key=True)
|
||||
|
||||
title = Column(String, nullable=False, unique=True)
|
||||
cover = Column(String)
|
||||
description = Column(String)
|
||||
author = Column(String)
|
||||
|
||||
torrent_file = Column(String, nullable=False)
|
||||
upload_date = Column(String, nullable=False)
|
||||
fragment = Column(String)
|
||||
update_date = Column(String, nullable=False)
|
||||
language = Column(String)
|
||||
release_date = Column(String)
|
||||
download_size = Column(String)
|
||||
duration = Column(String)
|
||||
reader = Column(String)
|
||||
|
||||
owner_id = Column(Integer, ForeignKey("users.id"))
|
||||
Reference in New Issue
Block a user