-
Notifications
You must be signed in to change notification settings - Fork 27
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
grdi export one health enterics #441
Conversation
* Needs testing
* return ""; | ||
* } | ||
* ``` | ||
* TODO is there any need for additional complexities in getMappedField? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ddooley I am just copy-pasting vals for the most part (with the exception of some trimming I also need advice on below)
); | ||
const valsToCheck = headerNamesToCheck.map((headerName) => { | ||
const valToCheck = inputRow[sourceFieldNameMap[headerName]]; | ||
// TODO trim because copy pasting from excel == '\r\n'; wider issue? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
web/templates/grdi/export.js
Outdated
@@ -73,6 +73,7 @@ export default { | |||
// ['gene_name_2', []], | |||
// ['diagnostic_PCR_CT_value_2', []], | |||
// ['description',[]], | |||
// TODO there are additional fields now; what order? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ddooley Does the existing biosample need to be updated too?
web/templates/grdi/export.js
Outdated
@@ -104,4 +105,397 @@ export default { | |||
return outputMatrix; | |||
}, | |||
}, | |||
|
|||
// TODO I see other refs to NCBI_BioSample in project; good name? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I should go through and test everything once more |
* Also update schema
* Need to update enums
* Remove obsolete mapping obj
let atLeastOneWideVal = false; | ||
for (const [i, longHeader] of longHeadersArr.entries()) { | ||
let wideHeader = antibiotic.concat('_', longHeader); | ||
if (longHeader === 'vendor') wideHeader += '_name'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add comment
outputMatrix.push(longRow); | ||
} | ||
} | ||
// Ensures a row is still added if no antibiotic info is present |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this necessary?
No description provided.