actor.toolbar

Cascading Deletes: Deleting rows from this table will cascade to: actor.org_unit, actor.usr, actor.workstation.

Columns

Column Type Nullable Default Notes

id PK

bigint

No

nextval('actor.toolbar_id_seq'::regclass)

ws FK

integer

Yes

actor.workstation(id)

org FK

integer

Yes

actor.org_unit(id)

usr FK

integer

Yes

actor.usr(id)

label

text

No

layout

text

No

Primary Key

(id)

Foreign Keys

Column(s) References On Delete On Update Deferrable Constraint

org

actor.org_unit(id)

CASCADE

NO ACTION

No

toolbar_org_fkey

usr

actor.usr(id)

CASCADE

NO ACTION

No

toolbar_usr_fkey

ws

actor.workstation(id)

CASCADE

NO ACTION

No

toolbar_ws_fkey

Check Constraints

  • layout_must_be_json: CHECK (is_json(layout))

  • only_one_type: CHECK ((ws IS NOT NULL) AND (COALESCE(org, usr) IS NULL OR org IS NOT NULL) AND (COALESCE(ws, usr) IS NULL OR usr IS NOT NULL) AND (COALESCE(org, ws) IS NULL))

Indexes

Index Method Definition

toolbar_pkey PK

btree

CREATE UNIQUE INDEX toolbar_pkey ON actor.toolbar USING btree (id)

label_once_per_org UNIQUE

btree

CREATE UNIQUE INDEX label_once_per_org ON actor.toolbar USING btree (org, label) WHERE (org IS NOT NULL)

label_once_per_usr UNIQUE

btree

CREATE UNIQUE INDEX label_once_per_usr ON actor.toolbar USING btree (usr, label) WHERE (usr IS NOT NULL)

label_once_per_ws UNIQUE

btree

CREATE UNIQUE INDEX label_once_per_ws ON actor.toolbar USING btree (ws, label) WHERE (ws IS NOT NULL)