diff --git a/vendor/regidesk/regidesk/migrations/0003_auto_20180121_1023.py b/vendor/regidesk/regidesk/migrations/0003_auto_20180121_1023.py new file mode 100644 index 00000000..86a2ffc1 --- /dev/null +++ b/vendor/regidesk/regidesk/migrations/0003_auto_20180121_1023.py @@ -0,0 +1,30 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.11.9 on 2018-01-20 23:23 +from __future__ import unicode_literals + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('regidesk', '0002_auto_20180120_1726'), + ] + + operations = [ + migrations.AddField( + model_name='checkin', + name='checked_in_bool', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='checkin', + name='exception_set', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='checkin', + name='exception_text', + field=models.TextField(blank=True), + ), + ] diff --git a/vendor/regidesk/regidesk/models.py b/vendor/regidesk/regidesk/models.py index 5a339804..6589ee9d 100644 --- a/vendor/regidesk/regidesk/models.py +++ b/vendor/regidesk/regidesk/models.py @@ -5,6 +5,7 @@ from decimal import Decimal from io import BytesIO from django.core.exceptions import ValidationError +from django.utils import timezone from django.db import models from django.db.models import Q, F @@ -72,6 +73,9 @@ class CheckIn(models.Model): _checkin_code_png=models.TextField(max_length=512,null=True,blank=True) badge_printed = models.BooleanField(default=False) schwag_given = models.BooleanField(default=False) + checked_in_bool = models.BooleanField(default=False) + exception_set = models.BooleanField(default=False) + exception_text = models.TextField(blank=True) class Meta: permissions = ( @@ -85,6 +89,11 @@ class CheckIn(models.Model): self.checkin_code = checkin_code return super(CheckIn, self).save(*a, **k) + def mark_checked_in(self): + self.checked_in_bool = True + self.checked_in = timezone.now() + self.save() + def mark_badge_printed(self): self.badge_printed = True self.save() @@ -98,6 +107,11 @@ class CheckIn(models.Model): self.schwag_given = True self.save() + def set_exception(self, text): + self.exception_set = True + self.exception_text = text + self.save() + @property def code(self): return self.checkin_code diff --git a/vendor/regidesk/regidesk/templates/regidesk/ci_overview.html b/vendor/regidesk/regidesk/templates/regidesk/ci_overview.html index aafed23d..7125aedc 100644 --- a/vendor/regidesk/regidesk/templates/regidesk/ci_overview.html +++ b/vendor/regidesk/regidesk/templates/regidesk/ci_overview.html @@ -34,6 +34,20 @@ +
+
Check In
+
+
+
Status
{% if check_in.checked_in_bool %}Checked in{% else %}Not checked in{% endif %}
+
+
+ + +
+
+
+ +
Badge
@@ -61,6 +75,17 @@
+
+
Log Exception
+
+
+ +

Reminder: Please tell attendee to email boarding@lca2018.org with the details as well

+ +
+
+
+
Bulk actions
diff --git a/vendor/regidesk/regidesk/views.py b/vendor/regidesk/regidesk/views.py index e9cca5a9..62f1ab96 100644 --- a/vendor/regidesk/regidesk/views.py +++ b/vendor/regidesk/regidesk/views.py @@ -302,12 +302,16 @@ def check_in_overview(request, access_code): return render(request, "regidesk/ci_code_404.html", {}) check_in = check_in[0] if request.method == 'POST': - if 'badge' in request.POST: + if 'checkin' in request.POST: + check_in.mark_checked_in() + elif 'badge' in request.POST: check_in.mark_badge_printed() elif 'schwag' in request.POST: check_in.mark_schwag_given() elif 'bulk' in request.POST: check_in.bulk_mark_given() + elif 'exception' in request.POST: + check_in.set_exception(request.POST['exception']) return redirect(request.path) ctx = { 'check_in': check_in,