The code below is from a django project for a kickstarter-like funding platform.
This is the view for the individual project page, which shows the project's title, description, and featured image, and asks the user to donate to the project. The page provides four suggested donation amounts, with a fifth option for the user to write in a custom amount. The minimum donation is $5. The max is $1000. The median is $20.
def project_page(request, slug):
project = get_object_or_404(Project.objects.get(slug=slug, published=True))
featured_image = project.featured_image
account = project.account