views from ackee
This commit is contained in:
@@ -6,7 +6,6 @@ from orm.reaction import Reaction
|
||||
from orm.shout import Shout
|
||||
from orm.topic import Topic, TopicFollower
|
||||
from orm.user import User, UserRating
|
||||
from orm.viewed import ViewedByDay
|
||||
|
||||
__all__ = [
|
||||
"User",
|
||||
@@ -19,8 +18,7 @@ __all__ = [
|
||||
"TopicFollower",
|
||||
"Notification",
|
||||
"Reaction",
|
||||
"UserRating",
|
||||
"ViewedByDay"
|
||||
"UserRating"
|
||||
]
|
||||
|
||||
Base.metadata.create_all(engine)
|
||||
|
@@ -1,12 +0,0 @@
|
||||
from datetime import datetime
|
||||
from sqlalchemy import Column, DateTime, ForeignKey, Integer
|
||||
from base.orm import Base
|
||||
|
||||
|
||||
class ViewedByDay(Base):
|
||||
__tablename__ = "viewed_by_day"
|
||||
|
||||
id = None
|
||||
shout = Column(ForeignKey("shout.slug"), primary_key=True)
|
||||
day = Column(DateTime, primary_key=True, default=datetime.now)
|
||||
value = Column(Integer)
|
Reference in New Issue
Block a user