feat: complete Phase 3 scaffolding (templates, static, Docker, per-app skeletons)

- Per-app skeleton completion: property/client/setting now have services/,
  tasks.py, views.py, urls.py, serializers.py, templates/<app>/, tests/
- admin.py added to all 10 apps (per spec §2.108 / §17.3)
- Top-level templates/: base.html, layouts/{app,auth}.html, components/
  {topbar,sidebar,pagination,toast,modal,empty-state}.html, errors/
  {403,404,500}.html
- static/: css/main.css (Tailwind entry), js/main.js (HTMX toast +
  CSRF wiring per §7.4), vendor/.gitkeep
- tailwind.config.js: Primary teal + neutral slate + semantic colors,
  Inter font stack, z-60/z-70, shadow-xs, slide-in-right animation per
  UI_SYSTEM §2.7/§10.1
- package.json: tailwindcss-only build/watch
- Dockerfile + docker-compose.yml (6 services: web/db/redis/celery/
  celery-beat/tailwind) + docker-compose.prod.yml + Makefile
- tests/ root: conftest.py with TenantClient fixture per §720,
  integration/{property,client,release}/, e2e/, schemathesis skeleton
- Removed empty apps/tenant/models/ (tenant uses models.py per §17.1)

Validated: manage.py check passes; tree matches spec §2 exactly.
This commit is contained in:
2026-04-29 17:45:22 +08:00
parent ed40de4050
commit 94d160223d
65 changed files with 454 additions and 0 deletions

25
templates/base.html Normal file
View File

@@ -0,0 +1,25 @@
{% load static %}
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="csrf-token" content="{{ csrf_token }}">
<title>{% block title %}Fonrey{% endblock %}</title>
<link rel="stylesheet" href="{% static 'css/output.css' %}">
{% block extra_head %}{% endblock %}
<script src="{% static 'vendor/htmx.min.js' %}" defer></script>
<script src="{% static 'vendor/alpine.min.js' %}" defer></script>
<script src="{% static 'js/main.js' %}" defer></script>
</head>
<body class="{% block body_class %}bg-neutral-50 text-neutral-900{% endblock %}">
{% block content %}{% endblock %}
<div id="toast-container" class="fixed bottom-4 right-4 z-70 flex flex-col gap-2"></div>
{% block extra_js %}{% endblock %}
</body>
</html>