Improve logic and add working "delete" links
This commit is contained in:
@ -22,19 +22,3 @@
|
||||
</.link>
|
||||
</:action>
|
||||
</.table>
|
||||
|
||||
<.modal
|
||||
:if={@live_action in [:new, :edit]}
|
||||
id="translation-modal"
|
||||
show
|
||||
on_cancel={JS.navigate(~p"/translations")}
|
||||
>
|
||||
<.live_component
|
||||
module={OutlookWeb.TranslationLive.FormComponent}
|
||||
id={@translation.id || :new}
|
||||
title={@page_title}
|
||||
action={@live_action}
|
||||
translation={@translation}
|
||||
navigate={~p"/translations"}
|
||||
/>
|
||||
</.modal>
|
||||
|
||||
@ -22,4 +22,4 @@
|
||||
<.render_doc tree={InternalTree.render_translation(@translation.article.content, @translation.content)} />
|
||||
</div>
|
||||
|
||||
<.back navigate={~p"/translations"}>Back to translations</.back>
|
||||
<.back navigate={~p"/articles/#{@translation.article}"}>Back to <article></article></.back>
|
||||
|
||||
Reference in New Issue
Block a user