Files
laravel-backend/database/migrations/2020_05_20_105543_create_versions_table.php
Joris Slagter df155bb13d
Some checks failed
continuous-integration/drone/push Build is failing
Initial Laravel API import
- Complete GGZ Ecademy Laravel backend application
- RESTful API for learning products, members, filters
- Authentication and authorization system
- Database migrations and seeders
- Custom CRUD generator commands
- Email notification system
- Integration with frontend applications
2025-12-02 17:40:21 +01:00

48 lines
1.4 KiB
PHP

<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateVersionsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('versions', function (Blueprint $table) {
$table->increments('id');
$table->unsignedInteger('learning_product_id');
$table->string('version_number')->nullable();
$table->dateTime('release_start', 0)->nullable();
$table->dateTime('release_end', 0)->nullable();
$table->dateTime('release_planning_date', 0)->nullable();
$table->longText('release_planning_description')->nullable();
$table->longText('technical_information')->nullable();
$table->timestamps();
$table->softDeletes();
});
Schema::table('versions', function (Blueprint $table) {
$table->foreign('learning_product_id')->references('id')->on('learning_products');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::table('versions', function (Blueprint $table) {
$table->dropForeign('versions_learning_product_id_foreign');
});
Schema::dropIfExists('versions');
}
}