class MyObjectAdmin(admin.ModelAdmin): # A template for a very customized change view: change_form_template = 'admin/my_change_form.html' def get_dynamic_info(self): # ... pass def change_view(self, request, object_id, form_url='', extra_context=None): extra_context = extra_context or {} extra_context['osm_data'] = self.get_dynamic_info() return super(MyObjectAdmin, self).change_view( request, object_id, form_url, extra_context=extra_context, )
-- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@googlegroups.com. To post to this group, send email to django-users@googlegroups.com. Visit this group at https://groups.google.com/group/django-users. To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/a45b0858-bc7b-41dd-9858-9cfe46ae68e4%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.