-
Notifications
You must be signed in to change notification settings - Fork 30
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
add all annotated variants download button to api access page #1208
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||
---|---|---|---|---|---|---|---|---|
|
@@ -82,6 +82,21 @@ const DownloadButtonGroups: React.FunctionComponent<{ | |||||||
buttonText="Cancer Gene List" | ||||||||
/> | ||||||||
) : null} | ||||||||
{props.data.hasAllAnnotatedVariants && ( | ||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can we check if the user's authority list includes ROLE_PREMIUM_API? I think currently, the button is visible to ROLE_DATA_DOWNLOAD. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Do we want the user to have both ROLE_DATA_DOWNLOAD and ROLE_PREMIUM_API? I think if ROLE_PREMIUM_API supersedes ROLE_DATA_DOWNLOAD we can probably add the private endpoints to role PREMIUM_API, right? Or maybe we want to open up allAnnotatedVariants and allActionableVariants to ROLE_DATA_DOWNLOAD. Seems weird to me that we would allow someone to download the entire data dump but not the full list of annotated variants. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I agree that data download role should give you access to the annotated variants files since we already give them the SQL dump with this role. Can you just update so that if the user has data download or is a premium user, then show the data download section. You don't need to explicitly check if premium user for allActionable and allAnnotated file buttons. ( oncokb-public/src/main/webapp/app/pages/apiAccessGroup/APIAccessPage.tsx Lines 291 to 293 in 1fc4dd5
|
||||||||
<AuthDownloadButton | ||||||||
className={BUTTON_CLASS_NAME} | ||||||||
fileName={`all_annotated_variants_${props.data.version}.tsv`} | ||||||||
getDownloadData={async () => { | ||||||||
const data = await oncokbClient.utilsAllAnnotatedVariantsTxtGetUsingGET( | ||||||||
{ | ||||||||
version: props.data.version, | ||||||||
} | ||||||||
); | ||||||||
return data; | ||||||||
}} | ||||||||
buttonText="All Annotated Variants" | ||||||||
/> | ||||||||
)} | ||||||||
{props.data.hasAllActionableVariants ? ( | ||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think this should be checking props.data.hasSqlDump right? I think someone had a typo here before. |
||||||||
<> | ||||||||
<AuthDownloadButton | ||||||||
|
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.
Can we also include allActionableVariantsTxt as well. We sometimes get that request too and should be quick to add?