Merge branch 'main' into feat/421_accessibility
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
This commit is contained in:
commit
73382c2c3f
49 changed files with 3415 additions and 1950 deletions
|
|
@ -82,7 +82,7 @@ defmodule MvWeb.MembershipFeeSettingsLive do
|
|||
{:noreply,
|
||||
socket
|
||||
|> assign(:settings, updated_settings)
|
||||
|> put_flash(:info, gettext("Settings saved successfully."))
|
||||
|> put_flash(:success, gettext("Settings saved successfully."))
|
||||
|> assign_form()}
|
||||
|
||||
{:error, form} ->
|
||||
|
|
@ -105,7 +105,7 @@ defmodule MvWeb.MembershipFeeSettingsLive do
|
|||
socket
|
||||
|> assign(:membership_fee_types, updated_types)
|
||||
|> assign(:member_counts, updated_counts)
|
||||
|> put_flash(:info, gettext("Membership fee type deleted"))}
|
||||
|> put_flash(:success, gettext("Membership fee type deleted"))}
|
||||
|
||||
{:error, %Ash.Error.Forbidden{}} ->
|
||||
{:noreply,
|
||||
|
|
@ -239,10 +239,10 @@ defmodule MvWeb.MembershipFeeSettingsLive do
|
|||
|
||||
<div class="divider"></div>
|
||||
|
||||
<button type="submit" class="btn btn-primary w-full">
|
||||
<.button type="submit" variant="primary" class="w-full">
|
||||
<.icon name="hero-check" class="size-5" />
|
||||
{gettext("Save Settings")}
|
||||
</button>
|
||||
</.button>
|
||||
</.form>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -333,24 +333,27 @@ defmodule MvWeb.MembershipFeeSettingsLive do
|
|||
</:col>
|
||||
|
||||
<:action :let={mft}>
|
||||
<.link
|
||||
navigate={~p"/membership_fee_settings/#{mft.id}/edit_fee_type"}
|
||||
class="btn btn-ghost btn-xs"
|
||||
aria-label={gettext("Edit membership fee type")}
|
||||
>
|
||||
<.icon name="hero-pencil" class="size-4" />
|
||||
</.link>
|
||||
<.tooltip content={gettext("Edit membership fee type")} position="left">
|
||||
<.button
|
||||
variant="ghost"
|
||||
size="sm"
|
||||
navigate={~p"/membership_fee_settings/#{mft.id}/edit_fee_type"}
|
||||
aria-label={gettext("Edit membership fee type")}
|
||||
>
|
||||
<.icon name="hero-pencil" class="size-4" />
|
||||
</.button>
|
||||
</.tooltip>
|
||||
</:action>
|
||||
|
||||
<:action :let={mft}>
|
||||
<div
|
||||
<.tooltip
|
||||
:if={get_member_count(mft, @member_counts) > 0}
|
||||
class="tooltip tooltip-left"
|
||||
data-tip={
|
||||
content={
|
||||
gettext("Cannot delete - %{count} member(s) assigned",
|
||||
count: get_member_count(mft, @member_counts)
|
||||
)
|
||||
}
|
||||
position="left"
|
||||
>
|
||||
<button
|
||||
phx-click="delete"
|
||||
|
|
@ -366,17 +369,18 @@ defmodule MvWeb.MembershipFeeSettingsLive do
|
|||
>
|
||||
<.icon name="hero-trash" class="size-4" />
|
||||
</button>
|
||||
</div>
|
||||
<button
|
||||
</.tooltip>
|
||||
<.button
|
||||
:if={get_member_count(mft, @member_counts) == 0}
|
||||
variant="danger"
|
||||
size="sm"
|
||||
phx-click="delete"
|
||||
phx-value-id={mft.id}
|
||||
data-confirm={gettext("Are you sure?")}
|
||||
class="btn btn-ghost btn-xs text-error"
|
||||
aria-label={gettext("Delete Membership Fee Type")}
|
||||
>
|
||||
<.icon name="hero-trash" class="size-4" />
|
||||
</button>
|
||||
</.button>
|
||||
</:action>
|
||||
</.table>
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue