@@ -464,17 +464,7 @@ WOQLClient.prototype.updateCSV = function(csv_path, commit_msg, gtype, gid) {
464464WOQLClient . prototype . getCSV = function ( csv_name , download , gtype , gid ) {
465465 let options = { } , filePath
466466 options . name = csv_name ;
467- return this . dispatch ( CONST . GET_CSV , this . connectionConfig . csvURL ( gtype , gid ) , options ) . then ( results => {
468- if ( download ) {
469- const url = window . URL . createObjectURL ( new Blob ( [ results ] ) ) ;
470- const link = document . createElement ( 'a' ) ;
471- link . href = url ;
472- link . setAttribute ( 'download' , csv_name ) ;
473- document . body . appendChild ( link ) ;
474- link . click ( ) ;
475- }
476- return results ;
477- } )
467+ return this . dispatch ( CONST . GET_CSV , this . connectionConfig . csvURL ( gtype , gid ) , options )
478468}
479469
480470/**
@@ -525,12 +515,14 @@ WOQLClient.prototype.info = function() {
525515 * @param {WOQLQuery } woql is a "woql query object"
526516 * @param {string } commit_msg - if the query contains any updates, it should include a textual message describing the reason for the update
527517 */
528- WOQLClient . prototype . query = function ( woql , commit_msg ) {
518+ WOQLClient . prototype . query = function ( woql , commit_msg , all_witnesses ) {
519+ all_witnesses = all_witnesses || false
529520 commit_msg = commit_msg || 'Commit generated with javascript client without message'
530521 if ( woql && woql . json && ( ! woql . containsUpdate ( ) || commit_msg ) ) {
531522 woql . context ( this . connection . getContextForOutboundQuery ( woql , this . db ( ) , this . organization ( ) ) )
532523 let doql = woql . containsUpdate ( ) ? this . generateCommitInfo ( commit_msg ) : { }
533524 doql . query = woql . json ( )
525+ if ( all_witnesses ) doql . all_witnesses = true
534526 return this . dispatch ( CONST . WOQL_QUERY , this . connectionConfig . queryURL ( ) , doql )
535527 }
536528 let errmsg = `WOQL query parameter error`
0 commit comments