From 0a9a803646171e1bc364907118ab29201dfb41b4 Mon Sep 17 00:00:00 2001 From: josecolella Date: Mon, 30 Jun 2014 16:36:01 +0200 Subject: [PATCH] Add text description to import panel --- visualization/static/visualization/js/app.js | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/visualization/static/visualization/js/app.js b/visualization/static/visualization/js/app.js index 4615a35..37a9253 100644 --- a/visualization/static/visualization/js/app.js +++ b/visualization/static/visualization/js/app.js @@ -71,7 +71,7 @@ var manageImportOpen = function() { } else { dropzone.fadeIn("slow"); - dropzone.prepend("
Drop or Click on the panel below to import your data sets (Accepted Files: excel [xlsx, xls], json, csv, txt)
"); + dropzone.prepend("
Drop or Click on the panel below to import your data sets (Accepted Files: excel [xlsx, xls], json, csv, xml, txt)
"); } @@ -324,7 +324,7 @@ var addDataGrid = function(data) { return $('').addClass('changeType').html('\u25BC'); }; - if (dataTableDiv.length == 0) { + if (dataTable.length == 0) { workspace.append('
'); $("#dataTable").handsontable({ minRows: 20, @@ -357,10 +357,10 @@ var addDataGrid = function(data) { }); - } else if(dataTableDiv.is(":visible")){ - dataTableDiv.fadeOut(); + } else if(dataTable.is(":visible")){ + dataTable.fadeOut(); } else { - dataTableDiv.fadeIn(); + dataTable.fadeIn(); } @@ -727,6 +727,7 @@ $(function() { processJSONFileContents(url); break; case 'csv': + case 'txt': console.log('Its a CSV file'); processCSVFileContents(url); break;