def add_keys(apps, schema_editor):
    """
    We can't import the Post model directly as it may be a newer
    version than this migration expects. We use the historical version.
    """
    Setting = apps.get_model('settings', 'Setting')
    key = ''
    try:
        key = 'BANK_MELLI_MERCHENT_CODE'
        Setting.objects.get(key=key)
    except Exception:
        Setting.objects.create(title='مرچنت کد بانک ملی', key=key, value='',
            value_type='s', is_show=False, is_variable_in_home=False)
    try:
        key = 'BANK_MELLI_TERMINAL_CODE'
        Setting.objects.get(key=key)
    except Exception:
        Setting.objects.create(title='ترمینال کد بانک ملی', key=key, value=
            '', value_type='s', is_show=False, is_variable_in_home=False)
    try:
        key = 'BANK_MELLI_SECRET_KEY'
        Setting.objects.get(key=key)
    except Exception:
        Setting.objects.create(title=' کلید خصوصی بانک ملی', key=key, value
            ='', value_type='s', is_show=False, is_variable_in_home=False)
