您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

m230821_061757_producer_add_option_testimony.php 618B

12345678910111213141516171819202122232425262728
  1. <?php
  2. use yii\db\Migration;
  3. use yii\db\Schema;
  4. /**
  5. * Class m230821_061757_producer_add_option_testimony
  6. */
  7. class m230821_061757_producer_add_option_testimony extends Migration
  8. {
  9. /**
  10. * {@inheritdoc}
  11. */
  12. public function safeUp()
  13. {
  14. $this->addColumn('producer', 'option_testimony', Schema::TYPE_TEXT);
  15. $this->addColumn('producer', 'option_time_saved', Schema::TYPE_FLOAT);
  16. }
  17. /**
  18. * {@inheritdoc}
  19. */
  20. public function safeDown()
  21. {
  22. $this->dropColumn('producer', 'option_testimony');
  23. $this->dropColumn('producer', 'option_time_saved');
  24. }
  25. }