Added missing defaults

This commit is contained in:
Sebastian 2017-05-26 01:57:52 +02:00
parent 794d9c9bdd
commit 4863c9f448
2 changed files with 21 additions and 1 deletions

View File

@ -0,0 +1,20 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.10.5 on 2017-05-25 23:55
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('roms', '0009_rom_download_count'),
]
operations = [
migrations.AlterField(
model_name='rom',
name='download_count',
field=models.IntegerField(default=0),
),
]

View File

@ -33,7 +33,7 @@ class Rom(models.Model):
approved = models.BooleanField("approved", default=False)
tags = TaggableManager(blank = True)
user = models.ForeignKey(User, blank=True, null=True)
download_count = models.IntegerField()
download_count = models.IntegerField(default = 0)
creation_time = models.DateTimeField("creation time", auto_now_add = True)
edit_time = models.DateTimeField("edit time", auto_now = True)