예제 #1
0
 def setUp(self):
     setup_demo()
     from django.db import connection, transaction
     cursor = connection.cursor()
     # Data modifying operation - commit required
     cursor.execute(ledger_account_view_sql)
     transaction.commit_unless_managed()
예제 #2
0
def clean_minibooks_db():
    for g in Group.objects.all():
        g.delete()
    for u in User.objects.all():
        u.delete()
    for b in crm_models.Business.objects.all():
        b.delete()
    for p in crm_models.Project.objects.all():
        p.delete()
    
    demo.setup_demo()
예제 #3
0
 def handle(self, **options):
     setup_demo()