<?php
declare(strict_types=1);
namespace Application\Migrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version20200305092823 extends AbstractMigration
{
private $id = 'ROLE_SYS_MONITOR';
private $name = 'System monitors';
private $description = 'SIEF.space system notification recipients.';
private $visibleToClient = 0;
private $systemGroup = 1;
public function up(Schema $schema): void
{
// this up() migration is auto-generated, please modify it to your needs
$this->addSql('INSERT INTO security_group VALUES (:id, :name, :description, :vc, :system, NOW(), NOW())', [
'id' => $this->id,
'name' => $this->name,
'description' => $this->description,
'vc' => $this->visibleToClient,
'system' => $this->systemGroup,
]);
$this->addSql('INSERT INTO _join_table_security_user_and_group VALUES (2, :id), (798, :id)', [
'id' => $this->id,
]);
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('DELETE FROM _join_table_security_user_and_group WHERE group_id = :id', ['id' => $this->id]);
$this->addSql('DELETE FROM security_group WHERE id = :id', ['id' => $this->id]);
}
}