From 9a685590fb2c71b16bd1db196939021f0fec03de Mon Sep 17 00:00:00 2001 From: tonyrewin Date: Tue, 14 Jun 2022 09:13:06 +0300 Subject: [PATCH] shout with id for candidates --- orm/shout.py | 2 +- schema.graphql | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/orm/shout.py b/orm/shout.py index 0631c7bc..7b7be84b 100644 --- a/orm/shout.py +++ b/orm/shout.py @@ -315,7 +315,7 @@ class CommentStat: class Shout(Base): __tablename__ = 'shout' - id = None + # id = None slug: str = Column(String, primary_key=True) community: int = Column(Integer, ForeignKey("community.id"), nullable=False, comment="Community") diff --git a/schema.graphql b/schema.graphql index 96c40139..f082efa5 100644 --- a/schema.graphql +++ b/schema.graphql @@ -269,13 +269,13 @@ type User { type Comment { id: Int! + shout: Int! author: User! body: String! replyTo: Int createdAt: DateTime! updatedAt: DateTime updatedBy: Int - shout: Int! deletedAt: DateTime deletedBy: Int ratings: [CommentRating] @@ -294,6 +294,7 @@ type CommentRating { # is publication type Shout { + id: Int! slug: String! body: String! createdAt: DateTime!