# Generated by Django 4.0.5 on 2022-06-27 08:19
from django.core.exceptions import ObjectDoesNotExist
from django.db import migrations

#
# def create_missing_offschedule(apps, schema_editor):
#     # get list of missing subjects
#     eos_model_cls = apps.get_model("meta_prn.endofstudy")
#     offschedule_model_cls = apps.get_model("meta_prn.offschedule")
#     action_type_model_cls = apps.get_model("edc_action_item_actiontype")
#     action_type = action_type_model_cls.objects.get(name="offschedule_action")
#
#     for eos in eos_model_cls.objects.all():
#         try:
#             offschedule_model_cls.objects.get(subject_identifier=eos.subject_identifier)
#         except ObjectDoesNotExist:
#             # create action items model instances
#             action_item_model_cls = apps.get_model("edc_action_item_actionitem")
#             try:
#                 action_item_model_cls.objects.get(subject_identifier=eos.subject_identifier, action_type=action_type)
#             except ObjectDoesNotExist:
#
#
#             # create offschedule model instances
#
#
#
#


class Migration(migrations.Migration):
    dependencies = [
        ("meta_prn", "0029_alter_historicalpregnancynotification_edd_and_more"),
    ]

    operations = []
