Advanced Django Training

Course duration

  • 3 days

Course Benefits

  • Learn to add feedback messages to let users know about changes.
  • Learn to allow users to securely upload files to your server.
  • Learn to keep user-uploaded files private.
  • Learn to use Amazon Simple Storage Service (Amazon S3) to manage files.
  • Learn how to make queries against the database using Django.
  • Learn to add custom properties to models.
  • Learn to use Ajax to securely make changes to the database without refreshing the page.
  • Learn to create constraints to control the data entered into the database.
  • Learn to load data with fixtures.
  • Learn to add pagination to Django templates.
  • Learn to find optimization opportunities the Django Debug Toolbar.
  • Learn to speed up your queries by prefetching data.
  • Learn to deploy your Django website to Heroku.
  • Learn to customize Django admin for staff users.
Available Delivery Methods
Public Class
Public expert-led online training from the convenience of your home, office or anywhere with an internet connection. Guaranteed to run .
Private Class
Private classes are delivered for groups at your offices or a location of your choice.

Course Outline

  1. Messages Framework
    1. Message Framework
    2. Exercise: Adding Messages
    3. Exercise: Using SuccessMessageMixin
    4. Exercise: Adding Success Messages to the Joke Views
    5. Exercise: Adding a Success Message to JokeDeleteView
  2. Media Files
    1. Media File Basics
    2. Exercise: Adding Media Settings
    3. Exercise: Uploading a Resume
    4. Exercise: Checking File Type
    5. Exercise: Keeping Resume Files Private
    6. Exercise: Adding an ImageField to the Model
    7. Exercise: Displaying the Avatar
    8. Amazon Simple Storage Service (Amazon S3)
    9. Exercise: Setting Up Amazon S3
    10. Exercise: Static Settings in Development
  3. Making Queries, Ajax, and View Functions
    1. Useful Prerequisites
    2. Managers and QuerySets
    3. Indexing and Slicing QuerySets
    4. Checking for Existence
    5. Creating, Updating, and Saving Model Instances
    6. QuerySet Methods that Don't Return QuerySets
    7. One-to-Many Relationships
    8. Many-to-Many Relationships
    9. Spanning Relationships
    10. Joke Voting
    11. Exercise: Adding a JokeVote Model
    12. Exercise: Registering the JokeVote Model
    13. Exercise: Adding Properties to the Joke Model
    14. Exercise: Rating Jokes Using Ajax
    15. Exercise: Adding a vote() View Function
    16. Exercise: Updating the URLConf
    17. Exercise: Updating the Templates
    18. Model Constraints
    19. Letting JavaScript Know if the User is Logged In
  4. Pagination and Ordering
    1. Fixtures
    2. Exercise: Loading Data from a Fixture
    3. Exercise: Pagination
    4. Exercise: Ordering
  5. Advanced Querying and Search
    1. Field Lookups
    2. Q Objects
    3. Exercise: Filtering Results by Category, Tag, or Creator
    4. Exercise: Implementing Search
    5. Aggregation
    6. Exercise: Getting Joke Ratings
    7. Code Optimization
    8. Exercise: Installing and Using the Django Debug Toolbar
    9. Brief Introduction to Annotation
    10. Viewing SQL Used in QuerySets
  6. Deploying your Website to Production
    1. Where to Host Your Django Site
    2. Exercise: Deploying to Heroku
  7. Customizing Django Admin
    1. Django Admin Views
    2. Exercise: Customizing Titles and Headers
    3. ModelAdmin Attributes that Affect the List View
    4. Exercise: Creating a Custom ModelAdmin Base Class
    5. Exercise: Customizing the Django Admin List View
    6. Lists vs. Tuples
    7. ModelAdmin Attributes that Affect Forms
    8. Exercise: Customizing Django Admin Form Views
    9. Customizing Fieldsets
    10. Exercise: Modifying the CustomUserAdmin Class
    11. Adding Calculated Read-only Fields
    12. Exercise: Adding a Link to the Change Password Form
    13. Exercise: Unregistering Models
    14. Exercise: Django Admin Groups and Permissions
  8. Additional Topics
    1. Additional Learning
    2. Additional Projects

Class Materials

Each student will receive a comprehensive set of materials, including course notes and all the class examples.

Class Prerequisites

Experience in the following is required for this Django class:

  • Python
  • Basic Django as taught in our Introduction to Django course

Experience in the following would be useful for this Django class:

  • JavaScript
  • SQL
Prerequisite Courses

Courses that can help you meet these prerequisites:

Since its founding in 1995, InterSource has been providing high quality and highly customized training solutions to clients worldwide. With over 500 course titles constantly updated and numerous course customization and creation possibilities, we have the capability to meet your I.T. training needs.
Instructor-led courses are offered via a live Web connection, at client sites throughout Europe, and at our Geneva Training Center.