def METHOD_NAME(apps, schema_editor):
    JobLog = apps.get_model("cm", "JobLog")
    CheckLog = apps.get_model("cm", "CheckLog")
    for cl in CheckLog.objects.all():
        if cl.old_job_id:
            try:
                job = JobLog.objects.get(id=cl.old_job_id)
                cl.job = job
                cl.save()
            except JobLog.DoesNotExist:
                pass