Skip to content

Commit

Permalink
feat: Diff logging for deposition page (#1467)
Browse files Browse the repository at this point in the history
  • Loading branch information
bchu1 authored Jan 16, 2025
1 parent 4dca0a6 commit 3947969
Show file tree
Hide file tree
Showing 4 changed files with 505 additions and 12 deletions.
15 changes: 5 additions & 10 deletions frontend/packages/data-portal/app/graphql/getDatasetsDiffer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,16 +63,11 @@ export function logIfHasDiff(
delete group.count
}
v2.distinctReconstructionSoftwares.aggregate =
v2.distinctReconstructionSoftwares
.aggregate!.filter(
// Bug in APIv2 returns this as a duplicate of 'AreTomo3 v2.0.4'
(group) => group.groupBy?.reconstructionSoftware !== 'AreTomo3_v2.0.4',
)
.sort((groupA, groupB) =>
String(groupA.groupBy!.reconstructionSoftware).localeCompare(
String(groupB.groupBy!.reconstructionSoftware),
),
)
v2.distinctReconstructionSoftwares.aggregate!.sort((groupA, groupB) =>
String(groupA.groupBy!.reconstructionSoftware).localeCompare(
String(groupB.groupBy!.reconstructionSoftware),
),
)
for (const group of v2.distinctObjectNames.aggregate!) {
delete group.count
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,14 @@ const GET_DEPOSITION_BY_ID = gql(`
count
groupBy {
annotationMethod
annotationSoftware
}
}
}
annotationMethodAndMethodLinksCombinations: annotationsAggregate {
aggregate {
count
groupBy {
annotationMethod
methodType
methodLinks {
link
Expand All @@ -107,7 +114,6 @@ const GET_DEPOSITION_BY_ID = gql(`
id
title
organismName
datasetPublications
keyPhotoThumbnailUrl
authors(orderBy: { authorListOrder: asc }) {
edges {
Expand Down
Loading

0 comments on commit 3947969

Please sign in to comment.