Add registry and cleanup files
This commit is contained in:
7
apps/linking/cleanup.py
Normal file
7
apps/linking/cleanup.py
Normal file
@@ -0,0 +1,7 @@
|
||||
from __future__ import absolute_import
|
||||
|
||||
|
||||
def cleanup():
|
||||
from .models import SmartLink
|
||||
|
||||
SmartLink.objects.all().delete()
|
||||
15
apps/linking/registry.py
Normal file
15
apps/linking/registry.py
Normal file
@@ -0,0 +1,15 @@
|
||||
from __future__ import absolute_import
|
||||
|
||||
from .cleanup import cleanup
|
||||
|
||||
|
||||
bootstrap_models = [
|
||||
{
|
||||
'name': 'smartlink',
|
||||
},
|
||||
{
|
||||
'name': 'smartlinkcondition',
|
||||
}
|
||||
]
|
||||
|
||||
cleanup_functions = [cleanup]
|
||||
Reference in New Issue
Block a user