MY SKY: dashboard applet + full-page natal chart — TDD
- User model: sky_birth_dt/lat/lon/place/house_system/chart_data fields (lyric migration 0018) - Applet seed: my-sky (6×6, dashboard context) via applets migration 0009 - dashboard/sky/ — full monoapplet page: natus form + D3 wheel, LS key scoped to dashboard:sky; saves to User model - dashboard/sky/preview/ — PySwiss proxy (same logic as epic:natus_preview, no seat check) - dashboard/sky/save/ — persists 6 sky fields to User via update_fields - _applet-my-sky.html: tile with h2 link to /dashboard/sky/ - 2 FTs (applet→link→form, localStorage persistence) + 12 ITs — all green Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
40
src/apps/lyric/migrations/0018_user_sky_fields.py
Normal file
40
src/apps/lyric/migrations/0018_user_sky_fields.py
Normal file
@@ -0,0 +1,40 @@
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
dependencies = [
|
||||
('lyric', '0017_ap_keypair_fields'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AddField(
|
||||
model_name='user',
|
||||
name='sky_birth_dt',
|
||||
field=models.DateTimeField(blank=True, null=True),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='user',
|
||||
name='sky_birth_lat',
|
||||
field=models.DecimalField(blank=True, decimal_places=4, max_digits=9, null=True),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='user',
|
||||
name='sky_birth_lon',
|
||||
field=models.DecimalField(blank=True, decimal_places=4, max_digits=9, null=True),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='user',
|
||||
name='sky_birth_place',
|
||||
field=models.CharField(blank=True, max_length=255),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='user',
|
||||
name='sky_house_system',
|
||||
field=models.CharField(blank=True, default='O', max_length=1),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name='user',
|
||||
name='sky_chart_data',
|
||||
field=models.JSONField(blank=True, null=True),
|
||||
),
|
||||
]
|
||||
@@ -47,6 +47,14 @@ class User(AbstractBaseUser):
|
||||
ap_public_key = models.TextField(blank=True, default="")
|
||||
ap_private_key = models.TextField(blank=True, default="")
|
||||
|
||||
# Personal natal chart (My Sky) — independent of any game room/character
|
||||
sky_birth_dt = models.DateTimeField(null=True, blank=True)
|
||||
sky_birth_lat = models.DecimalField(max_digits=9, decimal_places=4, null=True, blank=True)
|
||||
sky_birth_lon = models.DecimalField(max_digits=9, decimal_places=4, null=True, blank=True)
|
||||
sky_birth_place = models.CharField(max_length=255, blank=True)
|
||||
sky_house_system = models.CharField(max_length=1, blank=True, default="O")
|
||||
sky_chart_data = models.JSONField(null=True, blank=True)
|
||||
|
||||
is_staff = models.BooleanField(default=False)
|
||||
is_superuser = models.BooleanField(default=False)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user