diff --git a/.drone.yml b/.drone.yml index b0fb160..7fb6b97 100644 --- a/.drone.yml +++ b/.drone.yml @@ -284,7 +284,7 @@ environment: steps: - name: renovate - image: renovate/renovate:43.165 + image: renovate/renovate:43.163 environment: RENOVATE_CONFIG_FILE: "renovate_backend_config.js" RENOVATE_TOKEN: diff --git a/CHANGELOG.md b/CHANGELOG.md index c17ea39..cd65692 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,22 +7,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] -### Changed -- **Join request display and settings workflow** – Improved join request rendering and related settings behavior in one cohesive update: - - Join request fields now respect their configured field types in the details view. - - Custom field labels in join request views were standardized. - - Join request field formatting was corrected for more consistent output. - - Join link settings now include a direct "Open" action in addition to copy/share workflows. - ### Fixed - **Runtime ENV handling** – Empty or invalid environment variables (e.g. `SMTP_PORT=`, `PORT=`, `POOL_SIZE=`, `DATABASE_PORT=`) no longer cause `ArgumentError` at boot. Instead raises clear errors for required vars set but empty (e.g. DATABASE_HOST, PHX_HOST/DOMAIN, SECRET_KEY_BASE). -- **PostgreSQL 18 Docker volume path** – Corrected the database volume path to match PostgreSQL 18 expectations. - -### Dependency updates -- Mix dependencies were updated. -- Renovate Docker image was updated to `v43.165`. -- Rauthy Docker image was updated to `v0.35.1`. -- `just` was updated to `v1.50.0`. ## [1.1.1] - 2026-03-16 diff --git a/lib/mv/membership/custom_field_lookup.ex b/lib/mv/membership/custom_field_lookup.ex deleted file mode 100644 index 9d9b9f3..0000000 --- a/lib/mv/membership/custom_field_lookup.ex +++ /dev/null @@ -1,56 +0,0 @@ -defmodule Mv.Membership.CustomFieldLookup do - @moduledoc """ - Shared helper for loading custom fields by ID. - """ - - alias Mv.Constants - alias Mv.Membership - - @spec fetch_map_by_ids([String.t()], keyword()) :: map() - def fetch_map_by_ids(field_ids, opts \\ []) when is_list(field_ids) do - member_field_strings = Constants.member_fields() |> Enum.map(&Atom.to_string/1) - - custom_field_ids = - field_ids - |> Enum.uniq() - |> Enum.reject(&(&1 in member_field_strings)) - - if custom_field_ids == [] do - %{} - else - select = Keyword.get(opts, :select, [:id, :name, :value_type]) - - query = - Membership.CustomField - |> Ash.Query.select(select) - - read_opts = - [domain: Membership] - |> maybe_put_actor(opts) - |> maybe_put_authorize(opts) - - case Ash.read(query, read_opts) do - {:ok, fields} -> - allowed_ids = MapSet.new(custom_field_ids) - fields |> Enum.filter(&MapSet.member?(allowed_ids, &1.id)) |> Map.new(&{&1.id, &1}) - - {:error, _} -> - %{} - end - end - end - - defp maybe_put_actor(opts, read_opts) do - case Keyword.fetch(read_opts, :actor) do - {:ok, actor} -> Keyword.put(opts, :actor, actor) - :error -> opts - end - end - - defp maybe_put_authorize(opts, read_opts) do - case Keyword.fetch(read_opts, :authorize?) do - {:ok, authorize?} -> Keyword.put(opts, :authorize?, authorize?) - :error -> opts - end - end -end diff --git a/lib/mv_web/components/layouts.ex b/lib/mv_web/components/layouts.ex index 9aff23c..54f589d 100644 --- a/lib/mv_web/components/layouts.ex +++ b/lib/mv_web/components/layouts.ex @@ -138,7 +138,7 @@ defmodule MvWeb.Layouts do # Single get_settings() for layout; derive club_name and join_form_enabled to avoid duplicate query. %{club_name: club_name, join_form_enabled: join_form_enabled} = get_layout_settings() - # NOTE: Unprocessed count runs on every page load when join form is enabled; consider + # TODO: unprocessed count runs on every page load when join form enabled; consider # loading only on navigation or caching briefly if performance becomes an issue. unprocessed_join_requests_count = get_unprocessed_join_requests_count(assigns.current_user, join_form_enabled) diff --git a/lib/mv_web/live/global_settings_live.ex b/lib/mv_web/live/global_settings_live.ex index 43851db..cb57631 100644 --- a/lib/mv_web/live/global_settings_live.ex +++ b/lib/mv_web/live/global_settings_live.ex @@ -186,16 +186,6 @@ defmodule MvWeb.GlobalSettingsLive do <.icon name="hero-clipboard-document" class="size-4" /> {gettext("Copy")} - <.link - href={@join_url} - target="_blank" - rel="noopener noreferrer" - class="btn btn-secondary btn-sm" - > - <.icon name="hero-arrow-top-right-on-square" class="size-4" aria-hidden="true" /> - {pgettext("action", "Open")} - {gettext("join page URL in a new tab")} - diff --git a/lib/mv_web/live/join_live.ex b/lib/mv_web/live/join_live.ex index ba0e476..3b8db05 100644 --- a/lib/mv_web/live/join_live.ex +++ b/lib/mv_web/live/join_live.ex @@ -5,9 +5,7 @@ defmodule MvWeb.JoinLive do """ use MvWeb, :live_view - alias Ash.Resource.Info alias Mv.Membership - alias Mv.Membership.CustomFieldLookup alias MvWeb.JoinRateLimit alias MvWeb.Translations.MemberFields @@ -56,6 +54,10 @@ defmodule MvWeb.JoinLive do {gettext("Become a member")} +

+ {gettext("Please enter your details for the membership application here.")} +

+ <%= if @submitted do %>

@@ -65,9 +67,6 @@ defmodule MvWeb.JoinLive do

<% else %> -

- {gettext("Please enter your details for the membership application here.")} -

<.form for={@form} id="join-form" @@ -81,41 +80,19 @@ defmodule MvWeb.JoinLive do <% end %> <%= for field <- @join_fields do %> - <%= if field.input_type == "checkbox" do %> - -