diff --git a/billard/templatetags/display_client.py b/billard/templatetags/display_client.py index d15f81a..f4a0c91 100644 --- a/billard/templatetags/display_client.py +++ b/billard/templatetags/display_client.py @@ -17,28 +17,9 @@ def display_client(client, desk_no): loc = desk.client.location if not desk.enabled: return '' - alert = 'alert-success' acc = desk.accounting_set.all()[:3][::-1] - if acc is not None and len(acc) > 0: - a = acc[-1] - if a.time_to is None: - alert = 'alert-info' - prize, u1, u2 = utils.get_prize_for( - start=a.time_from, - end=datetime.now(), - pph=desk.prize, - hh_start=loc.happy_hour_start, - hh_end=loc.happy_hour_end, - pphh=desk.prize_hh, - ) - prize = '{0:.2f}'.format(prize) - if prize != a.prize: - a.prize = prize - before5min = datetime.now() - timedelta(minutes=5) - if client.last_seen is not None and client.last_seen < before5min: - alert = 'alert-danger' html = '