old_contents: # -*- coding: utf-8 -*-
  # Generated by Django 1.11.15 on 2019-04-17 19:51
  from __future__ import unicode_literals
  
  import os
  import uuid
  import django.contrib.postgres.fields.jsonb
  from django.db import migrations, models
  from django.core import management
  from arches.app.models.system_settings import settings
  
  
  def forwards_func(apps, schema_editor):
      for root, dirs, files in os.walk(os.path.join(settings.ROOT_DIR, 'app', 'search', 'components')):
          for file in files:
              filename, file_extension = os.path.splitext(file)
              if file_extension == '.py':
                  management.call_command('search', 'register', source=os.path.join(root, file))
  
  def reverse_func(apps, schema_editor):
      pass
  
  class Migration(migrations.Migration):
  
      dependencies = [
          ('models', '4375_add_unique_constraint_models'),
      ]
  
      operations = [
          migrations.CreateModel(
              name='SearchComponent',
              fields=[
                  ('searchcomponentid', models.UUIDField(default=uuid.uuid1, primary_key=True, serialize=False)),
                  ('name', models.TextField()),
                  ('icon', models.TextField(default=None)),
                  ('modulename', models.TextField(blank=True, null=True)),
                  ('classname', models.TextField(blank=True, null=True)),
                  ('type', models.TextField()),
                  ('componentpath', models.TextField(unique=True)),
                  ('componentname', models.TextField(unique=True)),
                  ('sortorder', models.IntegerField(blank=True, default=None, null=True)),
                  ('enabled', models.BooleanField(default=False)),
              ],
              options={
                  'db_table': 'search_component',
                  'managed': True,
              },
          ),
          migrations.RunPython(forwards_func, reverse_func)
      ]
  
new_contents: # -*- coding: utf-8 -*-
  # Generated by Django 1.11.15 on 2019-04-17 19:51
  from __future__ import unicode_literals
  
  import os
  import uuid
  import django.contrib.postgres.fields.jsonb
  from django.db import migrations, models
  from django.core import management
  from arches.app.models.system_settings import settings
  
  
  def forwards_func(apps, schema_editor):
      for root, dirs, files in os.walk(os.path.join(settings.ROOT_DIR, 'app', 'search', 'components')):
          for file in files:
              filename, file_extension = os.path.splitext(file)
              if file_extension == '.py':
                  management.call_command('search', 'register', source=os.path.join(root, file))
  
  def reverse_func(apps, schema_editor):
      pass
  
  class Migration(migrations.Migration):
  
      dependencies = [
          ('models', '4684_updates_tabbed_report_configs'),
      ]
  
      operations = [
          migrations.CreateModel(
              name='SearchComponent',
              fields=[
                  ('searchcomponentid', models.UUIDField(default=uuid.uuid1, primary_key=True, serialize=False)),
                  ('name', models.TextField()),
                  ('icon', models.TextField(default=None)),
                  ('modulename', models.TextField(blank=True, null=True)),
                  ('classname', models.TextField(blank=True, null=True)),
                  ('type', models.TextField()),
                  ('componentpath', models.TextField(unique=True)),
                  ('componentname', models.TextField(unique=True)),
                  ('sortorder', models.IntegerField(blank=True, default=None, null=True)),
                  ('enabled', models.BooleanField(default=False)),
              ],
              options={
                  'db_table': 'search_component',
                  'managed': True,
              },
          ),
          migrations.RunPython(forwards_func, reverse_func)
      ]
  
subject: fix migration issue after merge with master, re #4771