diff options
author | Eric Helgeson <erichelgeson@gmail.com> | 2009-07-21 09:20:47 -0500 |
---|---|---|
committer | Eric Helgeson <erichelgeson@gmail.com> | 2009-07-21 09:20:47 -0500 |
commit | db19d61e68fcf8398579c2c4968e73db7f7ed93b (patch) | |
tree | ca64284fb8544823de4a120bca8d45b424fb65b8 /db/laconica_pg.sql | |
parent | c32e494c0c480e30317b0f0a8dcae7103c4ff89e (diff) | |
parent | fbb0df9f5436e956c43ace372f625f08628c000f (diff) |
Merge commit 'origin/0.8.x' into 0.9.x
Diffstat (limited to 'db/laconica_pg.sql')
-rw-r--r-- | db/laconica_pg.sql | 48 |
1 files changed, 36 insertions, 12 deletions
diff --git a/db/laconica_pg.sql b/db/laconica_pg.sql index dae8b8faf..f5d35f985 100644 --- a/db/laconica_pg.sql +++ b/db/laconica_pg.sql @@ -1,3 +1,4 @@ +
/* local and remote users have profiles */
create sequence profile_seq;
@@ -184,7 +185,7 @@ create table token ( create table nonce (
consumer_key varchar(255) not null /* comment 'unique identifier, root URL' */,
- tok char(32) not null /* comment 'identifying value' */,
+ tok char(32) /* comment 'buggy old value, ignored' */,
nonce char(32) null /* comment 'buggy old value, ignored */,
ts integer not null /* comment 'timestamp sent' values are epoch, and only used internally */,
@@ -375,6 +376,20 @@ create table profile_block ( );
+create sequence design_seq;
+create table design (
+ id bigint default nextval('design_seq') /* comment 'design ID'*/,
+ backgroundcolor integer /* comment 'main background color'*/ ,
+ contentcolor integer /*comment 'content area background color'*/ ,
+ sidebarcolor integer /*comment 'sidebar background color'*/ ,
+ textcolor integer /*comment 'text color'*/ ,
+ linkcolor integer /*comment 'link color'*/,
+ backgroundimage varchar(255) /*comment 'background image, if any'*/,
+ disposition int default 1 /*comment 'bit 1 = hide background image, bit 2 = display background image, bit 4 = tile background image'*/,
+ primary key (id)
+);
+
+
create sequence user_group_seq;
create table user_group (
@@ -390,6 +405,8 @@ create table user_group ( homepage_logo varchar(255) /* comment 'homepage (profile) size logo' */,
stream_logo varchar(255) /* comment 'stream-sized logo' */,
mini_logo varchar(255) /* comment 'mini logo' */,
+ design_id integer /*comment 'id of a design' */ references design(id),
+
created timestamp not null default CURRENT_TIMESTAMP /* comment 'date this record was created' */,
modified timestamp /* comment 'date this record was modified' */
@@ -486,18 +503,25 @@ create table file_to_post ( unique(file_id, post_id)
);
-create sequence design_seq;
-create table design (
- id bigint default nextval('design_seq') /* comment 'design ID'*/,
- backgroundcolor integer /* comment 'main background color'*/ ,
- contentcolor integer /*comment 'content area background color'*/ ,
- sidebarcolor integer /*comment 'sidebar background color'*/ ,
- textcolor integer /*comment 'text color'*/ ,
- linkcolor integer /*comment 'link color'*/,
- backgroundimage varchar(255) /*comment 'background image, if any'*/,
- disposition int default 1 /*comment 'bit 1 = hide background image, bit 2 = display background image, bit 4 = tile background image'*/,
- primary key (id)
+create table group_block (
+ group_id integer not null /* comment 'group profile is blocked from' */ references user_group (id),
+ blocked integer not null /* comment 'profile that is blocked' */references profile (id),
+ blocker integer not null /* comment 'user making the block'*/ references "user" (id),
+ modified timestamp /* comment 'date of blocking'*/ ,
+
+ primary key (group_id, blocked)
+);
+
+create table group_alias (
+
+ alias varchar(64) /* comment 'additional nickname for the group'*/ ,
+ group_id integer not null /* comment 'group profile is blocked from'*/ references user_group (id),
+ modified timestamp /* comment 'date alias was created'*/,
+ primary key (alias)
+
);
+create index group_alias_group_id_idx on group_alias (group_id);
+
/* Textsearch stuff */
|