27 lines
671 B
Elixir
27 lines
671 B
Elixir
|
defmodule ComfycampWeb.OIDCRedirectURIHTML do
|
|||
|
use ComfycampWeb, :html
|
|||
|
|
|||
|
def new(assigns) do
|
|||
|
~H"""
|
|||
|
<div>
|
|||
|
<.header>Новый redirect URI</.header>
|
|||
|
<.uri_form changeset={@changeset} action={~p"/admin/oidc_apps/#{@oidc_app}/redirect_uris"} />
|
|||
|
</div>
|
|||
|
"""
|
|||
|
end
|
|||
|
|
|||
|
def uri_form(assigns) do
|
|||
|
~H"""
|
|||
|
<.simple_form :let={f} for={@changeset} action={@action}>
|
|||
|
<.error :if={@changeset.action}>
|
|||
|
Что-то пошло не так
|
|||
|
</.error>
|
|||
|
<.input field={f[:uri]} type="url" label="Redirect URI" />
|
|||
|
<:actions>
|
|||
|
<.button>Сохранить</.button>
|
|||
|
</:actions>
|
|||
|
</.simple_form>
|
|||
|
"""
|
|||
|
end
|
|||
|
end
|