yii2-openapi
yii2-openapi copied to clipboard
Migration for new fields: Use AFTER to keep order as in schema
Migrations for adding new columns should use "AFTER" keyword to make sure order of columns is the same as in schema.
I tested with MySQL.
I added new property in schema, then executed ./yii gii/api
. Migration for new column does not have after()
but when I apply newly created migration it automatically adds after the last column/property.
In which cases you are facing this issue?
Edit
Anyway I figured the case where after
is nice to have: if we want to add field in between existing fields and not at last position
@SOHELAHMED7 as far as I see this feature is complete. Please close the issue if that is the case.
Yes. this is completed. I cannot see close button. Seems like you have to close this issue