<commit_before># -*- coding: utf-8 -*-

from django import template
from Instanssi.kompomaatti.models import Compo, Competition

register = template.Library()

@register.inclusion_tag('kompomaatti/compo_nav_items.html')
def render_base_compos_nav(event_id):
    return {
        'event_id': event_id,
        'compos': Compo.objects.filter(active=True, event_id=event_id)
    }

@register.inclusion_tag('kompomaatti/competition_nav_items.html')
def render_base_competitions_nav(event_id):
    return {
        'event_id': event_id,
        'competitions': Competition.objects.filter(active=True, event_id=event_id)
    }<commit_msg>kompomaatti: Update tags to use new template subdirectory.<commit_after># -*- coding: utf-8 -*-

from django import template
from Instanssi.kompomaatti.models import Compo, Competition

register = template.Library()

@register.inclusion_tag('kompomaatti/tags/compo_nav_items.html')
def render_base_compos_nav(event_id):
    return {
        'event_id': event_id,
        'compos': Compo.objects.filter(active=True, event_id=event_id)
    }

@register.inclusion_tag('kompomaatti/tags/competition_nav_items.html')
def render_base_competitions_nav(event_id):
    return {
        'event_id': event_id,
        'competitions': Competition.objects.filter(active=True, event_id=event_id)
    }
{'fraction_non_alphanumeric': 0.11372251705837756, 'fraction_numerical': 0.001516300227445034, 'mean_word_length': 4.814977973568282, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5009777', 'n_tokens_mistral': 441, 'n_tokens_neox': 439, 'n_words': 71}