Skip to content

Commit

Permalink
Start date should be DateTimeField
Browse files Browse the repository at this point in the history
  • Loading branch information
annagav committed Sep 26, 2024
1 parent 576e352 commit f58774b
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 2 deletions.
4 changes: 4 additions & 0 deletions courses/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -411,6 +411,10 @@ class Meta:
"live",
"requirements",
"availability",
"start_date",
"end_date",
"enrollment_start",
"enrollment_end",
]

class Media:
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Generated by Django 4.2.15 on 2024-09-26 17:16

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('courses', '0056_program_end_date_program_enrollment_end_and_more'),
]

operations = [
migrations.AlterField(
model_name='program',
name='end_date',
field=models.DateTimeField(blank=True, db_index=True, null=True),
),
migrations.AlterField(
model_name='program',
name='start_date',
field=models.DateTimeField(blank=True, db_index=True, null=True),
),
]
4 changes: 2 additions & 2 deletions courses/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -163,8 +163,8 @@ class Meta:
)
enrollment_start = models.DateTimeField(null=True, blank=True, db_index=True)
enrollment_end = models.DateTimeField(null=True, blank=True, db_index=True)
start_date = models.DateField(null=True, blank=True, db_index=True)
end_date = models.DateField(null=True, blank=True, db_index=True)
start_date = models.DateTimeField(null=True, blank=True, db_index=True)
end_date = models.DateTimeField(null=True, blank=True, db_index=True)

@cached_property
def page(self):
Expand Down

0 comments on commit f58774b

Please sign in to comment.