This should fix most Javascript errors.

This commit is contained in:
James Cole
2017-01-02 10:34:01 +01:00
parent 36f1b6a834
commit f8268a864b
26 changed files with 102 additions and 51 deletions

View File

@@ -8,11 +8,13 @@
* See the LICENSE file for details.
*/
/** global: Tour, showTour, accountFrontpageUri, billCount, accountExpenseUri, accountRevenueUri */
$(function () {
"use strict";
// do chart JS stuff.
drawChart();
if (showTour) {
if (showTour == true) {
$.getJSON('json/tour').done(function (data) {
var tour = new Tour(
{
@@ -55,6 +57,9 @@ function getBoxAmounts() {
"use strict";
var boxes = ['in', 'out', 'bills-unpaid', 'bills-paid'];
for (var x in boxes) {
if (!boxes.hasOwnProperty(x)) {
continue;
}
var box = boxes[x];
$.getJSON('json/box/' + box).done(putData).fail(failData);
}