aboutsummaryrefslogtreecommitdiffstats
path: root/src/workflow
diff options
context:
space:
mode:
authorssmith <ssmith@iol.unh.edu>2020-06-22 13:48:17 -0400
committerssmith <ssmith@iol.unh.edu>2020-06-22 13:49:03 -0400
commit3bd27e99960c16c0a9bcab1533b1e6f15b0c9d9e (patch)
tree008597b2a0dee17ae8185bde4f9c2e3f572a8588 /src/workflow
parent0a8de17a33228a8fa9abd7b39149990650ce99d9 (diff)
Small Change to add a useful workflow transaction
Change-Id: I635a74605871bfa53337e20635a86632457452df Signed-off-by: Sean Smith <ssmith@iol.unh.edu>
Diffstat (limited to 'src/workflow')
-rw-r--r--src/workflow/models.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/workflow/models.py b/src/workflow/models.py
index 4a5616e..f550a38 100644
--- a/src/workflow/models.py
+++ b/src/workflow/models.py
@@ -11,6 +11,7 @@
from django.template.loader import get_template
from django.http import HttpResponse
from django.utils import timezone
+from django.db import transaction
import yaml
import requests
@@ -559,6 +560,7 @@ class Repository():
self.el[self.RESULT] = bundle
return False
+ @transaction.atomic # TODO: Rewrite transactions with savepoints at user level for all workflows
def make_booking(self):
models = self.el[self.BOOKING_MODELS]
owner = self.el[self.SESSION_USER]