From 0507c84856700376e06ae03b93366a7be3063771 Mon Sep 17 00:00:00 2001 From: Étienne Loks Date: Mon, 13 Mar 2017 22:29:24 +0100 Subject: Operation migration: fix regeneration of cache --- .../migrations/0061_regenerate_cached_label.py | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) (limited to 'archaeological_operations/migrations/0061_regenerate_cached_label.py') diff --git a/archaeological_operations/migrations/0061_regenerate_cached_label.py b/archaeological_operations/migrations/0061_regenerate_cached_label.py index 50a2b43fe..91beb8138 100644 --- a/archaeological_operations/migrations/0061_regenerate_cached_label.py +++ b/archaeological_operations/migrations/0061_regenerate_cached_label.py @@ -4,18 +4,11 @@ from south.db import db from south.v2 import SchemaMigration from django.db import models + class Migration(SchemaMigration): def forwards(self, orm): - from archaeological_operations.models import Operation - q = Operation.objects - nb = q.count() - sys.stdout.write("Force regenerating cache...\n") - for idx, ope in enumerate(q.all()): - sys.stdout.write("\r{}/{}".format(idx + 1, nb)) - sys.stdout.flush() - ope.skip_history_when_saving = True - ope.save() + pass def backwards(self, orm): pass -- cgit v1.2.3