-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(backend, website): Use version comments field for revocations as…
… well. (#2352) * Rename version_comment metadata field versionComment for internal consistency. * Add a versionComment field to the revoke endpoint, make sure versionComment is added to get-released-data output. * Add DB schema updates as new flyway version. * Add revocation comment to backend tests * Add comment option to revoke button * Add version comments to revocationentrydatatable and not just preview.
- Loading branch information
1 parent
d168fe0
commit a9fa920
Showing
17 changed files
with
206 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 30 additions & 0 deletions
30
backend/src/main/resources/db/migration/V1.1__add_field.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
alter table sequence_entries add column version_comment text; | ||
|
||
drop view if exists sequence_entries_view; | ||
|
||
create view sequence_entries_view as | ||
select | ||
se.*, | ||
sepd.started_processing_at, | ||
sepd.finished_processing_at, | ||
sepd.processed_data as processed_data, | ||
sepd.processed_data || em.joint_metadata as joint_metadata, | ||
sepd.errors, | ||
sepd.warnings, | ||
case | ||
when se.released_at is not null then 'APPROVED_FOR_RELEASE' | ||
when se.is_revocation then 'AWAITING_APPROVAL' | ||
when sepd.processing_status = 'IN_PROCESSING' then 'IN_PROCESSING' | ||
when sepd.processing_status = 'HAS_ERRORS' then 'HAS_ERRORS' | ||
when sepd.processing_status = 'FINISHED' then 'AWAITING_APPROVAL' | ||
else 'RECEIVED' | ||
end as status | ||
from | ||
sequence_entries se | ||
left join sequence_entries_preprocessed_data sepd on | ||
se.accession = sepd.accession | ||
and se.version = sepd.version | ||
and sepd.pipeline_version = (select version from current_processing_pipeline) | ||
left join external_metadata_view em on | ||
se.accession = em.accession | ||
and se.version = em.version; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.