Skip to content

Commit

Permalink
Minor design update
Browse files Browse the repository at this point in the history
  • Loading branch information
adilmohak committed Sep 30, 2024
1 parent 2ac925d commit 1ad6b48
Showing 1 changed file with 4 additions and 23 deletions.
27 changes: 4 additions & 23 deletions templates/course/course_allocation_form.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{% load i18n %}
{% extends 'base.html' %}
{% load i18n %}
{% block title %}{{ title }} | {% trans 'Learning management system' %}{% endblock title %}
{% load crispy_forms_tags %}
{% load static %}
Expand All @@ -14,35 +14,16 @@
</ol>
</nav>

{% if messages %}
{% for message in messages %}
{% if message.tags == 'error' %}
<div class="alert alert-danger">
<i class="fas fa-exclamation-circle"></i>{{ message }}
</div>
{% else %}
<div class="alert alert-success">
<i class="fas fa-check-circle"></i>{{ message }}
</div>
{% endif %}
{% endfor %}
{% endif %}
{% include 'snippets/messages.html' %}

<div class="row">
<div class="col-md-6 mx-auto">
<div class="card">
<p class="form-title">{% trans 'Course Allocation Form' %}</p>
<div class="p-3">
<form action="" method="POST">{% csrf_token %}
<!-- {{ form|crispy }} -->
<div class="form-group">
{{ form.lecturer.label }}{{ form.lecturer }}
<span class="danger">{{ form.lecturer.errors }}</span>
</div>
<div class="form-group">
{{ form.courses.label }}{{ form.courses }}
<span class="danger">{{ form.courses.errors }}</span>
</div>
{{ form.lecturer|as_crispy_field }}
{{ form.courses|as_crispy_field }}

{% for course in form.courses.all %}{{ course }}{% endfor %}

Expand Down

0 comments on commit 1ad6b48

Please sign in to comment.