Added project description
This commit is contained in:
parent
8e50cf711e
commit
f379dc9cc4
18
interface/migrations/0021_project_description.py
Normal file
18
interface/migrations/0021_project_description.py
Normal file
@ -0,0 +1,18 @@
|
||||
# Generated by Django 3.1.1 on 2020-10-05 03:41
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('interface', '0020_auto_20201003_2103'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='project',
|
||||
name='description',
|
||||
field=models.TextField(blank=True),
|
||||
),
|
||||
]
|
||||
@ -45,6 +45,7 @@ class Ensemble(models.Model):
|
||||
class Project(models.Model):
|
||||
name = models.CharField(max_length=100)
|
||||
ensemble = models.ForeignKey(Ensemble, related_name='projects', on_delete=models.CASCADE, null=True)
|
||||
description = models.TextField(blank=True)
|
||||
active = models.BooleanField(default=True)
|
||||
deadline =models.DateField(null=True, blank=True)
|
||||
owner = models.CharField(max_length=255, blank=True)
|
||||
|
||||
@ -3,6 +3,7 @@
|
||||
{% block page %}
|
||||
<div class="narrow">
|
||||
<h3 class="text-center">Due in {{ project.deadline|timeuntil }}!</h3>
|
||||
<p>{{ project.description }}</p>
|
||||
{% if project.owner %}
|
||||
<p>Project email: <a href="mailto:{{ project.owner }}">{{ project.owner }}</a></p>
|
||||
{% endif %}
|
||||
@ -23,4 +24,4 @@
|
||||
{% endif %}
|
||||
{% endwith %}
|
||||
</div>
|
||||
{% endblock %}
|
||||
{% endblock %}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user