<?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 Version20200521111605 extends AbstractMigration
{
public function up(Schema $schema) : void
{
$this->addSql("INSERT INTO `std_blocks_components` (`machine_name`, `block_id`, `created_by`, `updated_by`, `component_type`, `settings`, `order_value`, `is_active`, `created_date`, `updated_date`, `name`, `is_repeatable`) VALUES ('form_input_children', (SELECT id FROM std_blocks WHERE machine_name='form_select'), 1, 1, 'INPUT', NULL, 5, 1, '2019-08-21 10:20:41', '2019-08-21 10:20:41', 'input_children', 0);");
$this->addSql("INSERT INTO `std_blocks_components` (`machine_name`, `block_id`, `created_by`, `updated_by`, `component_type`, `settings`, `order_value`, `is_active`, `created_date`, `updated_date`, `name`, `is_repeatable`) VALUES ('form_select_parent_relation', (SELECT id FROM std_blocks WHERE machine_name='form_select'), 1, 1, 'INPUT', NULL, 7, 1, '2019-08-21 10:22:55', '2019-08-21 10:22:56', 'select_parent_relation', 1);");
$this->addSql("UPDATE `std_blocks_components` SET `order_value`='8' WHERE `block_id`=(SELECT id FROM std_blocks WHERE machine_name='form_select') AND `machine_name`='form_select_label';");
$this->addSql("UPDATE `std_blocks_components` SET `order_value`='9' WHERE `block_id`=(SELECT id FROM std_blocks WHERE machine_name='form_select') AND `machine_name`='form_select_value';");
$this->addSql("UPDATE `std_blocks_components` SET `order_value`='10' WHERE `block_id`=(SELECT id FROM std_blocks WHERE machine_name='form_select') AND `machine_name`='form_select_parent_relation';");
}
public function down(Schema $schema) : void
{
$this->addSql("DELETE FROM `std_blocks_components` WHERE `machine_name` = 'form_select_parent_relation' AND `block_id` = (SELECT id FROM std_blocks WHERE machine_name='form_select') ");
$this->addSql("DELETE FROM `std_blocks_components` WHERE `machine_name` = 'form_input_children' AND `block_id` = (SELECT id FROM std_blocks WHERE machine_name='form_select') ");
}
}