This commit is contained in:
2024-11-19 13:00:24 +07:00
commit 45e3c1f698
3462 changed files with 617437 additions and 0 deletions

27
home/views.py Normal file
View File

@@ -0,0 +1,27 @@
from django.shortcuts import render
from home.models import *
# ===============> Front Home Page View <===============
def homePageFront(request):
meta = homePageSEO.objects.first()
sliders = sliderSection.objects.all()
services = serviceSection.objects.all()
about = aboutSection.objects.first()
project_categories= projectCategory.objects.all()
projects = projectSection.objects.all().order_by('?')
clients = clientSection.objects.all()
context = {
'meta' : meta,
'sliders' : sliders,
'services' : services,
'about' : about,
'project_categories' : project_categories,
'projects': projects,
'clients' : clients,
}
return render(request, 'front/main/index.html', context)
def error_404(request, exception):
return render(request, 'error/404.html', status=404)