diff --git a/config/__pycache__/__init__.cpython-311.pyc b/config/__pycache__/__init__.cpython-311.pyc index bf43253..220ed7e 100644 Binary files a/config/__pycache__/__init__.cpython-311.pyc and b/config/__pycache__/__init__.cpython-311.pyc differ diff --git a/config/__pycache__/settings.cpython-311.pyc b/config/__pycache__/settings.cpython-311.pyc index 881731c..b7e7e6c 100644 Binary files a/config/__pycache__/settings.cpython-311.pyc and b/config/__pycache__/settings.cpython-311.pyc differ diff --git a/config/__pycache__/urls.cpython-311.pyc b/config/__pycache__/urls.cpython-311.pyc index 42d995d..e83ab0a 100644 Binary files a/config/__pycache__/urls.cpython-311.pyc and b/config/__pycache__/urls.cpython-311.pyc differ diff --git a/config/__pycache__/wsgi.cpython-311.pyc b/config/__pycache__/wsgi.cpython-311.pyc index e65b92e..0815ad8 100644 Binary files a/config/__pycache__/wsgi.cpython-311.pyc and b/config/__pycache__/wsgi.cpython-311.pyc differ diff --git a/core/__pycache__/__init__.cpython-311.pyc b/core/__pycache__/__init__.cpython-311.pyc index c26577c..7f00dd1 100644 Binary files a/core/__pycache__/__init__.cpython-311.pyc and b/core/__pycache__/__init__.cpython-311.pyc differ diff --git a/core/__pycache__/admin.cpython-311.pyc b/core/__pycache__/admin.cpython-311.pyc index 2964e11..72315d4 100644 Binary files a/core/__pycache__/admin.cpython-311.pyc and b/core/__pycache__/admin.cpython-311.pyc differ diff --git a/core/__pycache__/apps.cpython-311.pyc b/core/__pycache__/apps.cpython-311.pyc index 45edf7a..f1159ac 100644 Binary files a/core/__pycache__/apps.cpython-311.pyc and b/core/__pycache__/apps.cpython-311.pyc differ diff --git a/core/__pycache__/models.cpython-311.pyc b/core/__pycache__/models.cpython-311.pyc index 18a063c..b44c71c 100644 Binary files a/core/__pycache__/models.cpython-311.pyc and b/core/__pycache__/models.cpython-311.pyc differ diff --git a/core/__pycache__/urls.cpython-311.pyc b/core/__pycache__/urls.cpython-311.pyc index ebb8c6e..98a257e 100644 Binary files a/core/__pycache__/urls.cpython-311.pyc and b/core/__pycache__/urls.cpython-311.pyc differ diff --git a/core/__pycache__/views.cpython-311.pyc b/core/__pycache__/views.cpython-311.pyc index 8d204fa..3eabef6 100644 Binary files a/core/__pycache__/views.cpython-311.pyc and b/core/__pycache__/views.cpython-311.pyc differ diff --git a/core/admin.py b/core/admin.py index 8c38f3f..29775d3 100644 --- a/core/admin.py +++ b/core/admin.py @@ -1,3 +1,9 @@ from django.contrib import admin +from .models import Member -# Register your models here. +@admin.register(Member) +class MemberAdmin(admin.ModelAdmin): + list_display = ('full_name', 'email', 'role', 'status', 'join_date') + list_filter = ('role', 'status', 'join_date') + search_fields = ('full_name', 'email', 'notes') + list_per_page = 25 \ No newline at end of file diff --git a/core/migrations/0001_initial.py b/core/migrations/0001_initial.py new file mode 100644 index 0000000..b78eac2 --- /dev/null +++ b/core/migrations/0001_initial.py @@ -0,0 +1,30 @@ +# Generated by Django 5.2.7 on 2026-02-24 00:57 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='Member', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('full_name', models.CharField(max_length=255)), + ('email', models.EmailField(max_length=254, unique=True)), + ('phone', models.CharField(blank=True, max_length=20, null=True)), + ('role', models.CharField(choices=[('STAFF', 'Staff'), ('BOARD', 'Board Member'), ('YOUTH_VOLUNTEER', 'Youth Volunteer')], default='STAFF', max_length=20)), + ('status', models.CharField(choices=[('ACTIVE', 'Active'), ('INACTIVE', 'Inactive')], default='ACTIVE', max_length=10)), + ('join_date', models.DateField(auto_now_add=True)), + ('notes', models.TextField(blank=True, null=True)), + ], + options={ + 'ordering': ['-join_date'], + }, + ), + ] diff --git a/core/migrations/__pycache__/0001_initial.cpython-311.pyc b/core/migrations/__pycache__/0001_initial.cpython-311.pyc new file mode 100644 index 0000000..4c9e8f5 Binary files /dev/null and b/core/migrations/__pycache__/0001_initial.cpython-311.pyc differ diff --git a/core/migrations/__pycache__/__init__.cpython-311.pyc b/core/migrations/__pycache__/__init__.cpython-311.pyc index 5b49a39..401d184 100644 Binary files a/core/migrations/__pycache__/__init__.cpython-311.pyc and b/core/migrations/__pycache__/__init__.cpython-311.pyc differ diff --git a/core/models.py b/core/models.py index 71a8362..60d2206 100644 --- a/core/models.py +++ b/core/models.py @@ -1,3 +1,27 @@ from django.db import models -# Create your models here. +class Member(models.Model): + ROLE_CHOICES = [ + ('STAFF', 'Staff'), + ('BOARD', 'Board Member'), + ('YOUTH_VOLUNTEER', 'Youth Volunteer'), + ] + + STATUS_CHOICES = [ + ('ACTIVE', 'Active'), + ('INACTIVE', 'Inactive'), + ] + + full_name = models.CharField(max_length=255) + email = models.EmailField(unique=True) + phone = models.CharField(max_length=20, blank=True, null=True) + role = models.CharField(max_length=20, choices=ROLE_CHOICES, default='STAFF') + status = models.CharField(max_length=10, choices=STATUS_CHOICES, default='ACTIVE') + join_date = models.DateField(auto_now_add=True) + notes = models.TextField(blank=True, null=True) + + def __str__(self): + return f"{self.full_name} ({self.get_role_display()})" + + class Meta: + ordering = ['-join_date'] \ No newline at end of file diff --git a/core/templates/base.html b/core/templates/base.html index 1e7e5fb..ca2143d 100644 --- a/core/templates/base.html +++ b/core/templates/base.html @@ -1,25 +1,53 @@ -
- -