diff options
author | asteroide <thomas.duval@orange.com> | 2015-11-25 15:34:23 +0100 |
---|---|---|
committer | asteroide <thomas.duval@orange.com> | 2015-11-25 15:34:23 +0100 |
commit | fbdd3c6adc86353861fc48a8534523f85356b0cc (patch) | |
tree | 464afb71f9e89216584464208cf494d4c763a993 /keystone-moon | |
parent | f7cc5b52cac3361f68260aac1fecd20abfc7044b (diff) |
Automatically delete assignments related to a category when user asks to delete this category.
Change-Id: Ic906572bb5938891d103b11fc49b6b392edc20ef
Diffstat (limited to 'keystone-moon')
-rw-r--r-- | keystone-moon/keystone/contrib/moon/backends/sql.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/keystone-moon/keystone/contrib/moon/backends/sql.py b/keystone-moon/keystone/contrib/moon/backends/sql.py index 9bc9ee45..06071507 100644 --- a/keystone-moon/keystone/contrib/moon/backends/sql.py +++ b/keystone-moon/keystone/contrib/moon/backends/sql.py @@ -437,6 +437,7 @@ class IntraExtensionConnector(IntraExtensionDriver): query = session.query(SubjectCategory) query = query.filter_by(intra_extension_id=intra_extension_id, id=subject_category_id) ref = query.first() + self.del_subject_assignment(intra_extension_id, None, None, None) session.delete(ref) # Getter and Setter for object_category @@ -475,6 +476,7 @@ class IntraExtensionConnector(IntraExtensionDriver): query = session.query(ObjectCategory) query = query.filter_by(intra_extension_id=intra_extension_id, id=object_category_id) ref = query.first() + self.del_object_assignment(intra_extension_id, None, None, None) session.delete(ref) # Getter and Setter for action_category @@ -513,6 +515,7 @@ class IntraExtensionConnector(IntraExtensionDriver): query = session.query(ActionCategory) query = query.filter_by(intra_extension_id=intra_extension_id, id=action_category_id) ref = query.first() + self.del_action_assignment(intra_extension_id, None, None, None) session.delete(ref) # Perimeter |