Rename row 'x' to 'date', swap expenses and revenues.

This commit is contained in:
Alexis Lahouze 2017-07-04 20:35:18 +02:00
parent ab14ead2dc
commit 0f547a532c

View File

@ -42,14 +42,14 @@ var balanceChartModule = angular.module('balanceChartModule', [
Balances.query({
id: $routeParams.accountId
}, function(results) {
var headers = [['x', 'balances', 'expenses', 'revenues']];
var headers = [['date', 'balances', 'expenses', 'revenues']];
var rows = results.map(function(result) {
return [
result.operation_date,
result.balance,
result.revenues,
result.expenses
result.expenses,
result.revenues
];
});
@ -71,7 +71,7 @@ var balanceChartModule = angular.module('balanceChartModule', [
height: 500,
},
data: {
x: 'x',
x: 'date',
rows: [],
axes: {
expenses: 'y2',