diora-web/podcasts/migrations/0023_episode_fts.py
mrwnslz 3fa16b9653
Some checks failed
Test / e2e (push) Waiting to run
Build and push Docker image / build (push) Successful in 16s
Test / test (push) Has been cancelled
Podcasts stöbern: Volltextsuche (FTS5), ähnliche Folgen, Personen, Themen, Vergessenes, Personen anderswo (Apple/fyyd), Empfehlungen (fyyd); Abo-Favoriten
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-19 18:50:35 +02:00

27 lines
665 B
Python

# The full-text index for Stöbern (podcasts/discover.py): SQLite FTS5, contentless.
from django.db import migrations
from podcasts.discover import CREATE_SQL, DROP_SQL
def create(apps, schema_editor):
if schema_editor.connection.vendor != 'sqlite':
return
for sql in CREATE_SQL:
schema_editor.execute(sql)
def drop(apps, schema_editor):
if schema_editor.connection.vendor != 'sqlite':
return
for sql in DROP_SQL:
schema_editor.execute(sql)
class Migration(migrations.Migration):
dependencies = [
('podcasts', '0022_lists_and_levels'),
]
operations = [migrations.RunPython(create, drop)]