Add member profile for shackspace

This commit is contained in:
Tobias Kunze 2017-12-06 20:22:36 +01:00
parent 3da120f1c6
commit 074f789a1e
3 changed files with 52 additions and 0 deletions

View File

@ -0,0 +1,33 @@
# Generated by Django 2.0 on 2017-12-06 19:22
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
('members', '0005_auto_20171206_1919'),
]
operations = [
migrations.CreateModel(
name='ShackProfile',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('has_loeffelhardt_account', models.BooleanField(default=False)),
('has_matomat_key', models.BooleanField(default=False)),
('has_metro_card', models.BooleanField(default=False)),
('has_safe_key', models.BooleanField(default=False)),
('has_selgros_card', models.BooleanField(default=False)),
('has_shack_iron_key', models.BooleanField(default=False)),
('has_snackomat_key', models.BooleanField(default=False)),
('is_keyholder', models.BooleanField(default=False)),
('signed_DSV', models.BooleanField(default=False)),
('ssh_public_key', models.TextField(blank=True, null=True)),
('member', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='profile_shack', to='members.Member')),
],
),
]

View File

19
byro_shackspace/models.py Normal file
View File

@ -0,0 +1,19 @@
from django.db import models
class ShackProfile(models.Model):
member = models.ForeignKey(
to='members.Member',
on_delete=models.CASCADE,
related_name='profile_shack',
)
has_loeffelhardt_account = models.BooleanField(default=False)
has_matomat_key = models.BooleanField(default=False)
has_metro_card = models.BooleanField(default=False)
has_safe_key = models.BooleanField(default=False)
has_selgros_card = models.BooleanField(default=False)
has_shack_iron_key = models.BooleanField(default=False)
has_snackomat_key = models.BooleanField(default=False)
is_keyholder = models.BooleanField(default=False)
signed_DSV = models.BooleanField(default=False)
ssh_public_key = models.TextField(null=True, blank=True)