File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -3,7 +3,6 @@ require('dotenv').config()
33var createError = require ( 'http-errors' )
44var express = require ( 'express' )
55var cors = require ( 'cors' )
6- // var path = require('path')
76var cookieParser = require ( 'cookie-parser' )
87var logger = require ( 'morgan' )
98var proxy = require ( 'express-http-proxy' )
@@ -18,8 +17,6 @@ app.use(logger('dev'))
1817app . use ( express . json ( ) )
1918app . use ( express . urlencoded ( { extended : false } ) )
2019app . use ( cookieParser ( ) )
21- // No need for static dir for now as we're building an API only app
22- // app.use(express.static(path.join(__dirname, 'public')));
2320
2421app . use ( '/' , indexRouter )
2522
Original file line number Diff line number Diff line change @@ -13,8 +13,6 @@ const APP_VERSION = 'v1'
1313
1414/* Gets the schema from a GraphQL*/
1515async function getGraphQLTableSchema ( resource_id ) {
16- // console.log("ResourceID: " + resource_id)
17-
1816 const queryForSchema = gql `
1917 {
2018 __type(name: "${ resource_id } ") {
File renamed without changes.
Original file line number Diff line number Diff line change 11< pre >
2-
3-
4-
5-
62< h3 > Manual download file from query test</ h3 > :
73
84< button id ="b-json " download ="dwnl.json "> JSON</ button >
@@ -54,11 +50,8 @@ <h3>Manual download file from query test</h3>:
5450 link . download = filename ;
5551
5652 document . body . appendChild ( link ) ;
57-
5853 link . click ( ) ;
59-
6054 document . body . removeChild ( link ) ;
61-
6255 return response . body
6356 } catch ( err ) {
6457 console . error ( `Error: ${ err } ` )
@@ -67,7 +60,7 @@ <h3>Manual download file from query test</h3>:
6760
6861document . getElementById ( 'b-json' ) . addEventListener ( 'click' , async _ => createListener ( '/v1/download' ) )
6962document . getElementById ( 'b-csv' ) . addEventListener ( 'click' , async _ => createListener ( '/v1/download?format=csv' ) )
70- document . getElementById ( 'b-tsv' ) . addEventListener ( 'click' , async _ => createListener ( '/v1/download?format=csv&field_separator=%09 ' ) )
63+ document . getElementById ( 'b-tsv' ) . addEventListener ( 'click' , async _ => createListener ( '/v1/download?format=tsv ' ) )
7164document . getElementById ( 'b-xlsx' ) . addEventListener ( 'click' , async _ => createListener ( '/v1/download?format=xlsx' ) )
7265
7366document . getElementById ( 'json' ) . value = QUERY
You can’t perform that action at this time.
0 commit comments