Browse Source

Useless migration

Fabs 10 years ago
parent
commit
04f0f1362d
2 changed files with 28 additions and 2 deletions
  1. 26 0
      coin/billing/migrations/0004_auto_20140921_1454.py
  2. 2 2
      coin/utils.py

+ 26 - 0
coin/billing/migrations/0004_auto_20140921_1454.py

@@ -0,0 +1,26 @@
+# -*- coding: utf-8 -*-
+from __future__ import unicode_literals
+
+from django.db import models, migrations
+import coin.billing.models
+import coin.utils
+
+
+class Migration(migrations.Migration):
+
+    dependencies = [
+        ('billing', '0003_auto_20140920_2342'),
+    ]
+
+    operations = [
+        migrations.AlterField(
+            model_name='invoice',
+            name='pdf',
+            field=models.FileField(storage=coin.utils.private_files_storage, upload_to=coin.billing.models.invoice_pdf_filename, null=True, verbose_name='PDF', blank=True),
+        ),
+        migrations.AlterField(
+            model_name='invoice',
+            name='validated',
+            field=models.BooleanField(default=False, verbose_name=b'Valid\xc3\xa9e'),
+        ),
+    ]

+ 2 - 2
coin/utils.py

@@ -11,8 +11,8 @@ from django.conf import settings
 
 
 # Stockage des fichiers privés (comme les factures par exemple)
-private_files_storage = FileSystemStorage(location=settings.PRIVATE_FILES_ROOT)
-
+def private_files_storage():
+    return FileSystemStorage(location=settings.PRIVATE_FILES_ROOT)
 
 def str_or_none(obj):
     return str(obj) if obj else None