diff --git a/apps/member/views.py b/apps/member/views.py index b518ad24..14322dcf 100644 --- a/apps/member/views.py +++ b/apps/member/views.py @@ -391,12 +391,12 @@ class ClubAddMemberView(LoginRequiredMixin, CreateView): return super().get_queryset().filter(PermissionBackend.filter_queryset(self.request.user, Membership, "view") | PermissionBackend.filter_queryset(self.request.user, Membership, "change")) - def get_context_data(self, **kwargs): + club = Club.objects.get(pk=self.kwargs["pk"]) context = super().get_context_data(**kwargs) context['formset'] = MemberFormSet() context['helper'] = FormSetHelper() - + context['club'] = club context['no_cache'] = True return context diff --git a/templates/member/add_members.html b/templates/member/add_members.html index 8032af30..8b57e7d4 100644 --- a/templates/member/add_members.html +++ b/templates/member/add_members.html @@ -1,7 +1,11 @@ -{% extends "base.html" %} +{% extends "member/noteowner_detail.html" %} {% load crispy_forms_tags %} {% load static %} -{% block content %} + +{% block profile_info %} +{% include "member/club_info.html" %} +{% endblock %} +{% block profile_content %}
{% csrf_token %} @@ -10,9 +14,9 @@
+{% endblock %} - - +{% block extrajavascript %}