Revision 9c4e0410

b/cron_notify_expired.py
10 10
def notify_expired():
11 11
    routes = Route.objects.all()
12 12
    for route in routes:
13
        if route.status != 'EXPIRED':
13
        if route.status not in ['EXPIRED', 'ADMININACTIVE', 'ERROR']:
14 14
            expiration_days = (route.expires - datetime.date.today()).days
15 15
            if expiration_days < settings.EXPIRATION_NOTIFY_DAYS:
16 16
                try:
b/templates/user_routes.html
170 170
	<td style="text-align: center;">{{route.get_then|safe|escape}}</td>
171 171
	<td style="text-align: center; ">
172 172
		<span 
173
		{% if route.days_to_expire and route.days_to_expire >= 0 %}
173
		{% if route.days_to_expire %}
174 174
		class="expiresclass" 
175 175
		style="border-bottom:2px dashed red;" 
176 176
        title="Expires {% ifequal route.days_to_expire '0' %}today{% else%}in {{route.days_to_expire}} day{{ route.days_to_expire|pluralize }}{% endifequal %}"

Also available in: Unified diff