Fix the view for accounts.

This commit is contained in:
James Cole
2014-11-28 07:40:04 +01:00
parent 935276af88
commit 5a920d5efd
5 changed files with 75 additions and 27 deletions

View File

@@ -1,12 +1,12 @@
$(function () {
if (typeof(googleLineChart) == "function" && typeof accountID != 'undefined') {
googleLineChart('chart/account/' + accountID, 'overview-chart');
if (typeof(googleLineChart) == "function" && typeof accountID != 'undefined' && typeof view != 'undefined') {
googleLineChart('chart/account/' + accountID + '/' + view, 'overview-chart');
}
//
if (typeof(googleSankeyChart) == 'function' && typeof accountID != 'undefined') {
googleSankeyChart('chart/sankey/' + accountID + '/out', 'account-out-sankey');
googleSankeyChart('chart/sankey/' + accountID + '/in', 'account-in-sankey');
if (typeof(googleSankeyChart) == 'function' && typeof accountID != 'undefined' && typeof view != 'undefined') {
googleSankeyChart('chart/sankey/' + accountID + '/out' + '/' + view, 'account-out-sankey');
googleSankeyChart('chart/sankey/' + accountID + '/in' + '/' + view, 'account-in-sankey');
}
});