mirror of
https://github.com/tanrax/django-interactive-frameworks-benchmark
synced 2026-01-09 06:43:37 +01:00
Real-time alert system using Django LiveView with WebSocket support. Features include: - Real-time alert creation, viewing, and deletion - Broadcast notifications to all connected users - SQLite database - Stimulus.js integration for interactive UI - Modal dialogs for alert details - Alert form with validation Fixed Stimulus controller scope issue by placing data-controller on html element.
27 lines
795 B
Python
27 lines
795 B
Python
# Generated by Django 5.1.4 on 2025-12-08 10:23
|
|
|
|
from django.db import migrations, models
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
initial = True
|
|
|
|
dependencies = [
|
|
]
|
|
|
|
operations = [
|
|
migrations.CreateModel(
|
|
name='Alert',
|
|
fields=[
|
|
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
|
|
('type', models.CharField(choices=[('INFO', 'Info'), ('WARNING', 'Warning'), ('CRITICAL', 'Critical')], max_length=10)),
|
|
('description', models.TextField(blank=True, default='')),
|
|
('created_at', models.DateTimeField(auto_now_add=True)),
|
|
],
|
|
options={
|
|
'ordering': ['-created_at'],
|
|
},
|
|
),
|
|
]
|