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.

24 lines
476 B

  1. # Generated by Django 2.1.4 on 2019-01-04 09:08
  2. from django.db import migrations
  3. def fill_ping_kind(apps, schema_editor):
  4. Ping = apps.get_model('api', 'Ping')
  5. q = Ping.objects.filter(start=True)
  6. q.update(kind="start")
  7. q = Ping.objects.filter(fail=True)
  8. q.update(kind="fail")
  9. class Migration(migrations.Migration):
  10. dependencies = [
  11. ('api', '0050_ping_kind'),
  12. ]
  13. operations = [
  14. migrations.RunPython(fill_ping_kind),
  15. ]