{% extends 'core/base.html' %} {% block title %}Import Organization | Killian{% endblock %} {% block content %}

Import Organization

Upload a Killian JSON organization export, review its contents, then confirm the import.

Back

Select JSON File

Only Killian organization export files are supported.
{% csrf_token %}
{% if error %}
Import could not continue.
{{ error }}
{% endif %} {% if preview %}

Import Preview

{% if preview.existing %} Existing organization detected. No changes have been made yet. {% else %} Review the new organization before importing. {% endif %}
Organization
{{ preview.name }}
Short Name
{{ preview.short_name|default:'—' }}
Status
{{ preview.status|default:'Active' }}
Modules
{{ preview.modules }}
Records in Backup
{{ preview.record_count }}
{% if preview.existing %}
Import Mode
Reviewed merge / restore
{% endif %}
{% if preview.existing %}
Existing organization detected: {{ preview.existing_name }}
Killian compared the uploaded backup with the current organization before making any changes. Records shown as Existing Only will be preserved and will not be deleted. Records shown as Added will be created, and Changed records will be updated only after approval below.
{% if preview.comparison.warnings %}
Review warning {% for warning in preview.comparison.warnings %}
{{ warning }}
{% endfor %}
{% endif %}
Added
{{ preview.comparison.added_count }}
Changed
{{ preview.comparison.changed_count }}
Existing Only
{{ preview.comparison.existing_only_count }}
Unchanged
{{ preview.comparison.unchanged_count }}
Show differences Hide differences
{% if preview.comparison.organization_changes %}
Organization-level changes ({{ preview.comparison.organization_change_count }})
{% for change in preview.comparison.organization_changes %} {% endfor %}
Field Current Backup
{{ change.field }} {{ change.current }} {{ change.backup }}
{% endif %} {% if preview.comparison.changed %}
Changed records ({{ preview.comparison.changed_count }})
{% for record in preview.comparison.changed %}
{{ record.model_label }} — {{ record.title }}
Source ID: {{ record.source_pk }}
{% for change in record.changes %} {% endfor %}
Field Current Backup
{{ change.field }} {{ change.current }} {{ change.backup }}
{% endfor %}
{% endif %} {% if preview.comparison.added %}
Added records ({{ preview.comparison.added_count }})
{% for record in preview.comparison.added %}
{{ record.model_label }} — {{ record.title }} (Source ID: {{ record.source_pk }})
{% endfor %}
{% endif %} {% if preview.comparison.existing_only %}
Existing Only — preserved ({{ preview.comparison.existing_only_count }})
These records exist in Killian but are absent from the uploaded backup. They will not be deleted or modified by their absence.
{% for record in preview.comparison.existing_only %}
{{ record.model_label }} — {{ record.title }} (Source ID: {{ record.source_pk }})
{% endfor %}
{% endif %} {% if not preview.comparison.has_changes %}
No differences were detected between the backup and the live organization. All {{ preview.comparison.unchanged_count }} matching record(s) are unchanged.
{% endif %}
{% csrf_token %} Cancel
{% else %}
No existing organization with this name was found. Confirming will create a new organization and import its records.
{% csrf_token %} Cancel
{% endif %}
{% endif %} {% endblock %}