"socialiteproviders/okta": "^1.0",
"socialiteproviders/gitlab": "^3.0",
"socialiteproviders/twitch": "^3.0",
- "socialiteproviders/discord": "^2.0"
+ "socialiteproviders/discord": "^2.0",
+ "doctrine/dbal": "^2.5"
},
"require-dev": {
"filp/whoops": "~2.0",
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
"This file is @generated automatically"
],
- "content-hash": "b98be6702f1293174f785f99895e798b",
+ "content-hash": "eae00f50d183bb224c934683b06e8f9c",
"packages": [
{
"name": "aws/aws-sdk-php",
],
"time": "2014-05-19T10:25:02+00:00"
},
+ {
+ "name": "doctrine/annotations",
+ "version": "v1.4.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/doctrine/annotations.git",
+ "reference": "54cacc9b81758b14e3ce750f205a393d52339e97"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/doctrine/annotations/zipball/54cacc9b81758b14e3ce750f205a393d52339e97",
+ "reference": "54cacc9b81758b14e3ce750f205a393d52339e97",
+ "shasum": ""
+ },
+ "require": {
+ "doctrine/lexer": "1.*",
+ "php": "^5.6 || ^7.0"
+ },
+ "require-dev": {
+ "doctrine/cache": "1.*",
+ "phpunit/phpunit": "^5.7"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.4.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Doctrine\\Common\\Annotations\\": "lib/Doctrine/Common/Annotations"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Roman Borschel",
+ },
+ {
+ "name": "Benjamin Eberlei",
+ },
+ {
+ "name": "Guilherme Blanco",
+ },
+ {
+ "name": "Jonathan Wage",
+ },
+ {
+ "name": "Johannes Schmitt",
+ }
+ ],
+ "description": "Docblock Annotations Parser",
+ "homepage": "http://www.doctrine-project.org",
+ "keywords": [
+ "annotations",
+ "docblock",
+ "parser"
+ ],
+ "time": "2017-02-24T16:22:25+00:00"
+ },
+ {
+ "name": "doctrine/cache",
+ "version": "v1.6.2",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/doctrine/cache.git",
+ "reference": "eb152c5100571c7a45470ff2a35095ab3f3b900b"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/doctrine/cache/zipball/eb152c5100571c7a45470ff2a35095ab3f3b900b",
+ "reference": "eb152c5100571c7a45470ff2a35095ab3f3b900b",
+ "shasum": ""
+ },
+ "require": {
+ "php": "~5.5|~7.0"
+ },
+ "conflict": {
+ "doctrine/common": ">2.2,<2.4"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "~4.8|~5.0",
+ "predis/predis": "~1.0",
+ "satooshi/php-coveralls": "~0.6"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.6.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Doctrine\\Common\\Cache\\": "lib/Doctrine/Common/Cache"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Roman Borschel",
+ },
+ {
+ "name": "Benjamin Eberlei",
+ },
+ {
+ "name": "Guilherme Blanco",
+ },
+ {
+ "name": "Jonathan Wage",
+ },
+ {
+ "name": "Johannes Schmitt",
+ }
+ ],
+ "description": "Caching library offering an object-oriented API for many cache backends",
+ "homepage": "http://www.doctrine-project.org",
+ "keywords": [
+ "cache",
+ "caching"
+ ],
+ "time": "2017-07-22T12:49:21+00:00"
+ },
+ {
+ "name": "doctrine/collections",
+ "version": "v1.4.0",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/doctrine/collections.git",
+ "reference": "1a4fb7e902202c33cce8c55989b945612943c2ba"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/doctrine/collections/zipball/1a4fb7e902202c33cce8c55989b945612943c2ba",
+ "reference": "1a4fb7e902202c33cce8c55989b945612943c2ba",
+ "shasum": ""
+ },
+ "require": {
+ "php": "^5.6 || ^7.0"
+ },
+ "require-dev": {
+ "doctrine/coding-standard": "~0.1@dev",
+ "phpunit/phpunit": "^5.7"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.3.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-0": {
+ "Doctrine\\Common\\Collections\\": "lib/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Roman Borschel",
+ },
+ {
+ "name": "Benjamin Eberlei",
+ },
+ {
+ "name": "Guilherme Blanco",
+ },
+ {
+ "name": "Jonathan Wage",
+ },
+ {
+ "name": "Johannes Schmitt",
+ }
+ ],
+ "description": "Collections Abstraction library",
+ "homepage": "http://www.doctrine-project.org",
+ "keywords": [
+ "array",
+ "collections",
+ "iterator"
+ ],
+ "time": "2017-01-03T10:49:41+00:00"
+ },
+ {
+ "name": "doctrine/common",
+ "version": "v2.7.3",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/doctrine/common.git",
+ "reference": "4acb8f89626baafede6ee5475bc5844096eba8a9"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/doctrine/common/zipball/4acb8f89626baafede6ee5475bc5844096eba8a9",
+ "reference": "4acb8f89626baafede6ee5475bc5844096eba8a9",
+ "shasum": ""
+ },
+ "require": {
+ "doctrine/annotations": "1.*",
+ "doctrine/cache": "1.*",
+ "doctrine/collections": "1.*",
+ "doctrine/inflector": "1.*",
+ "doctrine/lexer": "1.*",
+ "php": "~5.6|~7.0"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "^5.4.6"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "2.7.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Doctrine\\Common\\": "lib/Doctrine/Common"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Roman Borschel",
+ },
+ {
+ "name": "Benjamin Eberlei",
+ },
+ {
+ "name": "Guilherme Blanco",
+ },
+ {
+ "name": "Jonathan Wage",
+ },
+ {
+ "name": "Johannes Schmitt",
+ }
+ ],
+ "description": "Common Library for Doctrine projects",
+ "homepage": "http://www.doctrine-project.org",
+ "keywords": [
+ "annotations",
+ "collections",
+ "eventmanager",
+ "persistence",
+ "spl"
+ ],
+ "time": "2017-07-22T08:35:12+00:00"
+ },
+ {
+ "name": "doctrine/dbal",
+ "version": "v2.5.13",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/doctrine/dbal.git",
+ "reference": "729340d8d1eec8f01bff708e12e449a3415af873"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/doctrine/dbal/zipball/729340d8d1eec8f01bff708e12e449a3415af873",
+ "reference": "729340d8d1eec8f01bff708e12e449a3415af873",
+ "shasum": ""
+ },
+ "require": {
+ "doctrine/common": ">=2.4,<2.8-dev",
+ "php": ">=5.3.2"
+ },
+ "require-dev": {
+ "phpunit/phpunit": "4.*",
+ "symfony/console": "2.*||^3.0"
+ },
+ "suggest": {
+ "symfony/console": "For helpful console commands such as SQL execution and import of files."
+ },
+ "bin": [
+ "bin/doctrine-dbal"
+ ],
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "2.5.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-0": {
+ "Doctrine\\DBAL\\": "lib/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Roman Borschel",
+ },
+ {
+ "name": "Benjamin Eberlei",
+ },
+ {
+ "name": "Guilherme Blanco",
+ },
+ {
+ "name": "Jonathan Wage",
+ }
+ ],
+ "description": "Database Abstraction Layer",
+ "homepage": "http://www.doctrine-project.org",
+ "keywords": [
+ "database",
+ "dbal",
+ "persistence",
+ "queryobject"
+ ],
+ "time": "2017-07-22T20:44:48+00:00"
+ },
{
"name": "doctrine/inflector",
"version": "v1.2.0",
"prefer-lowest": false,
"platform": {
"php": ">=7.0.0",
- "ext-tidy": "*"
+ "ext-tidy": "*",
+ "ext-dom": "*"
},
"platform-dev": [],
"platform-overrides": {
*/
public function up()
{
- $pdo = \DB::connection()->getPdo();
- $mysqlVersion = $pdo->getAttribute(PDO::ATTR_SERVER_VERSION);
- $requiresISAM = strpos($mysqlVersion, '5.5') === 0;
-
- Schema::create('books', function (Blueprint $table) use ($requiresISAM) {
- if($requiresISAM) $table->engine = 'MyISAM';
-
+ Schema::create('books', function (Blueprint $table) {
$table->increments('id');
$table->string('name');
$table->string('slug')->indexed();
*/
public function up()
{
- $pdo = \DB::connection()->getPdo();
- $mysqlVersion = $pdo->getAttribute(PDO::ATTR_SERVER_VERSION);
- $requiresISAM = strpos($mysqlVersion, '5.5') === 0;
- Schema::create('pages', function (Blueprint $table) use ($requiresISAM) {
- if($requiresISAM) $table->engine = 'MyISAM';
-
+
+ Schema::create('pages', function (Blueprint $table) {
$table->increments('id');
$table->integer('book_id');
$table->integer('chapter_id');
*/
public function up()
{
- $pdo = \DB::connection()->getPdo();
- $mysqlVersion = $pdo->getAttribute(PDO::ATTR_SERVER_VERSION);
- $requiresISAM = strpos($mysqlVersion, '5.5') === 0;
-
- Schema::create('chapters', function (Blueprint $table) use ($requiresISAM) {
- if($requiresISAM) $table->engine = 'MyISAM';
+ Schema::create('chapters', function (Blueprint $table) {
$table->increments('id');
$table->integer('book_id');
$table->string('slug')->indexed();
*/
public function up()
{
- $prefix = DB::getTablePrefix();
- DB::statement("ALTER TABLE {$prefix}pages ADD FULLTEXT search(name, text)");
- DB::statement("ALTER TABLE {$prefix}books ADD FULLTEXT search(name, description)");
- DB::statement("ALTER TABLE {$prefix}chapters ADD FULLTEXT search(name, description)");
+ // This was removed for v0.24 since these indexes are removed anyway
+ // and will cause issues for db engines that don't support such indexes.
+
+// $prefix = DB::getTablePrefix();
+// DB::statement("ALTER TABLE {$prefix}pages ADD FULLTEXT search(name, text)");
+// DB::statement("ALTER TABLE {$prefix}books ADD FULLTEXT search(name, description)");
+// DB::statement("ALTER TABLE {$prefix}chapters ADD FULLTEXT search(name, description)");
}
/**
*/
public function down()
{
- Schema::table('pages', function(Blueprint $table) {
- $table->dropIndex('search');
- });
- Schema::table('books', function(Blueprint $table) {
- $table->dropIndex('search');
- });
- Schema::table('chapters', function(Blueprint $table) {
- $table->dropIndex('search');
- });
+ $sm = Schema::getConnection()->getDoctrineSchemaManager();
+ $pages = $sm->listTableDetails('pages');
+ $books = $sm->listTableDetails('books');
+ $chapters = $sm->listTableDetails('chapters');
+
+ if ($pages->hasIndex('search')) {
+ Schema::table('pages', function(Blueprint $table) {
+ $table->dropIndex('search');
+ });
+ }
+
+ if ($books->hasIndex('search')) {
+ Schema::table('books', function(Blueprint $table) {
+ $table->dropIndex('search');
+ });
+ }
+
+ if ($chapters->hasIndex('search')) {
+ Schema::table('chapters', function(Blueprint $table) {
+ $table->dropIndex('search');
+ });
+ }
+
}
}
*/
public function up()
{
- $prefix = DB::getTablePrefix();
- DB::statement("ALTER TABLE {$prefix}pages ADD FULLTEXT name_search(name)");
- DB::statement("ALTER TABLE {$prefix}books ADD FULLTEXT name_search(name)");
- DB::statement("ALTER TABLE {$prefix}chapters ADD FULLTEXT name_search(name)");
+ // This was removed for v0.24 since these indexes are removed anyway
+ // and will cause issues for db engines that don't support such indexes.
+
+// $prefix = DB::getTablePrefix();
+// DB::statement("ALTER TABLE {$prefix}pages ADD FULLTEXT name_search(name)");
+// DB::statement("ALTER TABLE {$prefix}books ADD FULLTEXT name_search(name)");
+// DB::statement("ALTER TABLE {$prefix}chapters ADD FULLTEXT name_search(name)");
}
/**
*/
public function down()
{
- Schema::table('pages', function(Blueprint $table) {
- $table->dropIndex('name_search');
- });
- Schema::table('books', function(Blueprint $table) {
- $table->dropIndex('name_search');
- });
- Schema::table('chapters', function(Blueprint $table) {
- $table->dropIndex('name_search');
- });
+ $sm = Schema::getConnection()->getDoctrineSchemaManager();
+ $pages = $sm->listTableDetails('pages');
+ $books = $sm->listTableDetails('books');
+ $chapters = $sm->listTableDetails('chapters');
+
+ if ($pages->hasIndex('name_search')) {
+ Schema::table('pages', function(Blueprint $table) {
+ $table->dropIndex('name_search');
+ });
+ }
+
+ if ($books->hasIndex('name_search')) {
+ Schema::table('books', function(Blueprint $table) {
+ $table->dropIndex('name_search');
+ });
+ }
+
+ if ($chapters->hasIndex('name_search')) {
+ Schema::table('chapters', function(Blueprint $table) {
+ $table->dropIndex('name_search');
+ });
+ }
}
}
$table->index('score');
});
- // Drop search indexes
- Schema::table('pages', function(Blueprint $table) {
- $table->dropIndex('search');
- $table->dropIndex('name_search');
- });
- Schema::table('books', function(Blueprint $table) {
- $table->dropIndex('search');
- $table->dropIndex('name_search');
- });
- Schema::table('chapters', function(Blueprint $table) {
- $table->dropIndex('search');
- $table->dropIndex('name_search');
- });
+ $sm = Schema::getConnection()->getDoctrineSchemaManager();
+ $pages = $sm->listTableDetails('pages');
+ $books = $sm->listTableDetails('books');
+ $chapters = $sm->listTableDetails('chapters');
+
+ if ($pages->hasIndex('search')) {
+ Schema::table('pages', function(Blueprint $table) {
+ $table->dropIndex('search');
+ $table->dropIndex('name_search');
+ });
+ }
+
+ if ($books->hasIndex('search')) {
+ Schema::table('books', function(Blueprint $table) {
+ $table->dropIndex('search');
+ $table->dropIndex('name_search');
+ });
+ }
+
+ if ($chapters->hasIndex('search')) {
+ Schema::table('chapters', function(Blueprint $table) {
+ $table->dropIndex('search');
+ $table->dropIndex('name_search');
+ });
+ }
app(\BookStack\Services\SearchService::class)->indexAllEntities();
}
*/
public function down()
{
- $prefix = DB::getTablePrefix();
- DB::statement("ALTER TABLE {$prefix}pages ADD FULLTEXT search(name, text)");
- DB::statement("ALTER TABLE {$prefix}books ADD FULLTEXT search(name, description)");
- DB::statement("ALTER TABLE {$prefix}chapters ADD FULLTEXT search(name, description)");
- DB::statement("ALTER TABLE {$prefix}pages ADD FULLTEXT name_search(name)");
- DB::statement("ALTER TABLE {$prefix}books ADD FULLTEXT name_search(name)");
- DB::statement("ALTER TABLE {$prefix}chapters ADD FULLTEXT name_search(name)");
+ // This was removed for v0.24 since these indexes are removed anyway
+ // and will cause issues for db engines that don't support such indexes.
+// $prefix = DB::getTablePrefix();
+// DB::statement("ALTER TABLE {$prefix}pages ADD FULLTEXT search(name, text)");
+// DB::statement("ALTER TABLE {$prefix}books ADD FULLTEXT search(name, description)");
+// DB::statement("ALTER TABLE {$prefix}chapters ADD FULLTEXT search(name, description)");
+// DB::statement("ALTER TABLE {$prefix}pages ADD FULLTEXT name_search(name)");
+// DB::statement("ALTER TABLE {$prefix}books ADD FULLTEXT name_search(name)");
+// DB::statement("ALTER TABLE {$prefix}chapters ADD FULLTEXT name_search(name)");
+
Schema::dropIfExists('search_terms');
}
}