Releases: loadsys/CakePHP-Basic-Seed
2.1.1
This release fixes an issue with importing seed records that have pre-defined primary keys (id
typically) for the purposes of being able to associate seed data between tables as well as "reset" existing records using ID matching just by re-running a seed.
This change makes all Entity fields _accessible
by default. This could theoretically have an impact on seed imports if you happened to have defined fields in your seed data that you didn't actually want to import into the database, but that seems unlikely.
2.1.0
Significantly improves the processing for importing records. Existing DB records are now matched by primary key (if present) and updated in place where possible. Saves are skipped when there is no difference between the seed data and the existing DB record.
Additionally, both Table::newEntity()
/::patchEntity()
and Table::save()
options are now supported in importTables()
via the _entityOptions
and _saveOptions
keys.
_options
key has been deprecated and will be removed in a future release.
2.0.1
2.0.0
Better error feedback from `firstOrCreate()`
The method will now report validation errors if any are found after a failed save()
.