From 7d49a0aa43ed32d38118b6e781ec27f0f518be74 Mon Sep 17 00:00:00 2001 From: tibvdm Date: Tue, 16 Apr 2024 11:11:45 +0200 Subject: [PATCH] test --- app/controllers/mpa/pept2data_controller.rb | 2 +- app/views/mpa/pept2data/pept2data.json.jbuilder | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/controllers/mpa/pept2data_controller.rb b/app/controllers/mpa/pept2data_controller.rb index 6f0ad0e..4996d86 100644 --- a/app/controllers/mpa/pept2data_controller.rb +++ b/app/controllers/mpa/pept2data_controller.rb @@ -15,12 +15,12 @@ def pept2data # Request the suffix array search service @response = search(peptides, equate_il).uniq - @response["equated_IL"] = equate_il # Collect all lca's to look up the lineages taxa = [] @response.each do |result| taxa.append(result["lca"]) + result["equate"] = equate_il end # Retrieve all lineages at once diff --git a/app/views/mpa/pept2data/pept2data.json.jbuilder b/app/views/mpa/pept2data/pept2data.json.jbuilder index 3e738de..c989c56 100644 --- a/app/views/mpa/pept2data/pept2data.json.jbuilder +++ b/app/views/mpa/pept2data/pept2data.json.jbuilder @@ -1,4 +1,5 @@ json.peptides @response do |peptide| + json.equate peptide["equate"] json.sequence peptide["sequence"] json.lca peptide["lca"] json.lineage @lineages[peptide["lca"].to_i] @@ -7,4 +8,3 @@ json.peptides @response do |peptide| json.data peptide["fa"]["data"] end end -json.equated_IL @response["equated_IL"]