mirror of
https://github.com/IT4Change/Ocelot-Social.git
synced 2025-12-13 07:45:56 +00:00
add group to post in schema
This commit is contained in:
parent
6f59ced9eb
commit
90e1696f86
@ -38,6 +38,8 @@ type Group {
|
||||
categories: [Category] @relation(name: "CATEGORIZED", direction: "OUT")
|
||||
|
||||
myRole: GroupMemberRole # if 'null' then the current user is no member
|
||||
|
||||
posts: [Post] @relation(name: "IN", direction: "IN")
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -81,6 +81,7 @@ input _PostFilter {
|
||||
emotions_none: _PostEMOTEDFilter
|
||||
emotions_single: _PostEMOTEDFilter
|
||||
emotions_every: _PostEMOTEDFilter
|
||||
group: ID
|
||||
}
|
||||
|
||||
enum _PostOrdering {
|
||||
@ -167,6 +168,8 @@ type Post {
|
||||
emotions: [EMOTED]
|
||||
emotionsCount: Int!
|
||||
@cypher(statement: "MATCH (this)<-[emoted:EMOTED]-(:User) RETURN COUNT(DISTINCT emoted)")
|
||||
|
||||
group: Group @relation(name: "IN", direction: "OUT")
|
||||
}
|
||||
|
||||
input _PostInput {
|
||||
@ -184,6 +187,7 @@ type Mutation {
|
||||
language: String
|
||||
categoryIds: [ID]
|
||||
contentExcerpt: String
|
||||
groupId: ID
|
||||
): Post
|
||||
UpdatePost(
|
||||
id: ID!
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user