Fix SharedUpload model field name.

This commit is contained in:
Roberto Rosario
2015-07-06 14:32:23 -04:00
parent 9784ae88a4
commit 091dad9b45
2 changed files with 21 additions and 2 deletions

View File

@@ -0,0 +1,19 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
class Migration(migrations.Migration):
dependencies = [
('common', '0004_delete_anonymoususersingleton'),
]
operations = [
migrations.RenameField(
model_name='shareduploadedfile',
old_name='datatime',
new_name='datetime',
),
]

View File

@@ -19,9 +19,9 @@ def upload_to(instance, filename):
@python_2_unicode_compatible
class SharedUploadedFile(models.Model):
file = models.FileField(upload_to=upload_to, storage=shared_storage_backend, verbose_name=_('File'))
file = models.FileField(storage=shared_storage_backend, upload_to=upload_to, verbose_name=_('File'))
filename = models.CharField(max_length=255, verbose_name=_('Filename'))
datatime = models.DateTimeField(auto_now_add=True, verbose_name=_('Date time'))
datetime = models.DateTimeField(auto_now_add=True, verbose_name=_('Date time'))
class Meta:
verbose_name = _('Shared uploaded file')