Index for photo
This commit is contained in:
parent
149c7dcc53
commit
075d31e9f4
36
database/migrations/2019_12_15_210931_indexes_photo.php
Normal file
36
database/migrations/2019_12_15_210931_indexes_photo.php
Normal file
@ -0,0 +1,36 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
class IndexesPhoto extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('photo', function (Blueprint $table) {
|
||||
$table->index(['signature']);
|
||||
$table->index(['file_signature']);
|
||||
$table->index(['duplicate','remove']);
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('photo', function (Blueprint $table) {
|
||||
$table->dropIndex(['signature']);
|
||||
$table->dropIndex(['file_signature']);
|
||||
$table->dropIndex(['duplicate','remove']);
|
||||
});
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user