Blame | Letzte Änderung | Log anzeigen | RSS feed
<?phpuse Illuminate\Database\Migrations\Migration;use Illuminate\Database\Schema\Blueprint;use Illuminate\Support\Facades\Schema;return new class extends Migration{/*** Run the migrations.** @return void*/public function up(): void{Schema::create( 'templates', function ( Blueprint $table ){$table->id();$table->foreignId( 'shop_id' )->nullable()->constrained()->cascadeOnUpdate()->nullOnDelete();$table->string( 'name' )->default( '' );$table->text( "description" )->default( '' );$table->string( 'template_key' )->default( '' );$table->text( 'template_value' )->default( '' );$table->enum( 'type', [ '', 'action', 'item', 'directory', 'articlemaster' ] )->default( '' );$table->string( 'created_by' )->default( '' );$table->string( 'updated_by' )->default( '' );$table->timestamps();} );}/*** Reverse the migrations.** @return void*/public function down(): void{Schema::dropIfExists( 'templates' );}};