Added missing migration from 2.1.12
This commit is contained in:
		@@ -30,6 +30,18 @@ class Version2114 extends Listener
 | 
			
		||||
            return;
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        $migration = DB::table('migrations')
 | 
			
		||||
                       ->where('migration', '2016_06_27_000001_create_mediable_test_tables')
 | 
			
		||||
                       ->first();
 | 
			
		||||
 | 
			
		||||
        if ($migration === null) {
 | 
			
		||||
            DB::table('migrations')->insert([
 | 
			
		||||
                'id' => DB::table('migrations')->max('id') + 1,
 | 
			
		||||
                'migration' => '2016_06_27_000001_create_mediable_test_tables',
 | 
			
		||||
                'batch' => DB::table('migrations')->max('batch') + 1,
 | 
			
		||||
            ]);
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        Artisan::call('migrate', ['--force' => true]);
 | 
			
		||||
 | 
			
		||||
        $this->updateMediaTables();
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										44
									
								
								app/Listeners/Update/V21/Version2116.php
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										44
									
								
								app/Listeners/Update/V21/Version2116.php
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,44 @@
 | 
			
		||||
<?php
 | 
			
		||||
 | 
			
		||||
namespace App\Listeners\Update\V21;
 | 
			
		||||
 | 
			
		||||
use App\Abstracts\Listeners\Update as Listener;
 | 
			
		||||
use App\Events\Install\UpdateFinished as Event;
 | 
			
		||||
use Illuminate\Support\Facades\Artisan;
 | 
			
		||||
use Illuminate\Support\Facades\DB;
 | 
			
		||||
 | 
			
		||||
class Version2116 extends Listener
 | 
			
		||||
{
 | 
			
		||||
    const ALIAS = 'core';
 | 
			
		||||
 | 
			
		||||
    const VERSION = '2.1.16';
 | 
			
		||||
 | 
			
		||||
    /**
 | 
			
		||||
     * Handle the event.
 | 
			
		||||
     *
 | 
			
		||||
     * @param  $event
 | 
			
		||||
     *
 | 
			
		||||
     * @return void
 | 
			
		||||
     */
 | 
			
		||||
    public function handle(Event $event)
 | 
			
		||||
    {
 | 
			
		||||
        if ($this->skipThisUpdate($event)) {
 | 
			
		||||
            return;
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        $migration = DB::table('migrations')
 | 
			
		||||
                       ->where('migration', '2016_06_27_000001_create_mediable_test_tables')
 | 
			
		||||
                       ->first();
 | 
			
		||||
 | 
			
		||||
        if ($migration === null) {
 | 
			
		||||
            DB::table('migrations')->insert([
 | 
			
		||||
                'id' => DB::table('migrations')->max('id') + 1,
 | 
			
		||||
                'migration' => '2016_06_27_000001_create_mediable_test_tables',
 | 
			
		||||
                'batch' => DB::table('migrations')->max('batch') + 1,
 | 
			
		||||
            ]);
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        Artisan::call('migrate', ['--force' => true]);
 | 
			
		||||
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
		Reference in New Issue
	
	Block a user