feat: add notification UI
showPopup was also refactored to be better
This commit is contained in:
36
internal/graph/schema/notification.gql
Normal file
36
internal/graph/schema/notification.gql
Normal file
@ -0,0 +1,36 @@
|
||||
extend type Query {
|
||||
notifications: [Notification!]!
|
||||
}
|
||||
|
||||
enum EntityType {
|
||||
TASK
|
||||
}
|
||||
|
||||
enum ActorType {
|
||||
USER
|
||||
}
|
||||
|
||||
enum ActionType {
|
||||
TASK_MEMBER_ADDED
|
||||
}
|
||||
|
||||
type NotificationActor {
|
||||
id: UUID!
|
||||
type: ActorType!
|
||||
name: String!
|
||||
}
|
||||
|
||||
type NotificationEntity {
|
||||
id: UUID!
|
||||
type: EntityType!
|
||||
name: String!
|
||||
}
|
||||
|
||||
type Notification {
|
||||
id: ID!
|
||||
entity: NotificationEntity!
|
||||
actionType: ActionType!
|
||||
actor: NotificationActor!
|
||||
read: Boolean!
|
||||
createdAt: Time!
|
||||
}
|
@ -16,9 +16,9 @@ extend type Mutation {
|
||||
Task! @hasRole(roles: [ADMIN], level: PROJECT, type: PROJECT)
|
||||
|
||||
assignTask(input: AssignTaskInput):
|
||||
Task! @hasRole(roles: [ADMIN], level: PROJECT, type: PROJECT)
|
||||
Task! @hasRole(roles: [ADMIN], level: PROJECT, type: TASK)
|
||||
unassignTask(input: UnassignTaskInput):
|
||||
Task! @hasRole(roles: [ADMIN], level: PROJECT, type: PROJECT)
|
||||
Task! @hasRole(roles: [ADMIN], level: PROJECT, type: TASK)
|
||||
}
|
||||
|
||||
input NewTask {
|
||||
|
Reference in New Issue
Block a user