spine-framework 0.3.45 → 0.3.47
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -404,3 +404,19 @@ CREATE TABLE public.account_paths (
|
|
|
404
404
|
);
|
|
405
405
|
|
|
406
406
|
COMMENT ON TABLE public.account_paths IS 'Stores ancestor-descendant relationships for account hierarchy traversal';
|
|
407
|
+
|
|
408
|
+
-- ============================================
|
|
409
|
+
-- ROLE GRANTS
|
|
410
|
+
-- ============================================
|
|
411
|
+
|
|
412
|
+
GRANT USAGE ON SCHEMA public TO anon, authenticated, service_role;
|
|
413
|
+
GRANT ALL ON ALL TABLES IN SCHEMA public TO service_role;
|
|
414
|
+
GRANT ALL ON ALL SEQUENCES IN SCHEMA public TO service_role;
|
|
415
|
+
GRANT ALL ON ALL FUNCTIONS IN SCHEMA public TO service_role;
|
|
416
|
+
GRANT SELECT, INSERT, UPDATE, DELETE ON ALL TABLES IN SCHEMA public TO authenticated;
|
|
417
|
+
GRANT SELECT ON ALL TABLES IN SCHEMA public TO anon;
|
|
418
|
+
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT ALL ON TABLES TO service_role;
|
|
419
|
+
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT, INSERT, UPDATE, DELETE ON TABLES TO authenticated;
|
|
420
|
+
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT ON TABLES TO anon;
|
|
421
|
+
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT ALL ON SEQUENCES TO service_role, authenticated;
|
|
422
|
+
ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT ALL ON FUNCTIONS TO service_role, authenticated;
|
|
@@ -41,7 +41,7 @@ BEGIN
|
|
|
41
41
|
-- Look up internal person ID from auth_uid
|
|
42
42
|
SELECT p.id INTO v_person_id
|
|
43
43
|
FROM public.people p
|
|
44
|
-
WHERE p.auth_uid = v_auth_id
|
|
44
|
+
WHERE p.auth_uid = v_auth_id AND p.is_active = true
|
|
45
45
|
LIMIT 1;
|
|
46
46
|
|
|
47
47
|
RETURN v_person_id;
|