You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

22 line
483B

  1. <?php
  2. use yii\db\Schema;
  3. use yii\db\Migration;
  4. class m161014_084709_table_user_boulangerie extends Migration
  5. {
  6. public function up()
  7. {
  8. $this->createTable('user_etablissement', [
  9. 'id_user' => Schema::TYPE_INTEGER . ' NOT NULL',
  10. 'id_etablissement' => Schema::TYPE_INTEGER . ' NOT NULL',
  11. 'PRIMARY KEY (`id_user`, `id_etablissement`)'
  12. ]);
  13. }
  14. public function down()
  15. {
  16. $this->dropTable('user_etablissement');
  17. }
  18. }