Files
Aerbim/GeneralApp/funcs.py
2023-11-26 18:29:37 +03:00

23 lines
608 B
Python

from django.http import HttpResponse, Http404, FileResponse
def get_inter_Dict(user):
Dict = {}
from ServicesApp.funcs import get_sections
sections = get_sections()
Dict.update({
'sections': sections
})
# from SubscribesApp.funcs import get_cur_user_subscribe
# user_subscribe = get_cur_user_subscribe(user)
# Dict.update({'user_subscribe': user_subscribe})
return Dict
def get_inter_http_respose(template_obj, context_Dict, request):
context_Dict.update(get_inter_Dict(request.user))
return HttpResponse(template_obj.render(context_Dict, request))