from django.contrib.auth.models import Group


def is_supervisor(user):
    return user.is_authenticated and user.groups.filter(name='Supervisors').exists()


def is_manager(user):
    return user.is_authenticated and user.groups.filter(name='Managers').exists()

