ldc-arcadia-api/database/arcadia-replicate/Views/Refp/VisuelExportGenfiView.php

64 lines
2.1 KiB
PHP

<?php
declare(strict_types=1);
namespace Database\ArcadiaReplicate\Views\Refp;
use Database\ArcadiaReplicate\IdentifiesTableOrView;
use Database\ArcadiaReplicate\TableOrView;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Schema\Builder;
/**
* Schéma Oracle : REFP.VISUEL_EXPORT_GENFI
* Type : VIEW
* Description : Réplication miroir pour VISUEL_EXPORT_GENFI
*/
final class VisuelExportGenfiView implements TableOrView
{
use IdentifiesTableOrView;
public static function schemaName(): string
{
return 'REFP';
}
public static function name(): string
{
return 'VISUEL_EXPORT_GENFI';
}
public static function isView(): bool
{
return true;
}
public static function description(): string
{
return 'Objet miroir VIEW REFP.VISUEL_EXPORT_GENFI du métamodèle Arcadia.';
}
public static function up(Builder $schema): void
{
if (app()->environment('local', 'testing')) {
$schema->dropIfExists(self::table($schema->getConnection()));
}
$schema->create(self::table($schema->getConnection()), function (Blueprint $table): void {
$table->unsignedBigInteger('NO_ART')->comment('Oracle: NUMBER(10, 0) [PK]');
$table->unsignedBigInteger('CODE_VISUEL')->comment('Oracle: NUMBER(10, 0) [PK]');
$table->unsignedBigInteger('CODE_TYPEVUE')->nullable()->comment('Oracle: NUMBER(10, 0)');
$table->boolean('COPYRIGHT')->nullable()->comment('Oracle: NUMBER(1, 0)');
$table->integer('LANGUE')->nullable()->comment('Oracle: NUMBER(5, 0)');
$table->bigInteger('ORDRE')->nullable()->comment('Oracle: NUMBER(0, 0)');
$table->text('FILENAME')->nullable()->comment('Oracle: VARCHAR2(0, 0)');
$table->integer('UVERSION')->nullable()->comment('Oracle: NUMBER(5, 0)');
$table->primary(['NO_ART', 'CODE_VISUEL']);
});
}
public static function down(Builder $schema): void
{
$schema->dropIfExists(self::table($schema->getConnection()));
}
}