김정국 2014-03-04
Merge branch 'fix/project-visitation-integrity-violation-while-deleting-project' of npcode/yobi
from pull request 665
@adeeb59f739b90c9bf522a5375f15a06db6b9f1b
app/models/Project.java
--- app/models/Project.java
+++ app/models/Project.java
@@ -761,6 +761,11 @@
             posting.delete();
         }
 
+        for (ProjectVisitation visit :
+                ProjectVisitation.find.where().eq("project", this).findList()) {
+            visit.delete();
+        }
+
         super.delete();
     }
 
Add a comment
List