Fix sites link in HelpScout CRM integration (#4909)

* Fix sites link in HelpScout CRM integration

* Update tests
This commit is contained in:
Adrian Gruntkowski 2024-12-16 15:41:19 +01:00 committed by GitHub
parent 8b6f317d1d
commit 8de2b49376
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 4 additions and 4 deletions

View File

@ -106,7 +106,7 @@ defmodule Plausible.HelpScout do
sites_count: Plausible.Teams.owned_sites_count(team),
sites_link:
Routes.kaffy_resource_url(PlausibleWeb.Endpoint, :index, :sites, :site,
search: user.email
custom_search: user.email
)
}}
end

View File

@ -61,7 +61,7 @@ defmodule Plausible.HelpScoutTest do
crm_url = "#{PlausibleWeb.Endpoint.url()}/crm/auth/user/#{user_id}"
owned_sites_url =
"#{PlausibleWeb.Endpoint.url()}/crm/sites/site?search=#{URI.encode_www_form(email)}"
"#{PlausibleWeb.Endpoint.url()}/crm/sites/site?custom_search=#{URI.encode_www_form(email)}"
assert {:ok,
%{
@ -410,7 +410,7 @@ defmodule Plausible.HelpScoutTest do
crm_url = "#{PlausibleWeb.Endpoint.url()}/crm/auth/user/#{user_id}"
owned_sites_url =
"#{PlausibleWeb.Endpoint.url()}/crm/sites/site?search=#{URI.encode_www_form(email)}"
"#{PlausibleWeb.Endpoint.url()}/crm/sites/site?custom_search=#{URI.encode_www_form(email)}"
assert {:ok,
%{
@ -448,7 +448,7 @@ defmodule Plausible.HelpScoutTest do
crm_url = "#{PlausibleWeb.Endpoint.url()}/crm/auth/user/#{user2.id}"
owned_sites_url =
"#{PlausibleWeb.Endpoint.url()}/crm/sites/site?search=#{URI.encode_www_form(user2.email)}"
"#{PlausibleWeb.Endpoint.url()}/crm/sites/site?custom_search=#{URI.encode_www_form(user2.email)}"
assert {:ok,
%{