Version20150625155000.php 905 B

1234567891011121314151617181920212223242526272829303132333435
  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. * Session date changes
  8. */
  9. class Version20150625155000 extends AbstractMigrationChamilo
  10. {
  11. /**
  12. * @param Schema $schema
  13. */
  14. public function up(Schema $schema)
  15. {
  16. $this->addSql("INSERT INTO extra_field
  17. (extra_field_type, field_type, variable, display_text, visible, changeable, created_at)
  18. VALUES (1, 1, 'captcha_blocked_until_date', 'Account locked until', 0, 0, NOW())");
  19. }
  20. /**
  21. * @param Schema $schema
  22. */
  23. public function down(Schema $schema)
  24. {
  25. $this->addSql("DELETE FROM extra_field
  26. WHERE variable = 'captcha_blocked_until_date' AND
  27. extra_field_type = 1 AND
  28. field_type = 1");
  29. }
  30. }