Files
firefly-iii/public/js/reports.js

32 lines
776 B
JavaScript
Raw Normal View History

2015-02-23 20:25:48 +01:00
if (typeof(google) != 'undefined') {
google.setOnLoadCallback(drawChart);
}
2015-05-08 17:13:49 +02:00
function drawChart() {
2015-05-15 21:01:24 +02:00
googleColumnChart('chart/reports/income-expenses/' + year + shared, 'income-expenses-chart');
googleColumnChart('chart/reports/income-expenses-sum/' + year + shared, 'income-expenses-sum-chart')
2015-05-08 17:13:49 +02:00
2015-05-15 21:01:24 +02:00
googleStackedColumnChart('chart/budgets/spending/' + year + shared, 'budgets');
2015-05-08 17:13:49 +02:00
}
$(function () {
$('.openModal').on('click', openModal);
});
function openModal(e) {
"use strict";
var target = $(e.target).parent();
var URL = target.attr('href');
$.get(URL).success(function (data) {
$('#defaultModal').empty().html(data).modal('show');
}).fail(function () {
alert('Could not load data.');
});
2015-03-10 17:26:31 +01:00
return false;
}