Improve scheduled task layout and data handling

This commit is contained in:
Dane Everitt 2016-03-18 16:23:10 -04:00
parent c1301c7190
commit 67d9f9f4ab
11 changed files with 639 additions and 0 deletions

View file

@ -0,0 +1,29 @@
<?php
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class AddNullableFieldLastrun extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
$table = DB::getQueryGrammar()->wrapTable('tasks');
DB::statement('ALTER TABLE '.$table.' CHANGE `last_run` `last_run` TIMESTAMP NULL;');
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
$table = DB::getQueryGrammar()->wrapTable('tasks');
DB::statement('ALTER TABLE '.$table.' CHANGE `last_run` `last_run` TIMESTAMP;');
}
}