Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix form submit messages length (#10266)
* Allow longer form submit message than 191 characters * Review changes * Run cs-fixer on migrations Co-authored-by: Ruth Cheesley <ruth.cheesley@acquia.com> Co-authored-by: Dennis Ameling (he/him) <dennis@dennisameling.com>
- Loading branch information
1 parent
7b85da4
commit 8dcf3ee
Showing
2 changed files
with
31 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
/* | ||
* @copyright <year> Mautic Contributors. All rights reserved. | ||
* @author Mautic | ||
* @link https://mautic.org | ||
* @license GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html | ||
*/ | ||
|
||
namespace Mautic\Migrations; | ||
|
||
use Doctrine\DBAL\Schema\Schema; | ||
use Mautic\CoreBundle\Doctrine\AbstractMauticMigration; | ||
|
||
final class Version20210623071326 extends AbstractMauticMigration | ||
{ | ||
public function up(Schema $schema): void | ||
{ | ||
$this->addSql("ALTER TABLE {$this->prefix}forms MODIFY post_action_property LONGTEXT "); | ||
} | ||
|
||
public function down(Schema $schema): void | ||
{ | ||
$this->addSql("UPDATE {$this->prefix}forms SET post_action_property = left(post_action_property,191)"); | ||
$this->addSql("ALTER TABLE {$this->prefix}forms MODIFY post_action_property VARCHAR(191) DEFAULT NULL "); | ||
} | ||
} |