Skip to content

Commit b636242

Browse files
committed
feature 2604: add images.rotation at database creation (not only during upgrade)
git-svn-id: http://piwigo.org/svn/trunk@13849 68402e56-0260-453c-a942-63ccdbb3a9ee
1 parent f318fe0 commit b636242

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

install/db/120-database.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828

2929
$upgrade_description = 'rotation mode (code, not angle) is stored in the database';
3030

31-
$query = 'ALTER TABLE '.IMAGES_TABLE.' ADD COLUMN rotation tinyint DEFAULT NULL';
31+
$query = 'ALTER TABLE '.IMAGES_TABLE.' ADD COLUMN rotation tinyint unsigned DEFAULT NULL';
3232
pwg_query($query);
3333

3434
echo

install/piwigo_structure-mysql.sql

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ CREATE TABLE `piwigo_images` (
185185
`filesize` mediumint(9) unsigned default NULL,
186186
`width` smallint(9) unsigned default NULL,
187187
`height` smallint(9) unsigned default NULL,
188-
`coi` char(4) default NULL COMMENT 'center of interest',
188+
`coi` char(4) default NULL COMMENT 'center of interest',
189189
`representative_ext` varchar(4) default NULL,
190190
`date_metadata_update` date default NULL,
191191
`rating_score` float(5,2) unsigned default NULL,
@@ -198,6 +198,7 @@ CREATE TABLE `piwigo_images` (
198198
`level` tinyint unsigned NOT NULL default '0',
199199
`md5sum` char(32) default NULL,
200200
`added_by` smallint(5) NOT NULL default '0',
201+
`rotation` tinyint unsigned default null,
201202
PRIMARY KEY (`id`),
202203
KEY `images_i2` (`date_available`),
203204
KEY `images_i3` (`rating_score`),

0 commit comments

Comments
 (0)