Running migrations
Nothing to migrate.), changed ones print Created table or Updated table.
When a column exists in the table but not in the fields, the command prints
+ Unknown column: name and asks whether to drop it. Use $skipDropping for columns managed elsewhere.

Order of models
Admin models need no creation date. The menu and the order of models are declared in the navigation section, and foreign keys are added once every table exists, so parents do not have to be migrated first. Models the section does not list follow it, ordered by their class name. A$migration_date left over from CrudAdmin 5 is still read: it orders the models the navigation section does not list, before the models without a date. Two models with the same date are both registered. php artisan admin:upgrade:dates removes the property, see the v6 upgrade guide.
Automatic columns
Columns are added after the field columns in this order:Timestamps and soft deletes
Admin models with timestamps use soft deletes. Deleted records stay in the table and are hidden in the administration and in queries,withTrashed() shows them.
deleted_at field enables soft deletes without timestamps:
force delete option.
Table and connection
Standard Eloquent properties are respected by migrations:Reserved column names
A column named like a property of the model shadows the value of the row. Eloquent returns the property instead of calling__get(), so $row->table returns the table name and $row->attributes the whole row. It happens inside the model, in its traits, and since PHP 8.5 also in every other admin model. Configuration properties of CrudAdmin ($name, $title, $active, …) are moved out of the model instance and are safe; properties of Eloquent ($table, $connection, $casts, $hidden, $visible, $fillable, $guarded, $appends, $with, $exists, $timestamps, $primaryKey, $perPage, $attributes, $original, $relations, …) are not.
admin:migrate reports such fields:
- a new field stops the migration with an error, rename the column;
- a column of an already migrated table is only reported, so existing projects keep working.
getAttribute(), or $row['column']:
app/Models/Lead.php
Skipping column removal
Columns that exist in the table but are not defined in fields are offered for dropping. List columns managed outside of the admin model to keep them without asking, e.g. in a table shared with another project:Migration hooks
Hooks receive theBlueprint of the model table, the schema builder and the running command. Changes made on the blueprint are executed.
Hooks run only when the model is migrated. Without changes in the model use
php artisan admin:migrate --force.