From 5703759ca29cea76af5c774154191f9490112445 Mon Sep 17 00:00:00 2001 From: Jedd Morgan <45512892+JR-Morgan@users.noreply.github.com> Date: Tue, 10 Dec 2024 14:51:19 +0000 Subject: [PATCH 1/2] basic queries to update --- ui/src/graphql/streams.gql | 86 +++++++++++++++++++------------------ ui/src/graphql/user.gql | 2 +- ui/src/graphql/userById.gql | 4 +- 3 files changed, 46 insertions(+), 46 deletions(-) diff --git a/ui/src/graphql/streams.gql b/ui/src/graphql/streams.gql index 138ef8d9..5cdc9285 100644 --- a/ui/src/graphql/streams.gql +++ b/ui/src/graphql/streams.gql @@ -1,51 +1,53 @@ query Streams($cursor: String) { - streams(cursor: $cursor) { - totalCount - cursor - items { - id - name - description - role - isPublic - createdAt - updatedAt - collaborators { + activeUser { + streams(cursor: $cursor) { + totalCount + cursor + items { id name - company - avatar + description role - } - commits(limit: 1) { - totalCount - items { - id - createdAt - message - authorId - branchName - authorName - authorAvatar - referencedObject - } - } - branches { - totalCount - items { + isPublic + createdAt + updatedAt + collaborators { id name - commits(limit: 10) { - totalCount - items { - id - createdAt - message - authorId - branchName - authorName - authorAvatar - referencedObject + company + avatar + role + } + commits(limit: 1) { + totalCount + items { + id + createdAt + message + authorId + branchName + authorName + authorAvatar + referencedObject + } + } + branches { + totalCount + items { + id + name + commits(limit: 10) { + totalCount + items { + id + createdAt + message + authorId + branchName + authorName + authorAvatar + referencedObject + } } } } diff --git a/ui/src/graphql/user.gql b/ui/src/graphql/user.gql index 91b07d73..6c44b822 100644 --- a/ui/src/graphql/user.gql +++ b/ui/src/graphql/user.gql @@ -1,5 +1,5 @@ query { - user { + activeUser { id email name diff --git a/ui/src/graphql/userById.gql b/ui/src/graphql/userById.gql index 44e717ff..a49b6358 100644 --- a/ui/src/graphql/userById.gql +++ b/ui/src/graphql/userById.gql @@ -1,13 +1,11 @@ query User($id: String!) { - user(id: $id) { + otherUser(id: $id) { id - email name bio company avatar verified - profiles role } } From 94bd527e30e04f5bba1c15b8592e3512473e0cd0 Mon Sep 17 00:00:00 2001 From: Jedd Morgan <45512892+JR-Morgan@users.noreply.github.com> Date: Tue, 10 Dec 2024 15:14:54 +0000 Subject: [PATCH 2/2] aliasing --- ui/src/graphql/user.gql | 2 +- ui/src/graphql/userById.gql | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/src/graphql/user.gql b/ui/src/graphql/user.gql index 6c44b822..0cfca66b 100644 --- a/ui/src/graphql/user.gql +++ b/ui/src/graphql/user.gql @@ -1,5 +1,5 @@ query { - activeUser { + user:activeUser { id email name diff --git a/ui/src/graphql/userById.gql b/ui/src/graphql/userById.gql index a49b6358..526408a6 100644 --- a/ui/src/graphql/userById.gql +++ b/ui/src/graphql/userById.gql @@ -1,5 +1,5 @@ query User($id: String!) { - otherUser(id: $id) { + user:otherUser(id: $id) { id name bio