Firefly III: a personal finances manager
PHP accountingbudgetbudgetingbudgetscash-flowcashflowcredit-carddockerexpensesfinancefinancesfinanciallinuxmoneypaycheckpersonal-financephpphp7
Fix #1061
James Cole36c8275f5efd
diff --git a/public/js/ff/accounts/show.js b/public/js/ff/accounts/show.jsindex 3a3492d6ee..3b1ca6ce87 100644--- a/public/js/ff/accounts/show.js+++ b/public/js/ff/accounts/show.js@@ -96,7 +96,7 @@ function sortStop(event, ui) {});// do extra animation when done?- $.post('transactions/reorder', {items: submit, date: thisDate});+ $.post('transactions/reorder', {items: submit, date: thisDate, _token: token});current.animate({backgroundColor: "#5cb85c"}, 200, function () {$(this).animate({backgroundColor: originalBG}, 200);diff --git a/public/js/ff/budgets/index.js b/public/js/ff/budgets/index.jsindex a9450a77dc..db07e9088d 100644--- a/public/js/ff/budgets/index.js+++ b/public/js/ff/budgets/index.js@@ -120,7 +120,7 @@ function updateBudgetedAmounts(e) {// send a post to Firefly to update the amount:var newUri = budgetAmountUri.replace("REPLACE", id);- $.post(newUri, {amount: value, start: periodStart, end: periodEnd}).done(function (data) {+ $.post(newUri, {amount: value, start: periodStart, end: periodEnd, _token: token}).done(function (data) {// difference between new value and original valuevar difference = value - original;diff --git a/public/js/ff/export/index.js b/public/js/ff/export/index.jsindex c4974d4f79..62a6da390e 100644--- a/public/js/ff/export/index.js+++ b/public/js/ff/export/index.js@@ -95,6 +95,7 @@ function showError(text) {function callExport() {"use strict";var data = $('#export').serialize();+ data['_token'] = token;// call status, keep calling it until response is "finished"?intervalId = window.setInterval(checkStatus, 500);diff --git a/public/js/ff/help.js b/public/js/ff/help.jsindex c8c34b6c2c..9894563e66 100644--- a/public/js/ff/help.js+++ b/public/js/ff/help.js@@ -50,7 +50,7 @@ function showHelp(e) {}function enableGuidance(route, specialPage) {- $.post('json/intro/enable/' + route + '/' + specialPage).done(function (data) {+ $.post('json/intro/enable/' + route + '/' + specialPage, {_token: token}).done(function (data) {alert(data.message);}).fail(function () {alert('Could not re-enable introduction.');diff --git a/public/js/ff/piggy-banks/index.js b/public/js/ff/piggy-banks/index.jsindex dc89b4373d..72f128a2a0 100644--- a/public/js/ff/piggy-banks/index.js+++ b/public/js/ff/piggy-banks/index.js@@ -89,7 +89,7 @@ function stopSorting() {var id = holder.data('id');order.push(id);});- $.post('piggy-banks/sort', {order: order}).done(function () {+ $.post('piggy-banks/sort', {order: order, _token: token}).done(function () {$('.loadSpin').removeClass('fa fa-refresh fa-spin');});}\ No newline at end of filediff --git a/public/js/ff/rules/index.js b/public/js/ff/rules/index.jsindex 3dd009a638..5c58468fa1 100644--- a/public/js/ff/rules/index.js+++ b/public/js/ff/rules/index.js@@ -115,11 +115,11 @@ function sortStop(event, ui) {});if (parent.hasClass('rule-triggers')) {- $.post('rules/trigger/order/' + ruleId, {triggers: entries}).fail(function () {+ $.post('rules/trigger/order/' + ruleId, {triggers: entries, _token: token}).fail(function () {alert('Could not re-order rule triggers. Please refresh the page.');});} else {- $.post('rules/action/order/' + ruleId, {actions: entries}).fail(function () {+ $.post('rules/action/order/' + ruleId, {actions: entries, _token: token}).fail(function () {alert('Could not re-order rule actions. Please refresh the page.');});diff --git a/public/js/ff/search/index.js b/public/js/ff/search/index.jsindex c48d1815b0..8b8cea4304 100644--- a/public/js/ff/search/index.js+++ b/public/js/ff/search/index.js@@ -29,7 +29,7 @@ $(function () {});function startSearch(query) {- $.post(searchUri, {query: query}).done(presentSearchResults).fail(searchFailure);+ $.post(searchUri, {query: query, _token: token}).done(presentSearchResults).fail(searchFailure);}function searchFailure() {diff --git a/public/js/ff/transactions/list.js b/public/js/ff/transactions/list.jsindex 50fb790d86..1a9b5d1230 100644--- a/public/js/ff/transactions/list.js+++ b/public/js/ff/transactions/list.js@@ -71,7 +71,7 @@ function goToReconcile() {baseHref = bases[0].href;}- $.post(baseHref + 'transactions/reconcile', {transactions: ids}).done(function () {+ $.post(baseHref + 'transactions/reconcile', {transactions: ids, _token: token}).done(function () {window.location.reload(true);}).fail(function () {alert('Could not reconcile transactions: please check the logs and try again later.');