This repository has been archived on 2025-05-09. You can view files and clone it, but you cannot make any changes to it's state, such as pushing and creating new issues, pull requests or comments.
Astral-nook/database/migrations/2016_11_09_163911_add_checksums_table.php

36 lines
796 B
PHP

<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class AddChecksumsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('checksums', function (Blueprint $table) {
$table->increments('id');
$table->integer('service')->unsigned();
$table->string('filename');
$table->char('checksum', 40);
$table->timestamps();
$table->foreign('service')->references('id')->on('services');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::drop('checksums');
}
}