{% extends "allianceauth/base-bs5.html" %} {% block page_title %}Alt Corps{% endblock %} {% block content %}
{% include "aa_altcorp/_page_header.html" with title="Alt corporations" subtitle="Find a character, review its account, and manage corporation relationships." active_tab="corporations" %} {% if configuration_missing %}{% endif %}

1. Find the character and corporation

Both fields are part of the same search. The character result tells you which main account will receive the corporation.

{% if request.GET.character or request.GET.corporation %}

Character results

{% if characters %}
{% for result in characters %}
{{ result.character.character_name }}Auth account: {{ result.user.username }}{{ result.status }}{% if perms.aa_altcorp.manage_relationships %}
{% csrf_token %}
{% endif %}
{% endfor %}
{% elif request.GET.character %}

No character found with that name.

{% else %}

Enter a character name to find its account.

{% endif %}

Corporation results

{% if corporations %}
{% for corporation in corporations %}
{{ corporation.corporation_name }} ({{ corporation.corporation_id }})
{% endfor %}
{% elif request.GET.corporation %}

No corporation Alliance Auth knows about matches that name. Only corporations with a linked character are searchable.

{% else %}

Enter a corporation name to find it.

{% endif %}
{% if characters and corporations and perms.aa_altcorp.manage_relationships %}

2. Attach corporation to this account

{% csrf_token %}
{% endif %}{% endif %}

Attached corporations

{% for relationship in relationships %}
{{ relationship.main_character_name }} — {{ relationship.corporation_name }}{% if relationship.review %}{{ relationship.review.reason }}{% endif %}
{% if perms.aa_altcorp.manage_relationships %}
{% csrf_token %}
{% endif %}
{% empty %}
No relationships attached.
{% endfor %}
{% endblock %}