Learn Docker With My Newest Course

Dive into Docker takes you from "What is Docker?" to confidently applying Docker to your own projects. It's packed with best practices and examples. Start Learning Docker →

Build a SAAS App with Flask: Part 2

blog/cards/build-a-saas-app-with-flask-part-1.jpg

Learn about the Build a SAAS App with Flask project, this is part 2 of a 5 part series.

Quick Jump: Looking for the Other Parts of This Series? | The Main New Addition Is an Admin Section | On the Horizon

This Article Is Outdated

Build a SAAS App with Flask been completely re-recorded from scratch as version 2.

Read About v2

The source code can be found here: https://github.com/nickjj/build-a-saas-app-with-flask

Looking for the Other Parts of This Series?

The Main New Addition Is an Admin Section

In its initial form, it has the following features:

  • A dashboard page for a high level overview of everything
  • Manage users and issues
  • Search, sort, pagination and bulk delete features

blog/build-a-saas-app-with-flask-v1-admin-dashboard.jpg

You might be wondering, why not use Flask-Admin?

That’s a good question. Having worked on a lot of projects, I never once ended up being able to use a generic admin backend solution while feeling good about it.

They tend to be great if you’re dealing with very ordinary data sets and don’t care about creating a good user experience for the person viewing the admin.

Different Resources Tend to Have Different Needs

I don’t know about you but if I’m editing a blog post or editing a user account I would expect to see completely different views.

The blog post view might contain a large typing area, a split panel for real time previews and various other components that make writing a better experience.

On the other hand, when looking at a user’s account I would expect to see a bunch of details such as their last login time, their account status and billing history.

blog/build-a-saas-app-with-flask-v1-admin-user-details.jpg

Generic Solutions Are Usually Tedious to Customize

No one knows your code better than you. Personally I’m a fan of slightly more code in favor of avoiding leaky abstractions.

Not only that but I don’t like to pigeon hole myself into technical choices. For instance as an app grows it may become a reasonable idea to introduce something like Elasticsearch for more sophisticated data analysis.

I want to be able to implement Elasticsearch and wire in faceted navigation to my existing admin as painlessly as possible. A generic solution is not going to allow you to do this, or if it does you’re going to end up writing a lot of crazy code.

What Does the Default Admin Panel Look Like?

blog/build-a-saas-app-with-flask-v1-manage-issues.jpg

blog/build-a-saas-app-with-flask-v1-bulk-delete-items.jpg

In case you’re wondering, the email addresses above were generated using the Faker package. Sorry in advance if anyone is on that list, it’s mere coincidence.

Oh yeah, you’re probably wondering why the date format is so ugly. I haven’t setup momentjs yet. It will be adjusted in a future version.

On the Horizon

The next step is adding all of the billing and subscription components to the app.

Never Miss a Tip, Trick or Tutorial

Like you, I'm super protective of my inbox, so don't worry about getting spammed. You can expect a few emails per month (at most), and you can 1-click unsubscribe at any time. See what else you'll get too.



Comments