From 82530ac9e6e8599d44b272fa37fb8a08049b62af Mon Sep 17 00:00:00 2001 From: Chaoran Chen Date: Fri, 5 Apr 2024 09:10:35 +0000 Subject: [PATCH] feat(backend): return the group id in /get-data-to-edit --- .../src/main/kotlin/org/loculus/backend/api/SubmissionTypes.kt | 1 + .../backend/service/submission/SubmissionDatabaseService.kt | 2 ++ 2 files changed, 3 insertions(+) diff --git a/backend/src/main/kotlin/org/loculus/backend/api/SubmissionTypes.kt b/backend/src/main/kotlin/org/loculus/backend/api/SubmissionTypes.kt index 9fe26a9405..15dcaa2604 100644 --- a/backend/src/main/kotlin/org/loculus/backend/api/SubmissionTypes.kt +++ b/backend/src/main/kotlin/org/loculus/backend/api/SubmissionTypes.kt @@ -105,6 +105,7 @@ data class SequenceEntryVersionToEdit( override val accession: Accession, override val version: Version, val status: Status, + val groupId: Int, val processedData: ProcessedData, val originalData: OriginalData, @Schema(description = "The preprocessing will be considered failed if this is not empty") diff --git a/backend/src/main/kotlin/org/loculus/backend/service/submission/SubmissionDatabaseService.kt b/backend/src/main/kotlin/org/loculus/backend/service/submission/SubmissionDatabaseService.kt index b1e7b5ca74..4906d9c3af 100644 --- a/backend/src/main/kotlin/org/loculus/backend/service/submission/SubmissionDatabaseService.kt +++ b/backend/src/main/kotlin/org/loculus/backend/service/submission/SubmissionDatabaseService.kt @@ -723,6 +723,7 @@ class SubmissionDatabaseService( val selectedSequenceEntry = SequenceEntriesView.slice( SequenceEntriesView.accessionColumn, SequenceEntriesView.versionColumn, + SequenceEntriesView.groupIdColumn, SequenceEntriesView.statusColumn, SequenceEntriesView.processedDataColumn, SequenceEntriesView.originalDataColumn, @@ -747,6 +748,7 @@ class SubmissionDatabaseService( accession = selectedSequenceEntry[SequenceEntriesView.accessionColumn], version = selectedSequenceEntry[SequenceEntriesView.versionColumn], status = Status.fromString(selectedSequenceEntry[SequenceEntriesView.statusColumn]), + groupId = selectedSequenceEntry[SequenceEntriesView.groupIdColumn], processedData = compressionService.decompressSequencesInProcessedData( selectedSequenceEntry[SequenceEntriesView.processedDataColumn]!!, organism,