Added basic ability to store EDA Data in a Part

But that might change, as it is currently not ideal
This commit is contained in:
Jan Böhmer 2023-11-30 12:54:30 +01:00
parent 2ec1a10623
commit d5f002ac20
12 changed files with 398 additions and 1 deletions

View file

@ -0,0 +1,36 @@
<?php
declare(strict_types=1);
namespace DoctrineMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version20231129231240 extends AbstractMigration
{
public function getDescription(): string
{
return 'Added columns for EDA integration';
}
public function up(Schema $schema): void
{
// this up() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE categories ADD eda_info JSON NOT NULL COMMENT \'(DC2Type:json_document)\'');
$this->addSql('ALTER TABLE footprints ADD eda_info JSON NOT NULL COMMENT \'(DC2Type:json_document)\'');
$this->addSql('ALTER TABLE parts ADD eda_info JSON NOT NULL COMMENT \'(DC2Type:json_document)\'');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE `categories` DROP eda_info');
$this->addSql('ALTER TABLE `footprints` DROP eda_info');
$this->addSql('ALTER TABLE `parts` DROP eda_info');
}
}