From c7d69b4fa12ba3eab5517fa94238c9a2b67d9916 Mon Sep 17 00:00:00 2001 From: simon Date: Sun, 5 Dec 2021 20:26:39 +0700 Subject: [PATCH] use new notification for channel subscribe feedback --- .../home/templates/home/channel.html | 22 ++++++++----------- tubearchivist/home/views.py | 3 --- 2 files changed, 9 insertions(+), 16 deletions(-) diff --git a/tubearchivist/home/templates/home/channel.html b/tubearchivist/home/templates/home/channel.html index 29c998c..a0659cc 100644 --- a/tubearchivist/home/templates/home/channel.html +++ b/tubearchivist/home/templates/home/channel.html @@ -8,19 +8,15 @@
- {% if running == "subscribing" %} -

Subscribing in progress, refresh.

- {% else %} - add-icon -

Subscribe to Channels

-
-
- {% csrf_token %} - {{ subscribe_form }} - -
-
- {% endif %} + add-icon +

Subscribe to Channels

+
+
+ {% csrf_token %} + {{ subscribe_form }} + +
+
diff --git a/tubearchivist/home/views.py b/tubearchivist/home/views.py index b55bfac..cdc4a82 100644 --- a/tubearchivist/home/views.py +++ b/tubearchivist/home/views.py @@ -489,7 +489,6 @@ class ChannelView(View): "title": "Channels", "colors": view_config["colors"], "view_style": view_config["view_style"], - "running": view_config["running"], } return render(request, "home/channel.html", context) @@ -499,7 +498,6 @@ class ChannelView(View): config_handler = AppConfig(user_id) view_key = f"{user_id}:view:channel" view_style = RedisArchivist().get_message(view_key)["status"] - running = RedisArchivist().get_message("progress:subscribe")["status"] if not view_style: view_style = config_handler.config["default_view"]["channel"] @@ -511,7 +509,6 @@ class ChannelView(View): "view_style": view_style, "show_subed_only": show_subed_only, "colors": config_handler.colors, - "running": running, } return view_config