Create New Item
×
Item Type
File
Folder
Item Name
×
Search file in folder and subfolders...
File Manager
/
database
/
migrations
Advanced Search
Upload
New Item
Settings
Back
Back Up
Advanced Editor
Save
<?php use Illuminate\Support\Facades\Schema; use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Migrations\Migration; class CreateAuditTable extends Migration { /** * Run the migrations. * * @return void */ public function up() { Schema::create('audit_trail', function ($table) { $table->increments('id'); $table->integer('user_id')->nullable(); $table->string('owner_type'); $table->integer('owner_id')->nullable(); $table->text('old_value')->nullable(); $table->text('new_value')->nullable(); $table->string('type'); $table->string('route')->nullable(); $table->string('ip')->nullable(); $table->timestamps(); }); } /** * Reverse the migrations. * * @return void */ public function down() { Schema::dropIfExists('audit_trail'); } }