Rename external URLs and move profile fields

Rename the compliance external URL concept to compliance custom links,
and move the public-facing profile fields (description, website, email,
headquarter address) off the organization onto the trust center. Backfill
managed default domains for pages that lack them.

Signed-off-by: Bryan Frimin <bryan@probo.com>
This commit is contained in:
Bryan Frimin
2026-07-10 15:11:40 +02:00
parent b524e9b497
commit 55a8e72c17
9 changed files with 239 additions and 215 deletions

View File

@@ -0,0 +1,34 @@
-- Copyright (c) 2026 Probo Inc <hello@probo.com>.
--
-- Permission to use, copy, modify, and/or distribute this software for any
-- purpose with or without fee is hereby granted, provided that the above
-- copyright notice and this permission notice appear in all copies.
--
-- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
-- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
-- AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
-- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
-- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
-- OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
-- PERFORMANCE OF THIS SOFTWARE.
ALTER TABLE trust_centers
ADD COLUMN description TEXT,
ADD COLUMN website_url TEXT,
ADD COLUMN email CITEXT,
ADD COLUMN headquarter_address TEXT;
UPDATE trust_centers tc
SET
description = o.description,
website_url = o.website_url,
email = o.email,
headquarter_address = o.headquarter_address
FROM organizations o
WHERE tc.organization_id = o.id;
ALTER TABLE organizations
DROP COLUMN description,
DROP COLUMN website_url,
DROP COLUMN email,
DROP COLUMN headquarter_address;