This commit is contained in:
parent
f12da8a359
commit
349cee0ce6
19 changed files with 300 additions and 100 deletions
|
|
@ -48,15 +48,8 @@ defmodule MvWeb.JoinConfirmController do
|
|||
end
|
||||
|
||||
defp assign_confirm_assigns(conn, result) do
|
||||
club_name =
|
||||
case Mv.Membership.get_settings() do
|
||||
{:ok, settings} -> settings.club_name || "Mitgliederverwaltung"
|
||||
_ -> "Mitgliederverwaltung"
|
||||
end
|
||||
|
||||
conn
|
||||
|> assign(:result, result)
|
||||
|> assign(:club_name, club_name)
|
||||
|> assign(:csrf_token, Plug.CSRFProtection.get_csrf_token())
|
||||
|> assign(:flash, conn.assigns[:flash] || conn.flash || %{})
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -1,24 +1,4 @@
|
|||
<%!-- Public header (same structure as Layouts.app unauthenticated branch) --%>
|
||||
<header class="flex items-center gap-3 p-4 border-b border-base-300 bg-base-100">
|
||||
<img src={~p"/images/mila.svg"} alt="Mila Logo" class="size-8 shrink-0" />
|
||||
<span class="menu-label text-lg font-bold truncate flex-1">
|
||||
{@club_name}
|
||||
</span>
|
||||
<form method="post" action={~p"/set_locale"} class="shrink-0">
|
||||
<input type="hidden" name="_csrf_token" value={@csrf_token} />
|
||||
<select
|
||||
name="locale"
|
||||
onchange="this.form.submit()"
|
||||
class="select select-sm focus:outline-none focus:ring-2 focus:ring-primary focus:ring-offset-2"
|
||||
aria-label={gettext("Select language")}
|
||||
>
|
||||
<option value="de" selected={Gettext.get_locale() == "de"}>Deutsch</option>
|
||||
<option value="en" selected={Gettext.get_locale() == "en"}>English</option>
|
||||
</select>
|
||||
</form>
|
||||
</header>
|
||||
|
||||
<main class="px-4 py-8 sm:px-6">
|
||||
<Layouts.public_page flash={@flash}>
|
||||
<div class="max-w-4xl mx-auto">
|
||||
<div class="hero min-h-[60vh] bg-base-200 rounded-lg">
|
||||
<div class="hero-content flex-col items-start text-left">
|
||||
|
|
@ -62,4 +42,4 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
</Layouts.public_page>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue