Support download as TSV File (#4445)

This commit is contained in:
Tsuyoshi Yoshizawa
2019-12-26 23:16:48 +09:00
committed by Levko Kravets
parent f420e02cee
commit c2b39db03e
7 changed files with 70 additions and 19 deletions

View File

@@ -27,6 +27,7 @@ export function QueryControlDropdown(props) {
)}
<Menu.Item>
<QueryResultsLink
fileType="csv"
disabled={props.queryExecuting || !props.queryResult.getData || !props.queryResult.getData()}
query={props.query}
queryResult={props.queryResult}
@@ -35,6 +36,17 @@ export function QueryControlDropdown(props) {
<Icon type="file" /> Download as CSV File
</QueryResultsLink>
</Menu.Item>
<Menu.Item>
<QueryResultsLink
fileType="tsv"
disabled={props.queryExecuting || !props.queryResult.getData || !props.queryResult.getData()}
query={props.query}
queryResult={props.queryResult}
embed={props.embed}
apiKey={props.apiKey}>
<Icon type="file" /> Download as TSV File
</QueryResultsLink>
</Menu.Item>
<Menu.Item>
<QueryResultsLink
fileType="xlsx"