Version20150521113600.php 851 B

12345678910111213141516171819202122232425262728293031
  1. <?php
  2. /* For licensing terms, see /license.txt */
  3. namespace Application\Migrations\Schema\V110;
  4. use Application\Migrations\AbstractMigrationChamilo;
  5. use Doctrine\DBAL\Schema\Schema;
  6. /**
  7. * Username changes
  8. */
  9. class Version20150521113600 extends AbstractMigrationChamilo
  10. {
  11. /**
  12. * @param Schema $schema
  13. */
  14. public function up(Schema $schema)
  15. {
  16. $this->addSql('ALTER TABLE c_forum_thread MODIFY thread_replies int UNSIGNED NOT NULL DEFAULT 0');
  17. $this->addSql('ALTER TABLE c_forum_thread MODIFY thread_views int UNSIGNED NOT NULL DEFAULT 0');
  18. }
  19. /**
  20. * @param Schema $schema
  21. */
  22. public function down(Schema $schema)
  23. {
  24. $this->addSql('ALTER TABLE c_forum_thread MODIFY thread_replies int NULL');
  25. $this->addSql('ALTER TABLE c_forum_thread MODIFY thread_views int NULL');
  26. }
  27. }