# Generated by Django 4.0.1 on 2022-01-11 22:11

from django.db import migrations


def forwards_func(apps, schema_editor):
    Posts = apps.get_model("posts", "Post")
    # set current published posts to status 'PUBLIC'
    Posts.objects.filter(is_hidden=False).update(status="20")
    # set current hidden posts to status 'ONLY INTERN'
    Posts.objects.filter(is_hidden=True).update(status="15")


class Migration(migrations.Migration):

    dependencies = [
        ('posts', '0003_post_status'),
    ]

    operations = [
        migrations.RunPython(forwards_func),
    ]
