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 @@ - - - {% block title %}Knowledge Base{% endblock %} - {% if project_description %} - - - - {% endif %} - {% if project_image_url %} - - - {% endif %} - {% load static %} - - {% block head %}{% endblock %} + + + {% block title %}TeamLink{% endblock %} + + {% load static %} + + + {% block head %}{% endblock %} - - {% block content %}{% endblock %} - + - +
+ {% block content %}{% endblock %} +
+ + + + + {% block scripts %}{% endblock %} + + \ No newline at end of file diff --git a/core/templates/core/index.html b/core/templates/core/index.html index faec813..fcced2d 100644 --- a/core/templates/core/index.html +++ b/core/templates/core/index.html @@ -1,145 +1,86 @@ {% extends "base.html" %} +{% load static %} -{% block title %}{{ project_name }}{% endblock %} - -{% block head %} - - - - -{% endblock %} +{% block title %}TeamLink - Organization Member Database{% endblock %} {% block content %} -
-
-

Analyzing your requirements and generating your app…

-
- Loading… +
+
+
+
+

Connecting our
People and Purpose

+

The centralized hub for managing Staff, Board Members, and Youth Volunteers. Secure, searchable, and always accessible.

+ +
+
+
+

Quick Stats

+
+
+
+ {{ stats.total }} + Total Members +
+
+
+
+ {{ stats.staff }} + Staff +
+
+
+
+ {{ stats.board }} + Board +
+
+
+
+ {{ stats.volunteers }} + Volunteers +
+
+
+
+
+
-

AppWizzy AI is collecting your requirements and applying the first changes.

-

This page will refresh automatically as the plan is implemented.

-

- Runtime: Django {{ django_version }} · Python {{ python_version }} - — UTC {{ current_time|date:"Y-m-d H:i:s" }} -

-
-
- -{% endblock %} \ No newline at end of file + + +
+
+
+
+

One Secure Location for All Team Records

+

Effortlessly manage your organization's core contacts with advanced search, role-based filtering, and administrative oversight.

+
+
+
+
+
+
+
Secure Management
+

Admin-only data entry ensures your sensitive member data is protected and managed by authorized staff only.

+
+
+
+
+
+
Quick Discovery
+

Instantly find any staff member, board representative, or volunteer using our powerful search and filter tools.

+
+
+
+
+
+
Reporting Ready
+

Our structured data model makes it easy to export and report on your organization's human resources at any time.

+
+
+
+
+
+{% endblock %} diff --git a/core/urls.py b/core/urls.py index 6299e3d..8eebdac 100644 --- a/core/urls.py +++ b/core/urls.py @@ -1,7 +1,8 @@ from django.urls import path - -from .views import home +from .views import home, member_list, member_detail urlpatterns = [ path("", home, name="home"), -] + path("members/", member_list, name="member_list"), + path("members//", member_detail, name="member_detail"), +] \ No newline at end of file diff --git a/core/views.py b/core/views.py index c9aed12..e8707d0 100644 --- a/core/views.py +++ b/core/views.py @@ -2,24 +2,53 @@ import os import platform from django import get_version as django_version -from django.shortcuts import render +from django.shortcuts import render, get_object_or_404 from django.utils import timezone - +from .models import Member def home(request): - """Render the landing screen with loader and environment details.""" + """Render the landing screen with directory stats.""" host_name = request.get_host().lower() agent_brand = "AppWizzy" if host_name == "appwizzy.com" else "Flatlogic" - now = timezone.now() + + stats = { + 'total': Member.objects.count(), + 'staff': Member.objects.filter(role='STAFF').count(), + 'board': Member.objects.filter(role='BOARD').count(), + 'volunteers': Member.objects.filter(role='YOUTH_VOLUNTEER').count(), + } context = { - "project_name": "New Style", + "project_name": "TeamLink", "agent_brand": agent_brand, "django_version": django_version(), "python_version": platform.python_version(), - "current_time": now, - "host_name": host_name, - "project_description": os.getenv("PROJECT_DESCRIPTION", ""), - "project_image_url": os.getenv("PROJECT_IMAGE_URL", ""), + "current_time": timezone.now(), + "stats": stats, } return render(request, "core/index.html", context) + +def member_list(request): + """View to list all members with filtering and search.""" + query = request.GET.get('q') + role_filter = request.GET.get('role') + + members = Member.objects.all() + + if query: + members = members.filter(full_name__icontains=query) | members.filter(email__icontains=query) + + if role_filter: + members = members.filter(role=role_filter) + + context = { + "members": members, + "query": query, + "role_filter": role_filter, + } + return render(request, "core/member_list.html", context) + +def member_detail(request, pk): + """View for individual member details.""" + member = get_object_or_404(Member, pk=pk) + return render(request, "core/member_detail.html", {"member": member}) \ No newline at end of file diff --git a/static/css/custom.css b/static/css/custom.css index 925f6ed..1f078fd 100644 --- a/static/css/custom.css +++ b/static/css/custom.css @@ -1,4 +1,100 @@ -/* Custom styles for the application */ -body { - font-family: system-ui, -apple-system, sans-serif; +@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=Outfit:wght@600;700&display=swap'); + +:root { + --primary-color: #10b981; /* Vibrant Emerald */ + --secondary-color: #1a1d23; /* Deep Charcoal */ + --bg-color: #f8fafc; /* Soft Slate */ + --text-color: #334155; + --heading-font: 'Outfit', sans-serif; + --body-font: 'Inter', sans-serif; } + +body { + background-color: var(--bg-color); + color: var(--text-color); + font-family: var(--body-font); + line-height: 1.6; +} + +h1, h2, h3, h4, h5, h6 { + font-family: var(--heading-font); + color: var(--secondary-color); + font-weight: 700; +} + +.hero-section { + background: linear-gradient(135deg, var(--secondary-color) 0%, #334155 100%); + color: white; + padding: 100px 0; + margin-bottom: 50px; + border-radius: 0 0 30px 30px; +} + +.hero-section h1 { + color: white; + font-size: 3.5rem; + margin-bottom: 20px; +} + +.card { + border: none; + border-radius: 15px; + box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06); + transition: transform 0.2s; +} + +.card:hover { + transform: translateY(-5px); +} + +.btn-primary { + background-color: var(--primary-color); + border-color: var(--primary-color); + border-radius: 8px; + padding: 10px 25px; + font-weight: 600; +} + +.btn-primary:hover { + background-color: #059669; + border-color: #059669; +} + +.stat-card { + padding: 20px; + text-align: center; +} + +.stat-card .number { + font-size: 2.5rem; + color: var(--primary-color); + display: block; +} + +.stat-card .label { + font-weight: 500; + color: #64748b; +} + +.nav-link { + font-weight: 500; + color: var(--secondary-color); +} + +.navbar-brand { + font-family: var(--heading-font); + font-size: 1.5rem; + color: var(--secondary-color) !important; +} + +.badge-staff { background-color: #dcfce7; color: #166534; } +.badge-board { background-color: #dbeafe; color: #1e40af; } +.badge-volunteer { background-color: #fef9c3; color: #854d0e; } + +.search-bar { + background: white; + padding: 20px; + border-radius: 15px; + box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1); + margin-bottom: 30px; +} \ No newline at end of file