Models

A collection of 7 articles

  • #Python
  • #Django
  • #models

Give Me A Break... Day - Building SaaS #67

In this episode, we did some Django model development. I created a new model to track break days in a school year. This model will be critical to fill in vacations and holidays so that the scheduling functionality works properly. I added the model, the tests, the admin page, and the create view to create break days in the app.

  • #Python
  • #Django
  • #models

Handle Default Values - Building SaaS #65

In this episode, I updated a model to handle the default duration of new tasks. This default needed to come from the Course model instead of the CourseTask model so we had to determine how best to set that data in various forms. I also fixed some drop down selection bugs that populated a form with the wrong data. We made sure that all the code was well tested.

  • #Python
  • #Django
  • #models

Episode 7 - Models and Managers and Querysets, Oh My!

On this episode, we will explore more about models and how to interact with data in your database.

  • #Python
  • #Django
  • #models

The Home Stretch - Building SaaS #63

In this episode, we return to the homeschool application that I’m building. I’m in the final stretch of changes that need to happen to make the product minimally viable. We worked on a template, wrote some model methods, and did a bunch of automated testing.

  • #Python
  • #Django
  • #models

Episode 6 - Where Does the Data Go?

On this episode, we will learn about storing data and how Django manages data using models.

  • #Python
  • #Django
  • #models

Store Data With Models

In this article, we will see how to store data into a database with Django models. The article covers how models act as an interface to let your application store and fetch data.

  • #Python
  • #Django
  • #models

Remodeling Data Relationships - Building SaaS #55

In this episode, we’re remodeling! I changed the model relationship between GradeLevel and Course from a ForeignKey (1 to many) to a ManyToManyField. We talked through the change and started fixing all the tests that broke.