issue #5: Creato migration per generalizzazione documenti e funzioni sul model GenDoc

This commit is contained in:
2023-09-12 15:15:24 +02:00
parent b852a8e753
commit 44c27a9520
3 changed files with 89 additions and 0 deletions

View File

@@ -0,0 +1,36 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateGenDocsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('gen_docs', function (Blueprint $table) {
// Documenti generali definibili agganciabili a diverse entità
$table->id();
$table->timestamps();
$table->integer('entity')->unsigned();
$table->bigInteger('entity_id');
$table->string('filename', 255);
$table->longText('descrizone');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('gen_docs');
}
}