Joshua
fef9b0d56e
Ajout d'un controlleur et form User pour ajouter un Utilisateurs dans la table avec le password Hash et le role au formet Array Ajout de l'Authenticator pour verifier le Login Nouveau Form pour le login, permet le login correctement Changement des Vu pour Login, permet de POST le password et le mail correctement Ajout d'un IndexController pour les tests Changement du Utilisateurs.php (Table) pour mettre le Login correctement en place (Ajout du systele de login symfony, Mot_de_Passe -> Password, Mail -> UserIdentifier)
57 lines
2.7 KiB
PHP
57 lines
2.7 KiB
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace DoctrineMigrations\Latest;
|
|
|
|
use Doctrine\DBAL\Schema\Schema;
|
|
use Doctrine\Migrations\AbstractMigration;
|
|
|
|
/**
|
|
* Auto-generated Migration: Please modify to your needs!
|
|
*/
|
|
final class Version20241017131649 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('DROP SEQUENCE customer_id_seq CASCADE');
|
|
$this->addSql('DROP SEQUENCE discount_id_seq CASCADE');
|
|
$this->addSql('DROP SEQUENCE dishes_id_seq CASCADE');
|
|
$this->addSql('DROP SEQUENCE order_id_seq CASCADE');
|
|
$this->addSql('DROP SEQUENCE order_detail_id_seq CASCADE');
|
|
$this->addSql('DROP SEQUENCE reservation_id_seq CASCADE');
|
|
$this->addSql('DROP SEQUENCE status_order_id_seq CASCADE');
|
|
$this->addSql('DROP SEQUENCE status_table_id_seq CASCADE');
|
|
$this->addSql('DROP SEQUENCE table_id_seq CASCADE');
|
|
$this->addSql('DROP SEQUENCE user_id_seq CASCADE');
|
|
$this->addSql('ALTER TABLE utilisateurs ADD tabl_id INT DEFAULT NULL');
|
|
$this->addSql('ALTER TABLE utilisateurs ADD CONSTRAINT FK_497B315E4DE1870D FOREIGN KEY (tabl_id) REFERENCES tables (id) NOT DEFERRABLE INITIALLY IMMEDIATE');
|
|
$this->addSql('CREATE INDEX IDX_497B315E4DE1870D ON utilisateurs (tabl_id)');
|
|
}
|
|
|
|
public function down(Schema $schema): void
|
|
{
|
|
// this down() migration is auto-generated, please modify it to your needs
|
|
$this->addSql('CREATE SCHEMA public');
|
|
$this->addSql('CREATE SEQUENCE customer_id_seq INCREMENT BY 1 MINVALUE 1 START 1');
|
|
$this->addSql('CREATE SEQUENCE discount_id_seq INCREMENT BY 1 MINVALUE 1 START 1');
|
|
$this->addSql('CREATE SEQUENCE dishes_id_seq INCREMENT BY 1 MINVALUE 1 START 1');
|
|
$this->addSql('CREATE SEQUENCE order_id_seq INCREMENT BY 1 MINVALUE 1 START 1');
|
|
$this->addSql('CREATE SEQUENCE order_detail_id_seq INCREMENT BY 1 MINVALUE 1 START 1');
|
|
$this->addSql('CREATE SEQUENCE reservation_id_seq INCREMENT BY 1 MINVALUE 1 START 1');
|
|
$this->addSql('CREATE SEQUENCE status_order_id_seq INCREMENT BY 1 MINVALUE 1 START 1');
|
|
$this->addSql('CREATE SEQUENCE status_table_id_seq INCREMENT BY 1 MINVALUE 1 START 1');
|
|
$this->addSql('CREATE SEQUENCE table_id_seq INCREMENT BY 1 MINVALUE 1 START 1');
|
|
$this->addSql('CREATE SEQUENCE user_id_seq INCREMENT BY 1 MINVALUE 1 START 1');
|
|
$this->addSql('ALTER TABLE utilisateurs DROP CONSTRAINT FK_497B315E4DE1870D');
|
|
$this->addSql('DROP INDEX IDX_497B315E4DE1870D');
|
|
$this->addSql('ALTER TABLE utilisateurs DROP tabl_id');
|
|
}
|
|
}
|