itskp-odense/Backend/migrations/post_migration.php

11 lines
402 B
PHP
Raw Normal View History

<?php
require "../../bootstrap.php";
use Illuminate\Database\Capsule\Manager as Capsule;
Capsule::schema()->create('posts', function ($table) {//Note til mig selv, husk at din database table skal ende med "s" hvis du faa en lang fejl besked
$table->increments('id');
2021-06-04 10:34:47 +00:00
$table->string('title')->nullable(false);
$table->longtext('description')->nullable(false);
$table->timestamps();
2021-06-04 10:34:47 +00:00
});