From 3994d77a78e3d6ef9e91bb77829c3b51eb1fe9ab Mon Sep 17 00:00:00 2001 From: jordi fita mas Date: Fri, 4 Aug 2023 19:50:27 +0200 Subject: [PATCH] =?UTF-8?q?Remove=20campsite=5Ftype=E2=80=99s=20booking=5F?= =?UTF-8?q?terms=20and=20rules?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We are no longer going to “stitch up” a whole page based on ACF-like field, but write the whole page with that information in description. That change is due to wanting to serve the public-facing part of the web with the same application. --- deploy/campsite_type.sql | 2 -- test/campsite_type.sql | 14 +------------- verify/campsite_type.sql | 2 -- 3 files changed, 1 insertion(+), 17 deletions(-) diff --git a/deploy/campsite_type.sql b/deploy/campsite_type.sql index 58316fd..53a69c4 100644 --- a/deploy/campsite_type.sql +++ b/deploy/campsite_type.sql @@ -13,8 +13,6 @@ create table campsite_type ( slug uuid not null unique default gen_random_uuid(), name text not null constraint name_not_empty check(length(trim(name)) > 0), description xml not null default ''::xml, - rules xml not null default '', - booking_terms xml not null default '', active boolean not null default true ); diff --git a/test/campsite_type.sql b/test/campsite_type.sql index 0e3ec9e..1a71dea 100644 --- a/test/campsite_type.sql +++ b/test/campsite_type.sql @@ -5,7 +5,7 @@ reset client_min_messages; begin; -select plan(55); +select plan(47); set search_path to camper, public; @@ -54,18 +54,6 @@ select col_not_null('campsite_type', 'description'); select col_has_default('campsite_type', 'description'); --select col_default_is('campsite_type', 'description', ''); -select has_column('campsite_type', 'rules'); -select col_type_is('campsite_type', 'rules', 'xml'); -select col_not_null('campsite_type', 'rules'); -select col_has_default('campsite_type', 'rules'); ---select col_default_is('campsite_type', 'rules', ''); - -select has_column('campsite_type', 'booking_terms'); -select col_type_is('campsite_type', 'booking_terms', 'xml'); -select col_not_null('campsite_type', 'booking_terms'); -select col_has_default('campsite_type', 'booking_terms'); ---select col_default_is('campsite_type', 'booking_terms', ''); - select has_column('campsite_type', 'active'); select col_type_is('campsite_type', 'active', 'boolean'); select col_not_null('campsite_type', 'active'); diff --git a/verify/campsite_type.sql b/verify/campsite_type.sql index 42e8195..6eaba0d 100644 --- a/verify/campsite_type.sql +++ b/verify/campsite_type.sql @@ -7,8 +7,6 @@ select campsite_type_id , slug , name , description - , rules - , booking_terms , active from camper.campsite_type where false;