tabletop.js

Markers in leaflet map using tabletop.js Why its not working?

点点圈 提交于 2020-02-25 04:11:44
问题 I'm noob to javascript... I tried to find a solution to a problem on a similar thread, but I don't know why it doesn't work in my case. I can't comment there so I add new question. All my code is here: Link to Fiddle When I changed code with example, the map stopped showing. Where have I done the mistake? Thank You for helping me. Main part of js is like this: function myFunction() { // Add MAP var map = L.map('map').setView([54.151, 17.823], 9); var basemap = L.tileLayer('http://{s}.tile.osm

Get data from a Promise

天涯浪子 提交于 2020-01-16 16:24:48
问题 I'm working with Tabletop.js to get data from my Google Spreadsheet. In the function, I've invoked a Promise. The only problem is I can't get the data(which is an Array) out of the function. I have the following code: function getData() { return new Promise((resolve) => { Tabletop.init({key: publicSpreadsheetUrl, callback: showInfo, simpleSheet: true}) resolve('Done'); }) } let arrayWithData = []; function showInfo (data, tabletop) { console.log('showInfo active'); arrayWithData.push(...data)

How to setup service to pass google sheet IDs? AngularJS

岁酱吖の 提交于 2019-12-19 17:04:31
问题 I am building a small widget using angular that takes Google sheet Ids given by user and publishes the output in nice json format. The problem is that my code does nothing. There are no errors in the console and when I add ID nothing happens I guess the problem is in service.js angular.module('adf.widget.charts') .service('chartService', function(){ return { getUrl: function(key){ var googleSheetkey = key } } return googleSheetkey }); edit.html (to add Sheet ID) <form role="form"> <div class=

How to setup service to pass google sheet IDs? AngularJS

梦想与她 提交于 2019-12-19 17:04:12
问题 I am building a small widget using angular that takes Google sheet Ids given by user and publishes the output in nice json format. The problem is that my code does nothing. There are no errors in the console and when I add ID nothing happens I guess the problem is in service.js angular.module('adf.widget.charts') .service('chartService', function(){ return { getUrl: function(key){ var googleSheetkey = key } } return googleSheetkey }); edit.html (to add Sheet ID) <form role="form"> <div class=

Using Google Spreadsheet as JSON file using tabletop to datatables returns error

懵懂的女人 提交于 2019-12-13 01:18:59
问题 I'm a relative newbie when it comes to coding, especially javascript. I currently am trying to populate a table from a google spreadsheet, which will update when the spreadsheet is. I followed this tutorial word for word (basically all you need to do is replace the key with your own to specify your spreadsheet, and make sure its both published and public, which I've done) http://dataforradicals.com/the-absurdly-illustrated-guide-to-sortable-searchable-online-data-tables/ I just get a bad

How to pass data values from serivces to controller

非 Y 不嫁゛ 提交于 2019-12-11 10:10:41
问题 I am trying to make a widget for angular dashboard framework, sample widgets can be found here. I am struck at a point where I am trying to integrate tabletop.js in the widget. I somehow cannot get the data in the controller. my code: use strict; angular.module('adf.widget.charts', ['adf.provider', 'highcharts-ng']) .config(function(dashboardProvider){ var widget = { templateUrl: '{widgetsPath}/charts/src/view.html', reload: true, resolve: { /* @ngInject */ urls: function(chartService, config

Google Spreadsheet not accessible from miso dataset or tabletop

我只是一个虾纸丫 提交于 2019-12-11 04:09:37
问题 I recently asked this question about why my google spreadsheet data wasnt being called, even though the example one worked Using Google Spreadsheet as JSON file using tabletop to datatables returns error I tried a completely different library as I thought it was a problem with tabletop.js... I tried this example using Miso dataset... http://misoproject.com/dataset/tutorials/googlespreadsheets I got the example working perfectly but as soon as I switch in my spreadsheet key it stops working!

How to add markers to leaflet map with tabletop.js?

╄→гoц情女王★ 提交于 2019-12-02 13:50:12
问题 I'm using this quite nice guide to add markers from a Google sheet to a basic leaflet.js map: https://rdrn.me/leaflet-maps-google-sheets/ The problem is, using these code snippets here i get all the data logged and returned in the console, but none of the points appear on the map itself. This is probably some really basic JavaScript issue that i'm not able to see. Sorry, still learning. Here's a jfiddle, linking to a demo sheets with one marker point https://jsfiddle.net/xfs19cz7/1/ with the

How to add markers to leaflet map with tabletop.js?

左心房为你撑大大i 提交于 2019-12-02 10:56:15
I'm using this quite nice guide to add markers from a Google sheet to a basic leaflet.js map: https://rdrn.me/leaflet-maps-google-sheets/ The problem is, using these code snippets here i get all the data logged and returned in the console, but none of the points appear on the map itself. This is probably some really basic JavaScript issue that i'm not able to see. Sorry, still learning. Here's a jfiddle, linking to a demo sheets with one marker point https://jsfiddle.net/xfs19cz7/1/ with the map part: function init() { Tabletop.init({ key: '*url to gsheets here*', callback: myFunction,

How to setup service to pass google sheet IDs? AngularJS

别说谁变了你拦得住时间么 提交于 2019-12-01 16:34:29
I am building a small widget using angular that takes Google sheet Ids given by user and publishes the output in nice json format. The problem is that my code does nothing. There are no errors in the console and when I add ID nothing happens I guess the problem is in service.js angular.module('adf.widget.charts') .service('chartService', function(){ return { getUrl: function(key){ var googleSheetkey = key } } return googleSheetkey }); edit.html (to add Sheet ID) <form role="form"> <div class="form-group"> <label for="sample">Sample</label> <input type="text" class="form-control" id="sample" ng