diff schema/gemma.sql @ 5496:8797274e2739 deactivate-users

Added a active column to users.
author Sascha L. Teichmann <sascha.teichmann@intevation.de>
date Tue, 21 Sep 2021 15:31:26 +0200
parents 345515bc4548
children 796196f83678
line wrap: on
line diff
--- a/schema/gemma.sql	Tue Sep 21 12:49:30 2021 +0200
+++ b/schema/gemma.sql	Tue Sep 21 15:31:26 2021 +0200
@@ -385,7 +385,8 @@
         country char(2) NOT NULL REFERENCES countries,
         map_extent box2d NOT NULL,
         email_address varchar NOT NULL,
-        report_reciever boolean NOT NULL DEFAULT false
+        report_reciever boolean NOT NULL DEFAULT false,
+        active boolean NOT NULL DEFAULT true
     )
 ;
 
@@ -500,7 +501,8 @@
             p.country,
             p.map_extent,
             p.email_address,
-            p.report_reciever
+            p.report_reciever,
+            p.active
         FROM internal.user_profiles p
             JOIN pg_roles u ON p.username = u.rolname
             JOIN pg_auth_members a ON u.oid = a.member