Skip to content

Commit

Permalink
update schema and queries with new showDiff variable (#624)
Browse files Browse the repository at this point in the history
* update schema and queries with new showDiff variable

* updated schema and queries per PR comments
  • Loading branch information
studioswong authored Nov 11, 2021
1 parent 846597b commit 01bf8ee
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/apollo/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { ApolloClient, InMemoryCache, createHttpLink } from '@apollo/client';

const link = createHttpLink({
// our graphql endpoint, normally here: http://localhost:4142/graphql
uri: 'http://localhost:4000/graphql',
uri: 'http://localhost:4141/graphql',
fetch,
});

Expand Down
4 changes: 2 additions & 2 deletions src/apollo/queries.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ export const GET_RUN_METADATA = gql`

/** query for collapsable run details component */
export const GET_RUN_TRACKING_DATA = gql`
query getRunTrackingData($runs: [ID]!) {
runTrackingData(runIDs: $runs) {
query getRunTrackingData($runs: [ID]!, $showDiff: Boolean) {
runTrackingData(runIDs: $runs, showDiff: $showDiff) {
datasetName
datasetType
data
Expand Down
2 changes: 1 addition & 1 deletion src/apollo/schema.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ schema {
type Query {
runsList: [Run]!
runMetadata(runIDs: [ID]!): [Run!]!
runTrackingData(runIDs: [ID]!): [TrackingDataset]!
runTrackingData(runIDs: [ID]!, showDiff: Boolean = false): [TrackingDataset]! # showDiff as true will return all tracked fields amongst compared runs
}

type Subscription {
Expand Down
5 changes: 4 additions & 1 deletion src/apollo/schema.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,10 @@ const typeDefs = gql`
type Query {
runsList: [Run]!
runMetadata(runIDs: [ID]!): [Run!]!
runTrackingData(runIDs: [ID]!): [TrackingDataset]!
runTrackingData(
runIDs: [ID]!
showDiff: Boolean = false
): [TrackingDataset]!
}
type Subscription {
Expand Down

0 comments on commit 01bf8ee

Please sign in to comment.