From 13283b63270cbe8ad483328fbbf5b3d871c3bfbe Mon Sep 17 00:00:00 2001 From: Son NK Date: Thu, 16 Jan 2020 22:21:19 +0100 Subject: [PATCH] Support cancelled premium users in custom domain & directory - Freemium user can see custom domain and directory but could not add new. - user who has added custom domain or directory before could delete them --- app/dashboard/templates/dashboard/custom_domain.html | 6 ++++++ app/dashboard/templates/dashboard/directory.html | 6 ++++++ app/dashboard/views/custom_domain.py | 9 ++++----- app/dashboard/views/directory.py | 11 +++++------ app/dashboard/views/domain_detail.py | 10 ---------- server.py | 4 ++++ 6 files changed, 25 insertions(+), 21 deletions(-) diff --git a/app/dashboard/templates/dashboard/custom_domain.html b/app/dashboard/templates/dashboard/custom_domain.html index 6423fe44..f62df05d 100644 --- a/app/dashboard/templates/dashboard/custom_domain.html +++ b/app/dashboard/templates/dashboard/custom_domain.html @@ -13,6 +13,12 @@

Custom Domains

+ {% if not current_user.is_premium() %} + + {% endif %} + {% for custom_domain in custom_domains %}
diff --git a/app/dashboard/templates/dashboard/directory.html b/app/dashboard/templates/dashboard/directory.html index 8fe2c951..b1cc830a 100644 --- a/app/dashboard/templates/dashboard/directory.html +++ b/app/dashboard/templates/dashboard/directory.html @@ -10,6 +10,12 @@

Directories

+ {% if not current_user.is_premium() %} + + {% endif %} +