Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add rolling admission field to career opportunity #3300

Merged
merged 5 commits into from
Sep 19, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions apps/careeropportunity/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ class AddCareerOpportunityForm(forms.ModelForm):
widget=DatetimePickerInput(),
)
deadline_asap = forms.BooleanField(label="Frist er snarest", required=False)
rolling_admission = forms.BooleanField(label="Løpende opptak", required=False)

class Meta:
model = CareerOpportunity
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# Generated by Django 5.1.1 on 2024-09-19 19:15

from django.db import migrations, models


class Migration(migrations.Migration):
dependencies = [
("careeropportunity", "0017_careeropportunity_deadline_asap"),
]

operations = [
migrations.AddField(
model_name="careeropportunity",
name="rolling_admission",
field=models.BooleanField(
blank=True, default=False, verbose_name="Løpende opptak"
),
),
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Generated by Django 5.1.1 on 2024-09-19 19:21

from django.db import migrations, models


class Migration(migrations.Migration):
dependencies = [
("careeropportunity", "0018_careeropportunity_rolling_admission"),
]

operations = [
migrations.AlterField(
model_name="careeropportunity",
name="rolling_admission",
field=models.BooleanField(default=False, verbose_name="Løpende opptak"),
),
]
3 changes: 3 additions & 0 deletions apps/careeropportunity/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ class CareerOpportunity(models.Model):
featured = models.BooleanField(_("fremhevet"), default=False, blank=True)
deadline = models.DateTimeField(_("frist"), default=None, null=True, blank=True)
deadline_asap = models.BooleanField(_("snarest"), default=False, blank=True)
rolling_admission = models.BooleanField(
_("Løpende opptak"), default=False, blank=False
)

JOB_TYPE_CHOICES = (
(1, "Fastjobb"),
Expand Down
1 change: 1 addition & 0 deletions apps/careeropportunity/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ class Meta:
"featured",
"deadline",
"deadline_asap",
"rolling_admission",
"employment",
"location",
)
Expand Down