
-- drop public.page

DROP TABLE IF EXISTS public.page;
DROP SEQUENCE IF EXISTS public.page_id_seq;

-- public.page

CREATE SEQUENCE IF NOT EXISTS public.page_id_seq;

ALTER SEQUENCE public.page_id_seq
    OWNER TO postgres;

CREATE TABLE IF NOT EXISTS public.page
(
    id integer NOT NULL DEFAULT nextval('page_id_seq'::regclass),
    tag character varying(32) COLLATE pg_catalog."default" NOT NULL,
    name character varying(64) COLLATE pg_catalog."default" NOT NULL,
	status integer NOT NULL DEFAULT '-1'::integer,
    label jsonb NOT NULL DEFAULT '{}'::jsonb,
    context jsonb NOT NULL DEFAULT '{}'::jsonb,
    description character varying(512) COLLATE pg_catalog."default" NOT NULL DEFAULT ''::character varying,
    op integer NOT NULL DEFAULT '-1'::integer,
    ts timestamp with time zone NOT NULL DEFAULT CURRENT_TIMESTAMP,
    CONSTRAINT page_id_PrimaryKey PRIMARY KEY (id)
)
TABLESPACE pg_default;

ALTER TABLE IF EXISTS public.page
    OWNER to postgres;

