arch: move web folder into api & move api to top level
This commit is contained in:
		
							
								
								
									
										139
									
								
								internal/graph/schema/_models.gql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										139
									
								
								internal/graph/schema/_models.gql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,139 @@
 | 
			
		||||
scalar Time
 | 
			
		||||
scalar UUID
 | 
			
		||||
scalar Upload
 | 
			
		||||
 | 
			
		||||
enum RoleCode {
 | 
			
		||||
  owner
 | 
			
		||||
  admin
 | 
			
		||||
  member
 | 
			
		||||
  observer
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type ProjectLabel {
 | 
			
		||||
  id: ID!
 | 
			
		||||
  createdDate: Time!
 | 
			
		||||
  labelColor: LabelColor!
 | 
			
		||||
  name: String
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type LabelColor {
 | 
			
		||||
  id: ID!
 | 
			
		||||
  name: String!
 | 
			
		||||
  position: Float!
 | 
			
		||||
  colorHex: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type TaskLabel {
 | 
			
		||||
  id: ID!
 | 
			
		||||
  projectLabel: ProjectLabel!
 | 
			
		||||
  assignedDate: Time!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type ProfileIcon {
 | 
			
		||||
  url: String
 | 
			
		||||
  initials: String
 | 
			
		||||
  bgColor: String
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type Member {
 | 
			
		||||
  id: ID!
 | 
			
		||||
  role: Role!
 | 
			
		||||
  fullName: String!
 | 
			
		||||
  username: String!
 | 
			
		||||
  profileIcon: ProfileIcon!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type RefreshToken {
 | 
			
		||||
  id: ID!
 | 
			
		||||
  userId: UUID!
 | 
			
		||||
  expiresAt: Time!
 | 
			
		||||
  createdAt: Time!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type Role {
 | 
			
		||||
  code: String!
 | 
			
		||||
  name: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type UserAccount {
 | 
			
		||||
  id: ID!
 | 
			
		||||
  email: String!
 | 
			
		||||
  createdAt: Time!
 | 
			
		||||
  fullName: String!
 | 
			
		||||
  initials: String!
 | 
			
		||||
  role: Role!
 | 
			
		||||
  username: String!
 | 
			
		||||
  profileIcon: ProfileIcon!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type Team {
 | 
			
		||||
  id: ID!
 | 
			
		||||
  createdAt: Time!
 | 
			
		||||
  name: String!
 | 
			
		||||
  members: [Member!]!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type Project {
 | 
			
		||||
  id: ID!
 | 
			
		||||
  createdAt: Time!
 | 
			
		||||
  name: String!
 | 
			
		||||
  team: Team!
 | 
			
		||||
  owner: Member!
 | 
			
		||||
  taskGroups: [TaskGroup!]!
 | 
			
		||||
  members: [Member!]!
 | 
			
		||||
  labels: [ProjectLabel!]!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type TaskGroup {
 | 
			
		||||
  id: ID!
 | 
			
		||||
  projectID: String!
 | 
			
		||||
  createdAt: Time!
 | 
			
		||||
  name: String!
 | 
			
		||||
  position: Float!
 | 
			
		||||
  tasks: [Task!]!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type ChecklistBadge {
 | 
			
		||||
  complete: Int!
 | 
			
		||||
  total: Int!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type TaskBadges {
 | 
			
		||||
  checklist: ChecklistBadge
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type Task {
 | 
			
		||||
  id: ID!
 | 
			
		||||
  taskGroup: TaskGroup!
 | 
			
		||||
  createdAt: Time!
 | 
			
		||||
  name: String!
 | 
			
		||||
  position: Float!
 | 
			
		||||
  description: String
 | 
			
		||||
  dueDate: Time
 | 
			
		||||
  complete: Boolean!
 | 
			
		||||
  assigned: [Member!]!
 | 
			
		||||
  labels: [TaskLabel!]!
 | 
			
		||||
  checklists: [TaskChecklist!]!
 | 
			
		||||
  badges: TaskBadges!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type Organization {
 | 
			
		||||
  id: ID!
 | 
			
		||||
  name: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type TaskChecklistItem {
 | 
			
		||||
  id: ID!
 | 
			
		||||
  name: String!
 | 
			
		||||
  taskChecklistID: UUID!
 | 
			
		||||
  complete: Boolean!
 | 
			
		||||
  position: Float!
 | 
			
		||||
  dueDate: Time!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type TaskChecklist {
 | 
			
		||||
  id: ID!
 | 
			
		||||
  name: String!
 | 
			
		||||
  position: Float!
 | 
			
		||||
  items: [TaskChecklistItem!]!
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										35
									
								
								internal/graph/schema/_root.gql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										35
									
								
								internal/graph/schema/_root.gql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,35 @@
 | 
			
		||||
type Query {
 | 
			
		||||
  organizations: [Organization!]!
 | 
			
		||||
  users: [UserAccount!]!
 | 
			
		||||
  findUser(input: FindUser!): UserAccount!
 | 
			
		||||
  findProject(input: FindProject!): Project!
 | 
			
		||||
  findTask(input: FindTask!): Task!
 | 
			
		||||
  projects(input: ProjectsFilter): [Project!]!
 | 
			
		||||
  findTeam(input: FindTeam!): Team!
 | 
			
		||||
  teams: [Team!]!
 | 
			
		||||
  labelColors: [LabelColor!]!
 | 
			
		||||
  taskGroups: [TaskGroup!]!
 | 
			
		||||
  me: UserAccount!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type Mutation
 | 
			
		||||
 | 
			
		||||
input ProjectsFilter {
 | 
			
		||||
  teamID: UUID
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input FindUser {
 | 
			
		||||
  userId: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input FindProject {
 | 
			
		||||
  projectId: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input FindTask {
 | 
			
		||||
  taskID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input FindTeam {
 | 
			
		||||
  teamID: UUID!
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										26
									
								
								internal/graph/schema/project.gql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										26
									
								
								internal/graph/schema/project.gql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,26 @@
 | 
			
		||||
extend type Mutation {
 | 
			
		||||
  createProject(input: NewProject!): Project!
 | 
			
		||||
  deleteProject(input: DeleteProject!): DeleteProjectPayload!
 | 
			
		||||
  updateProjectName(input: UpdateProjectName): Project!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input NewProject {
 | 
			
		||||
  userID: UUID!
 | 
			
		||||
  teamID: UUID!
 | 
			
		||||
  name: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input UpdateProjectName {
 | 
			
		||||
  projectID: UUID!
 | 
			
		||||
  name: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input DeleteProject {
 | 
			
		||||
  projectID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type DeleteProjectPayload {
 | 
			
		||||
  ok: Boolean!
 | 
			
		||||
  project: Project!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
							
								
								
									
										33
									
								
								internal/graph/schema/project_label.gql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										33
									
								
								internal/graph/schema/project_label.gql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,33 @@
 | 
			
		||||
extend type Mutation {
 | 
			
		||||
  createProjectLabel(input: NewProjectLabel!): ProjectLabel!
 | 
			
		||||
  deleteProjectLabel(input: DeleteProjectLabel!): ProjectLabel!
 | 
			
		||||
  updateProjectLabel(input: UpdateProjectLabel!): ProjectLabel!
 | 
			
		||||
  updateProjectLabelName(input: UpdateProjectLabelName!): ProjectLabel!
 | 
			
		||||
  updateProjectLabelColor(input: UpdateProjectLabelColor!): ProjectLabel!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input NewProjectLabel {
 | 
			
		||||
  projectID: UUID!
 | 
			
		||||
  labelColorID: UUID!
 | 
			
		||||
  name: String
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input DeleteProjectLabel {
 | 
			
		||||
  projectLabelID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input UpdateProjectLabelName {
 | 
			
		||||
  projectLabelID: UUID!
 | 
			
		||||
  name: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input UpdateProjectLabel {
 | 
			
		||||
  projectLabelID: UUID!
 | 
			
		||||
  labelColorID: UUID!
 | 
			
		||||
  name: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input UpdateProjectLabelColor {
 | 
			
		||||
  projectLabelID: UUID!
 | 
			
		||||
  labelColorID: UUID!
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										48
									
								
								internal/graph/schema/project_member.gql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										48
									
								
								internal/graph/schema/project_member.gql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,48 @@
 | 
			
		||||
extend type Mutation {
 | 
			
		||||
  createProjectMember(input: CreateProjectMember!): CreateProjectMemberPayload!
 | 
			
		||||
  deleteProjectMember(input: DeleteProjectMember!): DeleteProjectMemberPayload!
 | 
			
		||||
  updateProjectMemberRole(input: UpdateProjectMemberRole!): UpdateProjectMemberRolePayload!
 | 
			
		||||
  setProjectOwner(input: SetProjectOwner!): SetProjectOwnerPayload!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input CreateProjectMember {
 | 
			
		||||
  projectID: UUID!
 | 
			
		||||
  userID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type CreateProjectMemberPayload {
 | 
			
		||||
  ok: Boolean!
 | 
			
		||||
  member: Member!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input DeleteProjectMember {
 | 
			
		||||
  projectID: UUID!
 | 
			
		||||
  userID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type DeleteProjectMemberPayload {
 | 
			
		||||
  ok: Boolean!
 | 
			
		||||
  member: Member!
 | 
			
		||||
  projectID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input UpdateProjectMemberRole {
 | 
			
		||||
  projectID: UUID!
 | 
			
		||||
  userID: UUID!
 | 
			
		||||
  roleCode: RoleCode!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type UpdateProjectMemberRolePayload {
 | 
			
		||||
  ok: Boolean!
 | 
			
		||||
  member: Member!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input SetProjectOwner {
 | 
			
		||||
  projectID: UUID!
 | 
			
		||||
  ownerID: UUID!
 | 
			
		||||
}
 | 
			
		||||
type SetProjectOwnerPayload {
 | 
			
		||||
  ok: Boolean!
 | 
			
		||||
  prevOwner: Member!
 | 
			
		||||
  newOwner: Member!
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										68
									
								
								internal/graph/schema/task.gql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										68
									
								
								internal/graph/schema/task.gql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,68 @@
 | 
			
		||||
extend type Mutation {
 | 
			
		||||
  createTask(input: NewTask!): Task!
 | 
			
		||||
  deleteTask(input: DeleteTaskInput!): DeleteTaskPayload!
 | 
			
		||||
 | 
			
		||||
  updateTaskDescription(input: UpdateTaskDescriptionInput!): Task!
 | 
			
		||||
  updateTaskLocation(input: NewTaskLocation!): UpdateTaskLocationPayload!
 | 
			
		||||
  updateTaskName(input: UpdateTaskName!): Task!
 | 
			
		||||
  setTaskComplete(input: SetTaskComplete!): Task!
 | 
			
		||||
  updateTaskDueDate(input: UpdateTaskDueDate!): Task!
 | 
			
		||||
 | 
			
		||||
  assignTask(input: AssignTaskInput): Task!
 | 
			
		||||
  unassignTask(input: UnassignTaskInput): Task!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input NewTask {
 | 
			
		||||
  taskGroupID: String!
 | 
			
		||||
  name: String!
 | 
			
		||||
  position: Float!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input AssignTaskInput {
 | 
			
		||||
  taskID: UUID!
 | 
			
		||||
  userID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input UnassignTaskInput {
 | 
			
		||||
  taskID: UUID!
 | 
			
		||||
  userID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input UpdateTaskDescriptionInput {
 | 
			
		||||
  taskID: UUID!
 | 
			
		||||
  description: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type UpdateTaskLocationPayload {
 | 
			
		||||
  previousTaskGroupID: UUID!
 | 
			
		||||
  task: Task!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input UpdateTaskDueDate  {
 | 
			
		||||
  taskID: UUID!
 | 
			
		||||
  dueDate: Time
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input SetTaskComplete {
 | 
			
		||||
  taskID: UUID!
 | 
			
		||||
  complete: Boolean!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input NewTaskLocation {
 | 
			
		||||
  taskID: UUID!
 | 
			
		||||
  taskGroupID: UUID!
 | 
			
		||||
  position: Float!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input DeleteTaskInput {
 | 
			
		||||
  taskID: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type DeleteTaskPayload {
 | 
			
		||||
  taskID: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input UpdateTaskName {
 | 
			
		||||
  taskID: String!
 | 
			
		||||
  name: String!
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										52
									
								
								internal/graph/schema/task_checklist.gql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										52
									
								
								internal/graph/schema/task_checklist.gql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,52 @@
 | 
			
		||||
extend type Mutation {
 | 
			
		||||
  createTaskChecklist(input: CreateTaskChecklist!): TaskChecklist!
 | 
			
		||||
  deleteTaskChecklist(input: DeleteTaskChecklist!): DeleteTaskChecklistPayload!
 | 
			
		||||
  updateTaskChecklistName(input: UpdateTaskChecklistName!): TaskChecklist!
 | 
			
		||||
  createTaskChecklistItem(input: CreateTaskChecklistItem!): TaskChecklistItem!
 | 
			
		||||
  updateTaskChecklistItemName(input: UpdateTaskChecklistItemName!): TaskChecklistItem!
 | 
			
		||||
  setTaskChecklistItemComplete(input: SetTaskChecklistItemComplete!): TaskChecklistItem!
 | 
			
		||||
  deleteTaskChecklistItem(input: DeleteTaskChecklistItem!): DeleteTaskChecklistItemPayload!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input CreateTaskChecklist {
 | 
			
		||||
  taskID: UUID!
 | 
			
		||||
  name: String!
 | 
			
		||||
  position: Float!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type DeleteTaskChecklistItemPayload {
 | 
			
		||||
  ok: Boolean!
 | 
			
		||||
  taskChecklistItem: TaskChecklistItem!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input CreateTaskChecklistItem {
 | 
			
		||||
  taskChecklistID: UUID!
 | 
			
		||||
  name: String!
 | 
			
		||||
  position: Float!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input SetTaskChecklistItemComplete {
 | 
			
		||||
  taskChecklistItemID: UUID!
 | 
			
		||||
  complete: Boolean!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input DeleteTaskChecklistItem {
 | 
			
		||||
  taskChecklistItemID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input UpdateTaskChecklistItemName {
 | 
			
		||||
  taskChecklistItemID: UUID!
 | 
			
		||||
  name: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input UpdateTaskChecklistName {
 | 
			
		||||
  taskChecklistID: UUID!
 | 
			
		||||
  name: String!
 | 
			
		||||
}
 | 
			
		||||
input DeleteTaskChecklist {
 | 
			
		||||
  taskChecklistID: UUID!
 | 
			
		||||
}
 | 
			
		||||
type DeleteTaskChecklistPayload {
 | 
			
		||||
  ok: Boolean!
 | 
			
		||||
  taskChecklist: TaskChecklist!
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										32
									
								
								internal/graph/schema/task_group.gql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										32
									
								
								internal/graph/schema/task_group.gql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,32 @@
 | 
			
		||||
extend type Mutation {
 | 
			
		||||
  createTaskGroup(input: NewTaskGroup!): TaskGroup!
 | 
			
		||||
  updateTaskGroupLocation(input: NewTaskGroupLocation!): TaskGroup!
 | 
			
		||||
  updateTaskGroupName(input: UpdateTaskGroupName!): TaskGroup!
 | 
			
		||||
  deleteTaskGroup(input: DeleteTaskGroupInput!): DeleteTaskGroupPayload!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input NewTaskGroupLocation {
 | 
			
		||||
  taskGroupID: UUID!
 | 
			
		||||
  position: Float!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input UpdateTaskGroupName  {
 | 
			
		||||
  taskGroupID: UUID!
 | 
			
		||||
  name: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input DeleteTaskGroupInput {
 | 
			
		||||
  taskGroupID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type DeleteTaskGroupPayload {
 | 
			
		||||
  ok: Boolean!
 | 
			
		||||
  affectedRows: Int!
 | 
			
		||||
  taskGroup: TaskGroup!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input NewTaskGroup {
 | 
			
		||||
  projectID: String!
 | 
			
		||||
  name: String!
 | 
			
		||||
  position: Float!
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										22
									
								
								internal/graph/schema/task_label.gql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										22
									
								
								internal/graph/schema/task_label.gql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,22 @@
 | 
			
		||||
input AddTaskLabelInput {
 | 
			
		||||
  taskID: UUID!
 | 
			
		||||
  projectLabelID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input RemoveTaskLabelInput {
 | 
			
		||||
  taskLabelID: UUID!
 | 
			
		||||
}
 | 
			
		||||
input ToggleTaskLabelInput {
 | 
			
		||||
  taskID: UUID!
 | 
			
		||||
  projectLabelID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type ToggleTaskLabelPayload {
 | 
			
		||||
  active: Boolean!
 | 
			
		||||
  task: Task!
 | 
			
		||||
}
 | 
			
		||||
extend type Mutation {
 | 
			
		||||
  addTaskLabel(input: AddTaskLabelInput): Task!
 | 
			
		||||
  removeTaskLabel(input: RemoveTaskLabelInput): Task!
 | 
			
		||||
  toggleTaskLabel(input: ToggleTaskLabelInput!): ToggleTaskLabelPayload!
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										19
									
								
								internal/graph/schema/team.gql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										19
									
								
								internal/graph/schema/team.gql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,19 @@
 | 
			
		||||
extend type Mutation {
 | 
			
		||||
  deleteTeam(input: DeleteTeam!): DeleteTeamPayload!
 | 
			
		||||
  createTeam(input: NewTeam!): Team!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input NewTeam {
 | 
			
		||||
  name: String!
 | 
			
		||||
  organizationID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input DeleteTeam {
 | 
			
		||||
  teamID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type DeleteTeamPayload {
 | 
			
		||||
  ok: Boolean!
 | 
			
		||||
  team: Team!
 | 
			
		||||
  projects: [Project!]!
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										48
									
								
								internal/graph/schema/team_member.gql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										48
									
								
								internal/graph/schema/team_member.gql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,48 @@
 | 
			
		||||
extend type Mutation {
 | 
			
		||||
  setTeamOwner(input: SetTeamOwner!): SetTeamOwnerPayload!
 | 
			
		||||
  createTeamMember(input: CreateTeamMember!): CreateTeamMemberPayload!
 | 
			
		||||
  updateTeamMemberRole(input: UpdateTeamMemberRole!): UpdateTeamMemberRolePayload!
 | 
			
		||||
  deleteTeamMember(input: DeleteTeamMember!): DeleteTeamMemberPayload!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input DeleteTeamMember {
 | 
			
		||||
  teamID: UUID!
 | 
			
		||||
  userID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type DeleteTeamMemberPayload {
 | 
			
		||||
  teamID: UUID!
 | 
			
		||||
  userID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input CreateTeamMember {
 | 
			
		||||
  userID: UUID!
 | 
			
		||||
  teamID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type CreateTeamMemberPayload {
 | 
			
		||||
  team: Team!
 | 
			
		||||
  teamMember: Member!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input UpdateTeamMemberRole {
 | 
			
		||||
  teamID: UUID!
 | 
			
		||||
  userID: UUID!
 | 
			
		||||
  roleCode: RoleCode!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type UpdateTeamMemberRolePayload {
 | 
			
		||||
  ok: Boolean!
 | 
			
		||||
  member: Member!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input SetTeamOwner {
 | 
			
		||||
  teamID: UUID!
 | 
			
		||||
  userID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type SetTeamOwnerPayload {
 | 
			
		||||
  ok: Boolean!
 | 
			
		||||
  prevOwner: Member!
 | 
			
		||||
  newOwner: Member!
 | 
			
		||||
}
 | 
			
		||||
							
								
								
									
										33
									
								
								internal/graph/schema/user.gql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										33
									
								
								internal/graph/schema/user.gql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,33 @@
 | 
			
		||||
extend type Mutation {
 | 
			
		||||
  createRefreshToken(input: NewRefreshToken!): RefreshToken!
 | 
			
		||||
  createUserAccount(input: NewUserAccount!): UserAccount!
 | 
			
		||||
  deleteUserAccount(input: DeleteUserAccount!): DeleteUserAccountPayload!
 | 
			
		||||
  logoutUser(input: LogoutUser!): Boolean!
 | 
			
		||||
  clearProfileAvatar:  UserAccount!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input NewRefreshToken {
 | 
			
		||||
  userId: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input NewUserAccount {
 | 
			
		||||
  username: String!
 | 
			
		||||
  email: String!
 | 
			
		||||
  fullName: String!
 | 
			
		||||
  initials: String!
 | 
			
		||||
  password: String!
 | 
			
		||||
  roleCode: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input LogoutUser {
 | 
			
		||||
  userID: String!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
input DeleteUserAccount {
 | 
			
		||||
  userID: UUID!
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
type DeleteUserAccountPayload {
 | 
			
		||||
  ok: Boolean!
 | 
			
		||||
  userAccount: UserAccount!
 | 
			
		||||
}
 | 
			
		||||
		Reference in New Issue
	
	Block a user