From 564cfb7c6fe41f7bd2baa2eb0cbf856f63de5b15 Mon Sep 17 00:00:00 2001 From: AlGouvea Date: Tue, 5 Oct 2021 10:59:19 -0300 Subject: [PATCH] Adicionado campo de tempo restante no cronometro --- .../0004_cronometro_tempo_restante.py | 18 ++++++++++++++++++ sapl/painel/models.py | 6 ++++++ 2 files changed, 24 insertions(+) create mode 100644 sapl/painel/migrations/0004_cronometro_tempo_restante.py diff --git a/sapl/painel/migrations/0004_cronometro_tempo_restante.py b/sapl/painel/migrations/0004_cronometro_tempo_restante.py new file mode 100644 index 000000000..f3ac159d3 --- /dev/null +++ b/sapl/painel/migrations/0004_cronometro_tempo_restante.py @@ -0,0 +1,18 @@ +# Generated by Django 2.2.24 on 2021-10-05 13:57 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('painel', '0003_auto_20201013_1153'), + ] + + operations = [ + migrations.AddField( + model_name='cronometro', + name='tempo_restante', + field=models.DurationField(blank=True, null=True, verbose_name='Tempo restante no cronômetro'), + ), + ] diff --git a/sapl/painel/models.py b/sapl/painel/models.py index aec696a53..2474bf545 100644 --- a/sapl/painel/models.py +++ b/sapl/painel/models.py @@ -48,6 +48,12 @@ class Cronometro(models.Model): tipo = models.CharField( max_length=1, choices=CRONOMETRO_TYPES, verbose_name=_('Tipo Cronômetro')) + + tempo_restante = models.DurationField( + verbose_name=_('Tempo restante no cronômetro'), + blank=True, + null=True + ) class Meta: ordering = ('-data_cronometro',) \ No newline at end of file