Skip to content
This repository has been archived by the owner on Jan 3, 2024. It is now read-only.

Commit

Permalink
feat(submission_page): template of submissions incomplete
Browse files Browse the repository at this point in the history
  • Loading branch information
LuizaMaluf committed Nov 29, 2023
1 parent 11103bb commit 48d650d
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 4 deletions.
2 changes: 1 addition & 1 deletion apps/submissions/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ def setUp(self) -> None:
def test_submission_list_view(self) -> None:
self.client.login(email="testuser@example", password="testpassword")

url = reverse("submission_list")
url = reverse("submissions:list")

response = self.client.get(url)

Expand Down
6 changes: 3 additions & 3 deletions apps/submissions/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@

from apps.submissions.views import SubmissionListView

urlpatterns = [
path("submissions/", SubmissionListView.as_view(), name="submission_list")
]
app_name = "submissions"

urlpatterns = [path("", SubmissionListView.as_view(), name="list")]
23 changes: 23 additions & 0 deletions templates/submissions/submission_list.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{% extends "base.html" %}

{% load crispy_forms_tags %}

{% block title %}Submissions{% endblock title %}

{% block content %}

<h2>Submissions</h2>
<ul>
{% for submission in submissions %}
<li>
Submission ID: {{ submission.id }} -
<a href="{% url 'tasks:detail' task.id %}">
- {{ task.title }}
</a>
- Status: {{ submission.status }}
- Data: {{ submission.created_at }}
</li>
{% endfor %}
</ul>

{% endblock content %}

0 comments on commit 48d650d

Please sign in to comment.