Skip to content

Correction for DF_Model v2 new table generation

Sam Sehnert requested to merge features/migration_new_tables_model_v2 into master

Fixed brand new table creation via v2 Model migrations.

What I did

  • Models with a missing table will no longer cause the admin area to completely fail to load.
  • Models with missing tables will correctly show warning messages in the admin area.
  • Migrations with new models that don't have corresponding tables in the DB will be created correctly.
  • Generator table list will now include models which don't have corresponding tables in the DB yet.

Implications

May case issues with generating v1 model migrations.

Setup

None

How to test

Create a new model from scratch, then use generator to make a new migration, without first creating a table in the DB for that model. Migration generation should create a model for table creation if the table doesn't exist. If the table does exist, it should create a migration to alter the table into the new structure.

Task: https://preview.gotasman.com/task/detail/42068

Merge request reports