[Fixed] column type
This commit is contained in:
parent
1f31efbd31
commit
f83495cb02
@ -5,9 +5,6 @@ declare(strict_types=1);
|
|||||||
namespace D3\ManufacturerInformation\Migrations;
|
namespace D3\ManufacturerInformation\Migrations;
|
||||||
|
|
||||||
use Doctrine\DBAL\Schema\Schema;
|
use Doctrine\DBAL\Schema\Schema;
|
||||||
use Doctrine\DBAL\Types\DateTimeType;
|
|
||||||
use Doctrine\DBAL\Types\DateType;
|
|
||||||
use Doctrine\DBAL\Types\IntegerType;
|
|
||||||
use Doctrine\DBAL\Types\TextType;
|
use Doctrine\DBAL\Types\TextType;
|
||||||
use Doctrine\Migrations\AbstractMigration;
|
use Doctrine\Migrations\AbstractMigration;
|
||||||
|
|
||||||
@ -29,10 +26,7 @@ final class Version20241023154223 extends AbstractMigration
|
|||||||
}
|
}
|
||||||
|
|
||||||
public function down(Schema $schema) : void
|
public function down(Schema $schema) : void
|
||||||
{
|
{}
|
||||||
// this down() migration is auto-generated, please modify it to your needs
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param Schema $schema
|
* @param Schema $schema
|
||||||
@ -47,7 +41,6 @@ final class Version20241023154223 extends AbstractMigration
|
|||||||
// Beschreibung
|
// Beschreibung
|
||||||
if (!$table->hasColumn('D3DESCRIPTION')) {
|
if (!$table->hasColumn('D3DESCRIPTION')) {
|
||||||
$table->addColumn('D3DESCRIPTION', (new TextType())->getName())
|
$table->addColumn('D3DESCRIPTION', (new TextType())->getName())
|
||||||
->setLength($this->connection->getDatabasePlatform()::LENGTH_LIMIT_TEXT)
|
|
||||||
->setNotnull(true);
|
->setNotnull(true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -15,7 +15,7 @@ final class Version20241028172608 extends AbstractMigration
|
|||||||
{
|
{
|
||||||
public function getDescription() : string
|
public function getDescription() : string
|
||||||
{
|
{
|
||||||
return 'Adds multilang tables';
|
return 'Adds multilang tables for the D3 manufacturer longdesc';
|
||||||
}
|
}
|
||||||
|
|
||||||
public function up(Schema $schema) : void
|
public function up(Schema $schema) : void
|
||||||
@ -26,10 +26,7 @@ final class Version20241028172608 extends AbstractMigration
|
|||||||
}
|
}
|
||||||
|
|
||||||
public function down(Schema $schema) : void
|
public function down(Schema $schema) : void
|
||||||
{
|
{}
|
||||||
// this down() migration is auto-generated, please modify it to your needs
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param Schema $schema
|
* @param Schema $schema
|
||||||
@ -43,22 +40,19 @@ final class Version20241028172608 extends AbstractMigration
|
|||||||
|
|
||||||
// lang 1
|
// lang 1
|
||||||
if (!$table->hasColumn('D3DESCRIPTION_1')) {
|
if (!$table->hasColumn('D3DESCRIPTION_1')) {
|
||||||
$table->addColumn('D3DESCRIPTION_1', (new TextType\())->getName())
|
$table->addColumn('D3DESCRIPTION_1', (new TextType())->getName())
|
||||||
->setLength($this->connection->getDatabasePlatform()::LENGTH_LIMIT_TEXT)
|
|
||||||
->setNotnull(true);
|
->setNotnull(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
// lang 2
|
// lang 2
|
||||||
if (!$table->hasColumn('D3DESCRIPTION_2')) {
|
if (!$table->hasColumn('D3DESCRIPTION_2')) {
|
||||||
$table->addColumn('D3DESCRIPTION_2', (new TextType\())->getName())
|
$table->addColumn('D3DESCRIPTION_2', (new TextType())->getName())
|
||||||
->setLength($this->connection->getDatabasePlatform()::LENGTH_LIMIT_TEXT)
|
|
||||||
->setNotnull(true);
|
->setNotnull(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
// lang 3
|
// lang 3
|
||||||
if (!$table->hasColumn('D3DESCRIPTION_3')) {
|
if (!$table->hasColumn('D3DESCRIPTION_3')) {
|
||||||
$table->addColumn('D3DESCRIPTION_3', (new TextType\())->getName())
|
$table->addColumn('D3DESCRIPTION_3', (new TextType())->getName())
|
||||||
->setLength($this->connection->getDatabasePlatform()::LENGTH_LIMIT_TEXT)
|
|
||||||
->setNotnull(true);
|
->setNotnull(true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user