From cf657c1ad798fc5d354caa31ef156b3c73dad524 Mon Sep 17 00:00:00 2001 From: Alexis Lahouze Date: Tue, 18 Aug 2015 17:15:36 +0200 Subject: [PATCH] Added session.flush() calls to update scheduled_operation object. --- accountant/api/views/scheduled_operations.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/accountant/api/views/scheduled_operations.py b/accountant/api/views/scheduled_operations.py index d8d8e44..38b23a7 100644 --- a/accountant/api/views/scheduled_operations.py +++ b/accountant/api/views/scheduled_operations.py @@ -86,6 +86,8 @@ class ScheduledOperationListResource(Resource): scheduled_operation.reschedule(session) + session.flush() + return scheduled_operation, 201 @@ -155,6 +157,8 @@ class ScheduledOperationResource(Resource): scheduled_operation.reschedule(session) + session.flush() + return scheduled_operation