Edited benuzer_id ... to user_id

This commit is contained in:
chrosey 2017-06-15 12:46:34 +02:00
parent a7414e8d66
commit e6c4eb2009
6 changed files with 10 additions and 36 deletions

View File

@ -13,7 +13,7 @@ class CreateBenutzersTable extends Migration
*/
public function up()
{
Schema::rename("users", "benutzer");
//Schema::rename("users", "benutzer");
}
/**
@ -23,6 +23,6 @@ class CreateBenutzersTable extends Migration
*/
public function down()
{
Schema::rename('benutzer',"users");
//Schema::rename('benutzer',"users");
}
}

View File

@ -17,8 +17,8 @@ class CreateEintragungsTable extends Migration
$table->increments('id');
$table->timestamps();
$table->integer('benutzer_id')->unsigned();
$table->foreign('benutzer_id')->references('id')->on('benutzer');
$table->integer('user_id')->unsigned();
$table->foreign('user_id')->references('id')->on('users');
$table->integer('veranstaltung_id')->unsigned();
$table->foreign('veranstaltung_id')->references('id')->on('veranstaltungen');

View File

@ -20,8 +20,8 @@ class CreateEinteilungsTable extends Migration
$table->dateTime('start');
$table->dateTime('ende')->nullable();
$table->integer('benutzer_id')->unsigned();
$table->foreign('benutzer_id')->references('id')->on('benutzer');
$table->integer('user_id')->unsigned();
$table->foreign('user_id')->references('id')->on('users');
$table->integer('veranstaltung_id')->unsigned();
$table->foreign('veranstaltung_id')->references('id')->on('veranstaltungen');

View File

@ -13,7 +13,7 @@ class UpdateBenutzerTable extends Migration
*/
public function up()
{
Schema::table('benutzer', function (Blueprint $table){
Schema::table('users', function (Blueprint $table){
$table->string('anzeigename',20)->unique();
$table->string('telefon',20);
});
@ -26,7 +26,7 @@ class UpdateBenutzerTable extends Migration
*/
public function down()
{
Schema::table('benutzer', function (Blueprint $table){
Schema::table('users', function (Blueprint $table){
$table->dropColumn(['anzeigename','telefon']);
});
}

View File

@ -20,8 +20,8 @@ class CreateArbeitszeitsTable extends Migration
$table->dateTime("beginn");
$table->datetime("ende");
$table->integer('benutzer_id')->unsigned();
$table->foreign('benutzer_id')->references('id')->on('benutzer')->onDelete('cascade');
$table->integer('user_id')->unsigned();
$table->foreign('user_id')->references('id')->on('users')->onDelete('cascade');
});
}

View File

@ -1,26 +0,0 @@
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateArbeitszeitsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
}
}