示例#1
0
 def get(self, request, *args, **kwargs):
     client_instance = client_check(request.user)
     response = {
         'client_img': load_client_img(client_instance),
         'data': education_page_get(client_instance),
     }
     return render(request, self.template_name, response)
示例#2
0
    def get(self, request, *args, **kwargs):
        client_instance = client_check(request.user)
        load_data = education_page_get(client_instance)['cl_edu']

        response = {'client_img': load_client_img(client_instance),
                    'edu_form': EducationFormSet(initial=load_data),
                    'certificate': CertificateFormSet(initial=load_data),
                    # 'certificate': CertificateForm(initial=load_data[0]),
                    'sab_class_form': SabClassFormSet(initial=load_data),
                    }
        return render(request, self.template_name, response)