Administration
<.link :if={@map_subscriptions_enabled?} phx-click="authorize"> <.icon name="hero-key-solid" class="w-6 h-6 text-gray-500 hover:text-gray-800 dark:text-gray-400 dark:hover:text-gray-100" />
Maps Management
<.link class="btn mt-2 w-full btn-neutral rounded-none" navigate={~p"/admin/maps"}>
<.icon name="hero-map-solid" class="w-6 h-6" />
Manage All Maps
Characters
<.link
class="btn mt-2 w-full btn-neutral rounded-none"
navigate={~p"/admin/characters"}
>
<.icon name="hero-users-solid" class="w-6 h-6" />
View All Characters
<.button class="mt-2" type="button" phx-click="create-map">
Create Map
Wanderer Balance
{@total_balance |> Number.to_human(units: ["", "K", "M", "B", "T", "P"])} ISK
Update User Balance
<.form :let={f} for={@form} phx-change="check-amount" phx-submit="update-balance">
<.live_select
field={f[:character_id]}
dropdown_extra_class="max-h-64 overflow-y-auto flex flex-row"
available_option_class="w-full"
debounce={250}
update_min_len={3}
options={@character_search_options}
placeholder="Search a character"
>
<:option :let={option}>
<.search_member_item option={option} />
<.live_select
field={f[:amount]}
update_min_len={0}
options={@amounts}
placeholder="Amount"
/>
<.button class="mt-2" type="submit">
Update Balance
Unlink Character
<.form :let={f} for={@unlink_character_form} phx-submit="unlink-character">
<.live_select
field={f[:unlink_character_id]}
dropdown_extra_class="max-h-64 overflow-y-auto flex flex-row"
available_option_class="w-full"
debounce={250}
update_min_len={3}
options={@character_search_options}
placeholder="Search a character"
>
<:option :let={option}>
<.search_member_item option={option} />
<.button class="mt-2" type="submit">
Unlink
EVE DB Data
<.button
class="mt-2"
type="button"
phx-click="update-eve-db-data"
phx-disable-with="Updating EVE DB Data..."
>
Update EVE DB Data
Invites
<.link class="btn mt-2 w-full btn-neutral rounded-none" patch={~p"/admin/invite"}>
<.icon name="hero-plus-solid" class="w-6 h-6" />
<.table id="invites" rows={@invites} class="!max-h-[40vh] !overflow-y-auto">
<:col :let={invite} label="Link">
<:col :let={invite} label="Type">
{invite.type}
<:col :let={invite} label="Valid Until">
<:action :let={invite}>
<.button
phx-click="delete-invite"
phx-value-id={invite.id}
data={[confirm: "Please confirm to delete invite!"]}
class="hover:text-white"
>
<.icon name="hero-trash-solid" class="w-4 h-4" />
<.link class="btn mt-2 w-full btn-neutral rounded-none" patch={~p"/admin/invite"}>
<.icon name="hero-plus-solid" class="w-6 h-6" />
New Invite
<.table id="invites" rows={@invites} class="!max-h-[40vh] !overflow-y-auto">
<:col :let={invite} label="Link">
{get_invite_link(@uri, invite.token)}
<.button
phx-hook="CopyToClipboard"
id="copy-to-clipboard"
class="copy-link btn btn-neutral rounded-none"
data-url={get_invite_link(@uri, invite.token)}
>
Copy
<.local_time id={invite.id} at={invite.valid_until} />
Tracking Pools
<.table
id="tracking_pools"
rows={@tracker_stats}
class="!max-h-[40vh] !overflow-y-auto"
>
<:col :let={stat} label="Pool">
{stat.title}
<:col :let={stat} label="Active">
true
<:col :let={stat} label="Count">
{stat.value}