Preparing new api for hasil-belajar

This commit is contained in:
Gregorio Chiko Putra
2019-05-14 15:26:44 +07:00
parent 9b91fe40ce
commit dbe517c1fc
6 changed files with 65 additions and 4 deletions

View File

@@ -0,0 +1,34 @@
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class AddUrlFieldToAccessLogsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('access_logs', function (Blueprint $table) {
$table->string('url');
});
DB::table('access_logs')->update(['url' => '/api/siswa']);
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('access_logs', function (Blueprint $table) {
$table->dropColumn('url');
});
}
}