diff --git a/castellum/appointments/forms.py b/castellum/appointments/forms.py
index 5b8e473f78de9a559dec8d1c1a8d5fcbd9e5aa32..371b9c29a794a88aa9973e34cb826262b16398cb 100644
--- a/castellum/appointments/forms.py
+++ b/castellum/appointments/forms.py
@@ -119,7 +119,6 @@ class AppointmentsForm(forms.ModelForm):
self.appointment_changes.append((appointment.start, start))
appointment.start = start
appointment.reminded = False
- appointment.show_up = Appointment.SHOWUP # reset to default
appointment.save()
elif start:
self.appointment_changes.append((None, start))
diff --git a/castellum/appointments/migrations/0003_remove_appointment_show_up.py b/castellum/appointments/migrations/0003_remove_appointment_show_up.py
new file mode 100644
index 0000000000000000000000000000000000000000..1d92588a84970cc78992e4a5cf3beef06c67674b
--- /dev/null
+++ b/castellum/appointments/migrations/0003_remove_appointment_show_up.py
@@ -0,0 +1,17 @@
+# Generated by Django 3.2 on 2021-05-04 07:31
+
+from django.db import migrations
+
+
+class Migration(migrations.Migration):
+
+ dependencies = [
+ ('appointments', '0002_status_wording'),
+ ]
+
+ operations = [
+ migrations.RemoveField(
+ model_name='appointment',
+ name='show_up',
+ ),
+ ]
diff --git a/castellum/appointments/models.py b/castellum/appointments/models.py
index 7bcc61ab4f0fc765502bd17554efa9c6d28ec201..e957cb78de2610fa04665886eb1f75cccea70922 100644
--- a/castellum/appointments/models.py
+++ b/castellum/appointments/models.py
@@ -35,20 +35,6 @@ MINUTE = datetime.timedelta(seconds=60)
class Appointment(models.Model):
- SHOWUP = 1
- LATE = 2
- EXCUSED = 3
- NOSHOW = 4
-
- SHOWUP_CHOICES = [
- (SHOWUP, _('no issues')),
- (LATE, _('late')),
- (EXCUSED, _('excused')),
- (NOSHOW, _('no show')),
- ]
-
- SHOWUP_OK = [SHOWUP, LATE]
-
session = models.ForeignKey(StudySession, verbose_name=_('Session'), on_delete=models.CASCADE)
start = DateTimeField(_('Start'))
reminded = models.BooleanField(_('Reminded'), default=False)
@@ -57,7 +43,6 @@ class Appointment(models.Model):
on_delete=models.CASCADE,
verbose_name=_('Participation'),
)
- show_up = models.SmallIntegerField(_('Show up'), default=SHOWUP, choices=SHOWUP_CHOICES)
class Meta:
verbose_name = _('Appointment')
diff --git a/castellum/appointments/templatetags/appointments.py b/castellum/appointments/templatetags/appointments.py
deleted file mode 100644
index ed24a42e3f4f7f9433a54dc2487482b16774f11b..0000000000000000000000000000000000000000
--- a/castellum/appointments/templatetags/appointments.py
+++ /dev/null
@@ -1,53 +0,0 @@
-# (c) 2018-2021
-# MPIB ,
-# MPI-CBS ,
-# MPIP
-#
-# This file is part of Castellum.
-#
-# Castellum is free software; you can redistribute it and/or modify it
-# under the terms of the GNU Affero General Public License as published
-# by the Free Software Foundation; either version 3 of the License, or
-# (at your option) any later version.
-#
-# Castellum is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# Affero General Public License for more details.
-#
-# You should have received a copy of the GNU Affero General Public
-# License along with Castellum. If not, see
-# .
-
-from django import template
-from django.utils.translation import gettext_lazy as _
-
-from castellum.appointments.models import Appointment
-
-register = template.Library()
-
-
-@register.filter
-def showup_level(subject):
- subject.annotate_showup_stats()
-
- if subject.showup_score > 6:
- return 'danger'
- elif subject.showup_score > 2:
- return 'warning'
- else:
- return 'success'
-
-
-@register.filter
-def showup_summary(subject):
- subject.annotate_showup_stats()
-
- labelled = []
- for status, label in Appointment.SHOWUP_CHOICES:
- count = getattr(subject, 'showup_{}'.format(status))
- if count:
- labelled.append((label, count))
-
- formatted = ', '.join('{}: {}'.format(label, count) for label, count in labelled)
- return formatted or _('no appointments so far')
diff --git a/castellum/contacts/templates/contacts/__contact.html b/castellum/contacts/templates/contacts/__contact.html
index 0fc344e9646c71870ae53da2eb91338904154f23..f42950614e0874201718766c7b030c0fa22652a0 100644
--- a/castellum/contacts/templates/contacts/__contact.html
+++ b/castellum/contacts/templates/contacts/__contact.html
@@ -1,4 +1,4 @@
-{% load i18n auth utils appointments %}
+{% load i18n auth utils %}
{% for guardian in subject.contact.guardians.all %}
{% has_privacy_level guardian.subject.privacy_level user as can_access %}
@@ -23,13 +23,3 @@
{% empty %}
{% include 'contacts/__contact_detail.html' with contact=subject.contact %}
{% endfor %}
-
-
- - {% translate "Show up rate" %}
- -
- ●
- {% with summary=subject|showup_summary %}
- {% if summary %}({{ summary }}){% endif %}
- {% endwith %}
-
-
diff --git a/castellum/execution/templates/execution/participation_appointments.html b/castellum/execution/templates/execution/participation_appointments.html
deleted file mode 100644
index 12b7eddcfbabd05cc66d470f11b9d62434498c64..0000000000000000000000000000000000000000
--- a/castellum/execution/templates/execution/participation_appointments.html
+++ /dev/null
@@ -1,34 +0,0 @@
-{% extends "execution/participation_base.html" %}
-{% load i18n auth bootstrap4 utils %}
-
-{% block content %}
-
- {% for session, appointment, form in appointments %}
- - {{ session.name }}
- -
- {% if appointment %}
-
-
-
-
- {% else %}
- —
- {% endif %}
-
- {% empty %}
-
- - {% translate 'No sessions' %}
- {% endfor %}
-
-
- {% has_perm 'appointments.change_appointment' user study as can_change_appointment %}
- {% if can_change_appointment %}
-
- {% endif %}
-{% endblock %}
diff --git a/castellum/execution/templates/execution/participation_detail.html b/castellum/execution/templates/execution/participation_detail.html
index dc58bb5e533b094e71f67a86fe1c4d19affd80fd..851debbbf315431dfc195fb241a22d7a60fd8c07 100644
--- a/castellum/execution/templates/execution/participation_detail.html
+++ b/castellum/execution/templates/execution/participation_detail.html
@@ -1,5 +1,5 @@
{% extends "execution/participation_base.html" %}
-{% load i18n utils auth appointments %}
+{% load i18n utils auth %}
{% block content %}
{% if pseudonyms|length > 1 %}
diff --git a/castellum/execution/templates/execution/study_base.html b/castellum/execution/templates/execution/study_base.html
index 27e5c7f5a6af9672be04299ac968dfd6aa2c60a1..dfa7ff6313987c1c111d068f3fd35030603d9a82 100644
--- a/castellum/execution/templates/execution/study_base.html
+++ b/castellum/execution/templates/execution/study_base.html
@@ -1,5 +1,5 @@
{% extends "execution/base.html" %}
-{% load i18n appointments %}
+{% load i18n %}
{% block title %}{{ study }} · {{ block.super }}{% endblock %}
diff --git a/castellum/execution/templates/execution/study_detail.html b/castellum/execution/templates/execution/study_detail.html
index fdd3840c162c4c83ca6a6ed226666cde33ac4ca3..3b6ea3254038d52331c83b7f4a6a10d998dd38ef 100644
--- a/castellum/execution/templates/execution/study_detail.html
+++ b/castellum/execution/templates/execution/study_detail.html
@@ -1,5 +1,5 @@
{% extends "execution/study_base.html" %}
-{% load i18n appointments utils %}
+{% load i18n utils %}
{% block content %}