Commits

Kai Diefenbach committed 5f2e464

Removed template tag 'transitions'. This should be on application level.

  • Participants
  • Parent commits 03fcf74

Comments (0)

Files changed (3)

File workflows/templates/workflows/transitions.html

-{% load i18n %}
-<label>{{ state.name }}</label>
-<select name="transition">
-    {% for transition in transitions %}
-        <option {% if transition.selected %}selected="selected"{% endif %}
-                value="{{ transition.id }}">
-            {{ transition.name }}
-        </option>
-    {% endfor %}
-</select>

File workflows/templatetags/__init__.py

Empty file removed.

File workflows/templatetags/workflows_tags.py

-# django imports
-from django import template
-
-# workflows imports
-import workflows.utils
-
-register = template.Library()
-
-@register.inclusion_tag('workflows/transitions.html', takes_context=True)
-def transitions(context, obj):
-    """
-    """
-    request = context.get("request")
-    
-    return {
-        "transitions" : workflows.utils.get_allowed_transitions(obj, request.user),
-        "state" : workflows.utils.get_state(obj),
-    }