aboutsummaryrefslogtreecommitdiffstats
path: root/install
diff options
context:
space:
mode:
authorplegall <plg@piwigo.org>2004-11-13 13:43:53 +0000
committerplegall <plg@piwigo.org>2004-11-13 13:43:53 +0000
commit88e4e1e60adf660651f9276ab2b19bffcc72d9d3 (patch)
treec5ee67d2ba4ee38b2864cf136787d187d12a2c07 /install
parent234b7463520902a62e0c3e4e35c00a9e27f14278 (diff)
- admin/cat_options page added : manage options for the whole categories
tree (uploadable, commentable). status and visible will be soon added - admin.php : $conf_link var to avoid lines longer than 79 characters - config.upload_available configuration parameter disappear : it's simpler to manage with cat_options - config.show_comments idem : new column categories.commentable, each categories can be commentable or not - categories.site_id becomes a nullable column : a virtual category does belong to no site - function display_select_categories has a new argument : $CSS_classes array to optionnaly assign a CSS class to each category in the select field - added informations in include/config.inc.php for setting default value of : - categories.visible - categories.status - categories.uploadable - categories.commentable - 2 new indexes images_i3(average_rate) and images_i4(hit) : optimizes best rated and most visited categories git-svn-id: http://piwigo.org/svn/trunk@602 68402e56-0260-453c-a942-63ccdbb3a9ee
Diffstat (limited to 'install')
-rw-r--r--install/config.sql2
-rw-r--r--install/dbscheme.txt8
-rw-r--r--install/phpwebgallery_structure.sql9
3 files changed, 12 insertions, 7 deletions
diff --git a/install/config.sql b/install/config.sql
index 52f810885..2c8d2594d 100644
--- a/install/config.sql
+++ b/install/config.sql
@@ -5,9 +5,7 @@ INSERT INTO phpwebgallery_config (param,value,comment) VALUES ('mail_webmaster',
INSERT INTO phpwebgallery_config (param,value,comment) VALUES ('default_language','en_UK.iso-8859-1','Default gallery language');
INSERT INTO phpwebgallery_config (param,value,comment) VALUES ('default_template','default','Default gallery style');
INSERT INTO phpwebgallery_config (param,value,comment) VALUES ('access','free','access type to your gallery (free|restricted)');
-INSERT INTO phpwebgallery_config (param,value,comment) VALUES ('show_comments','true','display the users comments');
INSERT INTO phpwebgallery_config (param,value,comment) VALUES ('nb_comment_page','10','number of comments to display on each page');
-INSERT INTO phpwebgallery_config (param,value,comment) VALUES ('upload_available','false','authorizing the upload of pictures by users');
INSERT INTO phpwebgallery_config (param,value,comment) VALUES ('upload_maxfilesize','150','maximum filesize for the uploaded pictures');
INSERT INTO phpwebgallery_config (param,value,comment) VALUES ('upload_maxwidth','800','maximum width authorized for the uploaded images');
INSERT INTO phpwebgallery_config (param,value,comment) VALUES ('upload_maxheight','600','maximum height authorized for the uploaded images');
diff --git a/install/dbscheme.txt b/install/dbscheme.txt
index de53364c0..b190134b5 100644
--- a/install/dbscheme.txt
+++ b/install/dbscheme.txt
@@ -25,11 +25,12 @@ column:comment table:categories type:text
column:dir table:categories type:varchar nullable:Y length:255 binary:N
column:rank table:categories type:tinyint nullable:Y length:3 signed:N
column:status table:categories type:enum('public','private') nullable:N
-column:site_id table:categories type:tinyint nullable:N length:4 signed:N
+column:site_id table:categories type:tinyint nullable:Y length:4 signed:N
column:visible table:categories type:enum('true','false') nullable:N
column:uploadable table:categories type:enum('true','false') nullable:N
column:representative_picture_id table:categories type:mediumint nullable:Y length:8 signed:N
column:uppercats table:categories type:varchar nullable:N length:255 binary:N
+column:commentable table:categories type:enum('true','false') nullable:N
column:id table:comments type:int nullable:N length:11 signed:N
column:image_id table:comments type:mediumint nullable:N length:8 signed:N
column:date table:comments type:datetime nullable:N
@@ -45,7 +46,7 @@ column:group_id table:group_access type:smallint
column:cat_id table:group_access type:smallint nullable:N length:5 signed:N
column:id table:groups type:smallint nullable:N length:5 signed:N
column:name table:groups type:varchar nullable:N length:255 binary:N
-column:date table:history type:int nullable:N length:11 signed:Y
+column:date table:history type:datetime nullable:N
column:login table:history type:varchar nullable:Y length:15 binary:N
column:IP table:history type:varchar nullable:N length:50 binary:N
column:category table:history type:varchar nullable:Y length:150 binary:N
@@ -116,6 +117,7 @@ PK:favorites_pk table:favorites column:image_id
PK:group_access_pk table:group_access column:group_id
PK:group_access_pk table:group_access column:cat_id
PK:groups_pk table:groups column:id
+PK:history_pk table:history column:date
PK:image_category_pk table:image_category column:image_id
PK:image_category_pk table:image_category column:category_id
PK:images_pk table:images column:id
@@ -135,5 +137,7 @@ index:image_category_i1 table:image_category column:image_id
index:image_category_i2 table:image_category column:category_id
index:images_i2 table:images column:date_available
index:images_i1 table:images column:storage_category_id
+index:images_i3 table:images column:average_rate
+index:images_i4 table:images column:hit
index:sites_ui1 table:sites column:galleries_url
index:users_ui1 table:users column:username
diff --git a/install/phpwebgallery_structure.sql b/install/phpwebgallery_structure.sql
index 8ad3d1f7a..b45845675 100644
--- a/install/phpwebgallery_structure.sql
+++ b/install/phpwebgallery_structure.sql
@@ -19,11 +19,12 @@ CREATE TABLE phpwebgallery_categories (
dir varchar(255) default NULL,
rank tinyint(3) unsigned default NULL,
status enum('public','private') NOT NULL default 'public',
- site_id tinyint(4) unsigned NOT NULL default '1',
+ site_id tinyint(4) unsigned default '1',
visible enum('true','false') NOT NULL default 'true',
uploadable enum('true','false') NOT NULL default 'false',
representative_picture_id mediumint(8) unsigned default NULL,
uppercats varchar(255) NOT NULL default '',
+ commentable enum('true','false') NOT NULL default 'true',
PRIMARY KEY (id),
KEY categories_i2 (id_uppercat)
) TYPE=MyISAM;
@@ -100,7 +101,7 @@ CREATE TABLE phpwebgallery_history (
category varchar(150) default NULL,
file varchar(50) default NULL,
picture varchar(150) default NULL,
- PRIMARY KEY `date` (`date`)
+ PRIMARY KEY (date)
) TYPE=MyISAM;
--
@@ -141,7 +142,9 @@ CREATE TABLE phpwebgallery_images (
average_rate float(5,2) unsigned default NULL,
PRIMARY KEY (id),
KEY images_i2 (date_available),
- KEY images_i1 (storage_category_id)
+ KEY images_i1 (storage_category_id),
+ KEY images_i3 (average_rate),
+ KEY images_i4 (hit)
) TYPE=MyISAM;
--