rescuers own site

This commit is contained in:
gw3000 2023-06-10 15:42:55 +02:00
parent 908bff726a
commit f72425f354
5 changed files with 39 additions and 25 deletions

View file

@ -0,0 +1 @@
<h1>Single rescuer</h1>

5
rescuer/urls.py Normal file
View file

@ -0,0 +1,5 @@
from django.urls import path
from .views import rescuer_single
urlpatterns = [path("<id>", rescuer_single, name="rescuer_single")]

View file

@ -1,3 +1,8 @@
from django.shortcuts import render
from .models import Rescuer
# Create your views here.
def rescuer_single(request, id):
rescuer = Rescuer.objects.get(id=id)
context = {"rescuer": rescuer}
return render(request, "rescuer/rescuer_single.html", context)