示例#1
0
import db

class Magnet(object):
    pass

magnetTable = db.Table(
    "magnet", db.metadata,
    db.Column('id', db.Integer, primary_key=True),
    db.Column('fid', db.Integer),
    db.Column('magnet_uri', db.TEXT),
)

db.mapper(Magnet, magnetTable)
示例#2
0
import db


class Magnet(object):
    pass


magnetTable = db.Table(
    "magnet",
    db.metadata,
    db.Column('id', db.Integer, primary_key=True),
    db.Column('fid', db.Integer),
    db.Column('magnet_uri', db.TEXT),
)

db.mapper(Magnet, magnetTable)
示例#3
0
import db

class Category(object):
    pass

categoryTable = db.Table(
    "category", db.metadata,
    db.Column('id', db.Integer, primary_key=True),
    db.Column('fid', db.Integer),
    db.Column('gid', db.Integer),
)

db.mapper(Category, categoryTable)
示例#4
0
import db

class Cast(object):
    pass

castTable = db.Table(
    "cast", db.metadata,
    db.Column('id', db.Integer, primary_key=True),
    db.Column('aid', db.Integer),
    db.Column('fid', db.Integer),
)

db.mapper(Cast, castTable)
示例#5
0
import db

class Artist(object):
    pass

artistTable = db.Table(
    "artist", db.metadata,
    db.Column('aid', db.Integer, primary_key=True),
    db.Column('artist_name', db.VARCHAR(50), nullable=False),
    db.Column('stag', db.VARCHAR(40), nullable=True),
    db.Column('url', db.VARCHAR(100), nullable=True),
)

db.mapper(Artist, artistTable)
示例#6
0
import db


class Genre(object):
    pass


genreTable = db.Table(
    "genre",
    db.metadata,
    db.Column('gid', db.Integer, primary_key=True),
    db.Column('genre_name', db.VARCHAR(50), nullable=False),
    db.Column('url', db.VARCHAR(100), nullable=True),
)

db.mapper(Genre, genreTable)
示例#7
0
import db

class Film(object):
    pass

filmTable = db.Table(
    "film", db.metadata,
    db.Column('fid', db.Integer, primary_key=True),
    db.Column('tag', db.VARCHAR(40), nullable=False),
    db.Column('file_name', db.VARCHAR(1000), nullable=False),
    db.Column('cover', db.VARCHAR(1000), nullable=True),
    db.Column('url', db.VARCHAR(200), nullable=True),
    db.Column('length', db.Integer, nullable=True),
    db.Column('date', db.VARCHAR(100), nullable=True),
    db.Column('director', db.VARCHAR(100), nullable=True),
    db.Column('maker', db.VARCHAR(100), nullable=True),
    db.Column('producer', db.VARCHAR(100), nullable=True),
    db.Column('score', db.FLOAT, nullable=True),
    db.Column('magnet', db.VARCHAR(1000), nullable=True),
)

db.mapper(Film, filmTable)
示例#8
0
import db


class TopArtist(object):
    pass


topArtistTable = db.Table(
    "topartist",
    db.metadata,
    db.Column('aid', db.Integer, primary_key=True),
    db.Column('artist_name', db.VARCHAR(50), nullable=False),
    db.Column('stag', db.VARCHAR(40), nullable=True),
    db.Column('url', db.VARCHAR(100), nullable=True),
    db.Column('img', db.VARCHAR(100), nullable=True),
    db.Column('rank', db.Integer, nullable=True),
)

db.mapper(TopArtist, topArtistTable)
示例#9
0
import db

class TopArtist(object):
    pass

topArtistTable = db.Table(
    "topartist", db.metadata,
    db.Column('aid', db.Integer, primary_key=True),
    db.Column('artist_name', db.VARCHAR(50), nullable=False),
    db.Column('stag', db.VARCHAR(40), nullable=True),
    db.Column('url', db.VARCHAR(100), nullable=True),
    db.Column('img', db.VARCHAR(100), nullable=True),
    db.Column('rank', db.Integer, nullable=True),
)

db.mapper(TopArtist, topArtistTable)