mirror of
https://github.com/ae-utbm/sith.git
synced 2024-12-25 09:11:13 +00:00
Add db index in counter
This commit is contained in:
parent
cf062a35d3
commit
ec307cd5df
19
counter/migrations/0012_auto_20170515_2202.py
Normal file
19
counter/migrations/0012_auto_20170515_2202.py
Normal file
@ -0,0 +1,19 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('counter', '0011_auto_20161004_2039'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AlterField(
|
||||
model_name='permanency',
|
||||
name='end',
|
||||
field=models.DateTimeField(db_index=True, verbose_name='end date', null=True),
|
||||
),
|
||||
]
|
@ -431,7 +431,7 @@ class Permanency(models.Model):
|
||||
user = models.ForeignKey(User, related_name="permanencies", verbose_name=_("user"))
|
||||
counter = models.ForeignKey(Counter, related_name="permanencies", verbose_name=_("counter"))
|
||||
start = models.DateTimeField(_('start date'))
|
||||
end = models.DateTimeField(_('end date'), null=True)
|
||||
end = models.DateTimeField(_('end date'), null=True, db_index=True)
|
||||
activity = models.DateTimeField(_('last activity date'), auto_now=True)
|
||||
|
||||
class Meta:
|
||||
|
Loading…
Reference in New Issue
Block a user