Add genome and feature group creation to Protein Structure grid#1221
Open
olsonanl wants to merge 2 commits into
Open
Add genome and feature group creation to Protein Structure grid#1221olsonanl wants to merge 2 commits into
olsonanl wants to merge 2 commits into
Conversation
…Structure Grid
Issue
Users viewing the Structures tab on taxonomy pages could not create genome groups or feature groups from their selections because
structure_data was not in the validContainerTypes for the AddGroup action.
Files Modified
1. public/js/p3/widget/GridContainer.js (bvbrc_website)
Change 1a: Added structure_data to the validContainerTypes array for the AddGroup action (line ~1519):
validContainerTypes: ['genome_data', 'sequence_data', 'feature_data', 'protein_data',
'transcriptomics_experiment_data', 'transcriptomics_gene_data', 'spgene_data', 'structure_data']
Change 1b: Added handling for structure_data in the type determination logic (lines ~1535-1537):
} else if (containerWidget.containerType == 'structure_data') {
type = 'feature_group';
}
2. public/js/p3/widget/SelectionToGroup.js (bvbrc_website)
Added structure_data to the conversionTypes object to enable the type selector dropdown:
conversionTypes: {
feature_data: [{ label: 'Feature', value: 'feature_group' }, { label: 'Genome', value: 'genome_group' }],
structure_data: [{ label: 'Feature', value: 'feature_group' }, { label: 'Genome', value: 'genome_group' }]
},
How It Works
1. The GROUP icon now appears in the action bar when selecting protein structures
2. When clicked, the SelectionToGroup widget detects inputType is structure_data and shows a dropdown with "Feature" and "Genome"
options
3. Users can create either a Feature Group (using feature_id) or a Genome Group (using genome_id) from selected structures
3 tasks
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
structure_datato AddGroup action validContainerTypes in GridContainer.jsstructure_datatype handling to create feature groups by defaultstructure_datato conversionTypes in SelectionToGroup.js to enable dropdown selection between Feature and Genome groupsThis allows users viewing the Structures tab on taxonomy pages to:
This PR should NOT be merged until the corresponding Data API fixes are installed.
The Data API changes add access control filtering for
protein_structurequeries using a Solr cross-collection join on the genome collection. Without those changes, protein structures from private genomes may be exposed to unauthorized users.Test plan
🤖 Generated with Claude Code