diff --git a/main/models.py b/main/models.py index fd0482ac403a4d23f8ae1bde2cf72f5887f3c841..c752cd333d2611e83bdcddd312b55250a8b85bd8 100644 --- a/main/models.py +++ b/main/models.py @@ -481,7 +481,7 @@ class MainCareersPage( current_date = date.today() if not show_closed: - filter = filter & models.Q(closing_date__gt=current_date) + filter = filter & models.Q(closing_date__gte=current_date) if category is not None: filter = filter & models.Q(category=category) @@ -609,8 +609,8 @@ class MainCareerPage( if ( request.method == "POST" - and self.closing_date > current_date - and self.submission_end_date > current_date + and self.closing_date >= current_date + and self.submission_end_date >= current_date ): form = CareerSubmissionForm(request.POST, request.FILES) diff --git a/main/templates/main/main_career_page.html b/main/templates/main/main_career_page.html index 97172130810f3c7ed51a05306a1cdfcad74e47c4..42771275762e5a8d0e7ded43b516bcbc32d962ee 100644 --- a/main/templates/main/main_career_page.html +++ b/main/templates/main/main_career_page.html @@ -16,7 +16,7 @@ <div class="bg-red-400 border border-solid border-red-600 p-4 inline-block mb-6"> <strong>Výběrové řízení uzavřeno.</strong> </div> - {% elif page.submission_end_date <= current_date %} + {% elif page.submission_end_date < current_date %} <div class="bg-red-400 border border-solid border-red-600 p-4 inline-block mb-6"> <strong>Přihlášky uzavřeny.</strong> </div> @@ -53,7 +53,7 @@ </div> {% endif %} - {% if page.closing_date > current_date and page.submission_end_date > current_date %} + {% if page.closing_date >= current_date and page.submission_end_date >= current_date %} <div data-micromodal-trigger="modal-1" class="lg:mb-3 mb-12 inline-block"> {% include "styleguide2/includes/atoms/buttons/round_button.html" with text="Přihlásit se" show_arrow_on_hover=True %} </div> @@ -61,7 +61,7 @@ </section> </main> - {% if page.closing_date > current_date and page.submission_end_date > current_date %} + {% if page.closing_date >= current_date and page.submission_end_date >= current_date %} <div class="modal micromodal-slide" id="modal-1" aria-hidden="true"> <div class="modal__overlay" tabindex="-1"> <form