diff options
Diffstat (limited to 'apps/gallery/appinfo')
-rw-r--r-- | apps/gallery/appinfo/app.php | 4 | ||||
-rw-r--r-- | apps/gallery/appinfo/database.xml | 2 | ||||
-rw-r--r-- | apps/gallery/appinfo/update.php | 14 |
3 files changed, 12 insertions, 8 deletions
diff --git a/apps/gallery/appinfo/app.php b/apps/gallery/appinfo/app.php index e1db33eb314..e3a8dbd588b 100644 --- a/apps/gallery/appinfo/app.php +++ b/apps/gallery/appinfo/app.php @@ -26,6 +26,8 @@ OC::$CLASSPATH['OC_Gallery_Photo'] = 'apps/gallery/lib/photo.php'; OC::$CLASSPATH['OC_Gallery_Scanner'] = 'apps/gallery/lib/scanner.php'; OC::$CLASSPATH['OC_Gallery_Sharing'] = 'apps/gallery/lib/sharing.php'; OC::$CLASSPATH['OC_Gallery_Hooks_Handlers'] = 'apps/gallery/lib/hooks_handlers.php'; +OC::$CLASSPATH['Pictures_Managers'] = 'apps/gallery/lib/managers.php'; +OC::$CLASSPATH['Pictures_Tiles'] = 'apps/gallery/lib/tiles.php'; $l = OC_L10N::get('gallery'); @@ -48,6 +50,6 @@ class OC_GallerySearchProvider extends OC_Search_Provider{ } } -OC_Search::registerProvider('OC_GallerySearchProvider'); +//OC_Search::registerProvider('OC_GallerySearchProvider'); require_once('apps/gallery/lib/hooks_handlers.php'); diff --git a/apps/gallery/appinfo/database.xml b/apps/gallery/appinfo/database.xml index d1ccd6b5a24..1683e0ca2c7 100644 --- a/apps/gallery/appinfo/database.xml +++ b/apps/gallery/appinfo/database.xml @@ -3,7 +3,7 @@ <name>*dbname*</name> <create>true</create> <overwrite>false</overwrite> - <charset>latin1</charset> + <charset>utf8</charset> <table> <name>*dbprefix*pictures_images_cache</name> <declaration> diff --git a/apps/gallery/appinfo/update.php b/apps/gallery/appinfo/update.php index dd248e21b3e..a0997ab5e86 100644 --- a/apps/gallery/appinfo/update.php +++ b/apps/gallery/appinfo/update.php @@ -1,9 +1,11 @@ <?php -$stmt = OCP\DB::prepare('DROP TABLE IF EXISTS *PREFIX*gallery_photos'); -$stmt->execute(); -$stmt = OCP\DB::prepare('DROP TABLE IF EXISTS *PREFIX*gallery_albums'); -$stmt->execute(); - -\OC_DB::createDbFromStructure('./database.xml'); +$currentVersion=OC_Appconfig::getValue('gallery', 'installed_version'); +if (version_compare($currentVersion, '0.5.0', '<')) { + $stmt = OCP\DB::prepare('DROP TABLE IF EXISTS *PREFIX*gallery_photos'); + $stmt->execute(); + $stmt = OCP\DB::prepare('DROP TABLE IF EXISTS *PREFIX*gallery_albums'); + $stmt->execute(); + \OC_DB::createDbFromStructure(OC::$APPSROOT.'/apps/'.$appid.'/appinfo/database.xml'); +} |