public function down() { $this->dropTable(\metalguardian\fileProcessor\helpers\FPM::getTableName()); }
/** * @inheritdoc */ public function safeUp() { $this->createTable($this->tableName, ['id' => $this->primaryKey(), 'entity_model_name' => $this->string()->notNull(), 'entity_model_id' => $this->integer()->notNull(), 'file_id' => $this->integer()->notNull(), 'temp_sign' => $this->string()->notNull()->defaultValue(''), 'position' => $this->integer()->notNull()->defaultValue(0), 'attribute' => $this->string()->defaultValue(null)], 'CHARACTER SET utf8 COLLATE utf8_unicode_ci ENGINE=InnoDB'); $this->addForeignKey('fk_entity_file_id_to_fpm_file_table', $this->tableName, 'file_id', \metalguardian\fileProcessor\helpers\FPM::getTableName(), 'id', 'CASCADE', 'CASCADE'); }
/** * @inheritdoc */ public static function tableName() { return \metalguardian\fileProcessor\helpers\FPM::getTableName(); }