ammend
All checks were successful
/ ls (pull_request) Successful in 1m35s
/ ls (push) Successful in 1m31s

This commit is contained in:
lubiana 2025-06-21 15:20:08 +02:00
parent c8e6af6896
commit 98feafa3fc
Signed by: lubiana
SSH key fingerprint: SHA256:vW1EA0fRR3Fw+dD/sM0K+x3Il2gSry6YRYHqOeQwrfk
3 changed files with 49 additions and 2 deletions

View file

@ -1,4 +1,4 @@
<?php <?php declare(strict_types=1);
/** /**
* Returns the importmap for this application. * Returns the importmap for this application.

View file

@ -0,0 +1,47 @@
<?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 Version20250621131822 extends AbstractMigration
{
public function getDescription(): string
{
return '';
}
public function up(Schema $schema): void
{
// this up() migration is auto-generated, please modify it to your needs
$this->addSql(<<<'SQL'
ALTER TABLE food_vendor ADD COLUMN emojis VARCHAR(30) DEFAULT NULL
SQL);
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql(<<<'SQL'
CREATE TEMPORARY TABLE __temp__food_vendor AS SELECT name, phone, menu_link, id FROM food_vendor
SQL);
$this->addSql(<<<'SQL'
DROP TABLE food_vendor
SQL);
$this->addSql(<<<'SQL'
CREATE TABLE food_vendor (name VARCHAR(50) NOT NULL, phone VARCHAR(50) DEFAULT '', menu_link VARCHAR(255) DEFAULT NULL, id BLOB NOT NULL, PRIMARY KEY(id))
SQL);
$this->addSql(<<<'SQL'
INSERT INTO food_vendor (name, phone, menu_link, id) SELECT name, phone, menu_link, id FROM __temp__food_vendor
SQL);
$this->addSql(<<<'SQL'
DROP TABLE __temp__food_vendor
SQL);
}
}

View file

@ -12,8 +12,8 @@ use Symfony\Bridge\Doctrine\IdGenerator\UlidGenerator;
use Symfony\Bridge\Doctrine\Types\UlidType; use Symfony\Bridge\Doctrine\Types\UlidType;
use Symfony\Component\Serializer\Annotation\Groups; use Symfony\Component\Serializer\Annotation\Groups;
use Symfony\Component\Uid\Ulid; use Symfony\Component\Uid\Ulid;
use Symfony\Component\Validator\Constraints\Length; use Symfony\Component\Validator\Constraints\Length;
use function mb_strlen; use function mb_strlen;
#[ORM\Entity(repositoryClass: FoodVendorRepository::class)] #[ORM\Entity(repositoryClass: FoodVendorRepository::class)]