def sources(request): """ Get the sources list for samples. :param request: Django request object (Required) :type request: :class:`django.http.HttpRequest` :returns: :class:`django.http.HttpResponse` """ refresh = request.GET.get("refresh", "no") if refresh == "yes": generate_sources() sources_list = get_source_counts(request.user) return render(request, 'samples_sources.html', {'sources': sources_list})
def sources(request): """ Get the sources list for samples. :param request: Django request object (Required) :type request: :class:`django.http.HttpRequest` :returns: :class:`django.http.HttpResponse` """ refresh = request.GET.get("refresh", "no") if refresh == "yes": generate_sources() sources_list = get_source_counts(request.user) return render(request, 'samples_sources.html', {'sources': sources_list})