I have the following script:
var dataSet;
d3.json("/TableData", function(error, json) {
if (error) return console.warn(error);
dataSet = json;
});
$('#data-table').dynatable({
dataset: {
records: dataSet
}
});
/TableData
is a sqlalchemy call to a db which returns:
{
"data": [
{
"Type": "Turbine",
"Seconds": 170,
},
{
"Type": "Turbine",
"Seconds": 75435,
}]}
I don't get any errors with the console but nothing shows up in the flask
website? if I go to http://127.0.0.1/TableData
I can see the table data.