You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
501 B

  1. # Generated by Django 3.2.4 on 2021-07-22 13:25
  2. from django.db import migrations
  3. def fill_member_role(apps, schema_editor):
  4. Member = apps.get_model("accounts", "Member")
  5. Member.objects.filter(rw=False).update(role="r")
  6. Member.objects.filter(rw=True).update(role="w")
  7. class Migration(migrations.Migration):
  8. dependencies = [
  9. ("accounts", "0040_auto_20210722_1244"),
  10. ]
  11. operations = [
  12. migrations.RunPython(fill_member_role, migrations.RunPython.noop),
  13. ]