Skip to content

Commit

Permalink
fixed the issue that the exports doesn't work if the all slides are C…
Browse files Browse the repository at this point in the history
…ytology: 'Not cell block' or 'Not H&E Stained Slide'.
  • Loading branch information
nanli-emory committed Oct 6, 2023
1 parent 63d41c0 commit d0df77e
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion handlers/dataHandlers.js
Original file line number Diff line number Diff line change
Expand Up @@ -786,12 +786,22 @@ SeerService.collectionDataExports = async function(req, res, next) {
const csvData = [];

// first?, second?, third?
const {first, second, third} = data.relativeInformative;
// const {first, second, third} = data.relativeInformative;

data.slides.forEach((sid)=>{
const slideData = slideMap.get(sid);
// Relative Informativeness need to add
const tumorPresent = slideData.csvData.tumorPresent;

// get the ranked slide id
let first = null;
let second = null;
let third = null;
if (data.relativeInformative) {
first = data.relativeInformative.first;
second = data.relativeInformative.second;
third = data.relativeInformative.third;
}
if (tumorPresent == 1 && sid == first) {
slideData.csvData.relativeInformativeness = '1';
} else if (tumorPresent == 1 && sid == second) {
Expand Down

0 comments on commit d0df77e

Please sign in to comment.