Model Administration

In this chapter, we will go through the advanced techniques we can use to customize administration by developing some practical cases.

In this chapter, we will cover the following topics:

  • Customizing columns on the change list page
  • Creating sortable inlines
  • Creating admin actions
  • Developing change list filters
  • Changing the app label of a third-party app
  • Creating a custom accounts app
  • Getting user Gravatars
  • Inserting a map into a change form

Introduction

The Django framework comes with a built-in administration system for your data models. With very little effort, you can set up filterable, searchable, and sortable lists in order to browse your models, and you can configure forms to add and manage data.

Technical requirements

To work with the code in this chapter, you will need the latest stable version of Python, a MySQL or PostgreSQL database, and a Django project with a virtual environment.