def result(request, applabel, appmodel, object_id, feedback_id): feedback_relation = _get_fbr_or_404(applabel, appmodel, object_id, feedback_id) if not has_permission(feedback_relation, request.user): messages.error(request, _("Du har ikke tilgang til dette skjemaet.")) return redirect("home") return feedback_results(request, feedback_relation)
def chart_data(request, applabel, appmodel, object_id, feedback_id): feedback_relation = _get_fbr_or_404(applabel, appmodel, object_id, feedback_id) if not has_permission(feedback_relation, request.user): messages.error(request, _("Du har ikke tilgang til denne dataen.")) return redirect("home") return get_chart_data(request, feedback_relation)