Skip to content

Commit

Permalink
TASK: Change size of redirecturi to store more uris
Browse files Browse the repository at this point in the history
  • Loading branch information
daniellienert committed Feb 28, 2019
1 parent 447fd79 commit b091170
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Classes/Domain/Model/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ final class Client implements ClientEntityInterface
protected $hashedSecret = null;

/**
* @ORM\Column(nullable=true)
* @ORM\Column(nullable=true, type="text", length=2000)
* @var string
*/
protected $redirectUri = null;
Expand Down
44 changes: 44 additions & 0 deletions Migrations/Mysql/Version20190228174241.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
<?php
namespace Neos\Flow\Persistence\Doctrine\Migrations;

use Doctrine\DBAL\Migrations\AbstractMigration;
use Doctrine\DBAL\Schema\Schema;

class Version20190228174241 extends AbstractMigration
{

/**
* @return string
*/
public function getDescription()
{
return 'Change redirecturi field to text';
}

/**
* @param Schema $schema
* @return void
* @throws \Doctrine\DBAL\DBALException
* @throws \Doctrine\DBAL\Migrations\AbortMigrationException
*/
public function up(Schema $schema)
{
// this up() migration is autogenerated, please modify it to your needs
$this->abortIf($this->connection->getDatabasePlatform()->getName() != 'mysql', 'Migration can only be executed safely on "mysql".');
$this->addSql('ALTER TABLE punktde_oauth2_server_domain_model_client CHANGE redirecturi redirecturi TEXT DEFAULT NULL');
}

/**
* @param Schema $schema
* @return void
* @throws \Doctrine\DBAL\DBALException
* @throws \Doctrine\DBAL\Migrations\AbortMigrationException
*/
public function down(Schema $schema)
{
// this down() migration is autogenerated, please modify it to your needs
$this->abortIf($this->connection->getDatabasePlatform()->getName() != 'mysql', 'Migration can only be executed safely on "mysql".');

$this->addSql('ALTER TABLE punktde_oauth2_server_domain_model_client CHANGE redirecturi redirecturi VARCHAR(255) DEFAULT NULL COLLATE utf8mb4_unicode_ci');
}
}

0 comments on commit b091170

Please sign in to comment.