Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hide single cell udf options if the project is not single cell #896

Merged
merged 3 commits into from
Nov 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions run_dir/design/project_samples.html
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,10 @@ <h4>Key Project Information</h4>
<dt>Library Method</dt> <dd id="library_construction_method">-</dd>
<dt>Library Prep Option</dt> <dd id="library_prep_option">-</dd>
<dt>BioAnalyzer Run Required</dt> <dd id="bioanalyzer_run_required">-</dd>
<dt>SC prep option (Hashing)</dt> <dd><span id="library_prep_option_single_cell_(hashing)">-</span></dd>
<dt>SC prep option (CITE)</dt> <dd><span id="library_prep_option_single_cell_(cite)">-</span></dd>
<dt>SC prep option (VDJ)</dt> <dd><span id="library_prep_option_single_cell_(vdj)">-</span></dd>
<dt>SC prep option (Feature)</dt> <dd><span id="library_prep_option_single_cell_(feature)">-</span></dd>
<dt hidden class="single_cell_udf">SC prep option (Hashing)</dt> <dd hidden class="single_cell_udf"><span id="library_prep_option_single_cell_(hashing)">-</span></dd>
<dt hidden class="single_cell_udf">SC prep option (CITE)</dt> <dd hidden class="single_cell_udf"><span id="library_prep_option_single_cell_(cite)">-</span></dd>
<dt hidden class="single_cell_udf">SC prep option (VDJ)</dt> <dd hidden class="single_cell_udf"><span id="library_prep_option_single_cell_(vdj)">-</span></dd>
<dt hidden class="single_cell_udf">SC prep option (Feature)</dt> <dd hidden class="single_cell_udf"></dd><span id="library_prep_option_single_cell_(feature)">-</span></dd>
<dt>Last updated</dt> <dd><span id="last_update"></span></dd>
</dl>
<hr>
Expand Down
7 changes: 7 additions & 0 deletions run_dir/static/js/project_samples.js
Original file line number Diff line number Diff line change
Expand Up @@ -316,6 +316,13 @@ function load_all_udfs(){
$('#loading_spinner').hide();
$('#page_content').show();

// Display hidden single cell section if application is single cell
let application = 'application' in data ? data['application'] : '';

if(application.includes('single cell')){
$('.single_cell_udf').removeAttr('hidden');
}

// Project not found
if(Object.getOwnPropertyNames(data).length == 0){
$('#page_content').html('<h1>Error - Project Not Found</h1><div class="alert alert-danger">Oops! Sorry about that, we can\'t find the project <strong>'+project+'</strong></div>');
Expand Down
Loading