datatracker/ietf/name/migrations/0014_change_legacy_stream_desc.py
Rich Salz 8a5826a941
fix: redundant word in banner for Legacy stream documents (#7207)
* fix: Remove redundant "stream stream" output

fix: Change "Legacy stream" to "Legacy"

chore: Add "stream" to stream.desc as needed

Fixes: #6902

* chore: Remove unused stream_desc parameter

The stream_desc key isn't used in template/doc/docuemnt_draft.html to
don't pass it in nor compute it

Fixes: #6902

* fix: migrate the legacy StreamName

---------

Co-authored-by: Robert Sparks <rjsparks@nostrum.com>
2024-08-05 09:48:48 -05:00

22 lines
586 B
Python

# Copyright The IETF Trust 2024, All Rights Reserved
from django.db import migrations
def forward(apps, schema_editor):
StreamName = apps.get_model("name", "StreamName")
StreamName.objects.filter(pk="legacy").update(desc="Legacy")
def reverse(apps, schema_editor):
StreamName = apps.get_model("name", "StreamName")
StreamName.objects.filter(pk="legacy").update(desc="Legacy stream")
class Migration(migrations.Migration):
dependencies = [
("name", "0013_narrativeminutes"),
]
operations = [
migrations.RunPython(forward, reverse)
]