mirror of
https://github.com/welton89/RRBEC.git
synced 2026-04-05 13:35:42 +00:00
exibindo dados do banco no html
This commit is contained in:
@@ -1,5 +1,8 @@
|
||||
from django.shortcuts import render
|
||||
|
||||
from products.models import Product
|
||||
|
||||
|
||||
def products(request):
|
||||
return render(request, 'products.html')
|
||||
protucts = Product.objects.all()
|
||||
return render(request, 'products.html', {'products': protucts})
|
||||
Reference in New Issue
Block a user