From 4356da19d8ab7ae047d4a449eea4085640ed18f2 Mon Sep 17 00:00:00 2001
From: Samuel Gaist <samuel.gaist@idiap.ch>
Date: Fri, 11 Sep 2020 11:36:40 +0200
Subject: [PATCH] [team][templatetags] Pre-commit cleanup

---
 beat/web/team/templatetags/team_tags.py | 50 ++++++++++++-------------
 1 file changed, 25 insertions(+), 25 deletions(-)

diff --git a/beat/web/team/templatetags/team_tags.py b/beat/web/team/templatetags/team_tags.py
index a4a6474d4..f4bed2b28 100644
--- a/beat/web/team/templatetags/team_tags.py
+++ b/beat/web/team/templatetags/team_tags.py
@@ -26,19 +26,18 @@
 ###############################################################################
 
 
-
 from django import template
 from django.conf import settings
 
 register = template.Library()
 
 
-#--------------------------------------------------
+# --------------------------------------------------
 
 
-@register.inclusion_tag('team/panels/table.html', takes_context=True)
+@register.inclusion_tag("team/panels/table.html", takes_context=True)
 def team_table(context, objects, owner, id):
-    '''Composes a team list table
+    """Composes a team list table
 
     This panel primarily exists for user's team list page.
 
@@ -50,22 +49,22 @@ def team_table(context, objects, owner, id):
         id: The HTML id to set on the generated table. This is handy for the
           filter functionality normally available on list pages.
 
-    '''
+    """
 
     return {
-        'request': context['request'],
-            'objects': objects,
-            'owner': owner,
-            'panel_id': id,
+        "request": context["request"],
+        "objects": objects,
+        "owner": owner,
+        "panel_id": id,
     }
 
 
-#--------------------------------------------------
+# --------------------------------------------------
 
 
-@register.inclusion_tag('team/panels/actions.html', takes_context=True)
+@register.inclusion_tag("team/panels/actions.html", takes_context=True)
 def team_actions(context, obj, display_count):
-    '''Composes the action buttons for a particular team
+    """Composes the action buttons for a particular team
 
     This panel primarily exists for showing action buttons for a given
     team taking into consideration it is being displayed for a given user.
@@ -78,29 +77,30 @@ def team_actions(context, obj, display_count):
         display_count (bool): If true, displays the number of elements in the
           team in a button
 
-    '''
+    """
     return {
-        'request': context['request'],
-            'display_count': display_count,
-            'object': obj,
+        "request": context["request"],
+        "display_count": display_count,
+        "object": obj,
     }
 
 
-#--------------------------------------------------
+# --------------------------------------------------
 
 
-@register.inclusion_tag('ui/contribution_list.html')
+@register.inclusion_tag("ui/contribution_list.html")
 def user_list(id):
-    return { 'panel_id': id,
-             'URL_PREFIX': settings.URL_PREFIX,
-             'finder_placeholder': 'Find an User...',
-             'owner': False,
-           }
+    return {
+        "panel_id": id,
+        "URL_PREFIX": settings.URL_PREFIX,
+        "finder_placeholder": "Find an User...",
+        "owner": False,
+    }
 
 
-#--------------------------------------------------
+# --------------------------------------------------
 
 
 @register.simple_tag(takes_context=True)
 def total_shares_for_user(context, team):
-    return team.total_shares(context['request'].user)
+    return team.total_shares(context["request"].user)
-- 
GitLab