Easy, powerful and ultrafast ODM for PHP and MongoDB
fresh()
method to reload instances from databaseAdd soft delete feature.
Add support to PHP 8.0, Illuminate 9.x and 10.x and MongoDB 5.0. Drop support to PHP 7.x, Illuminate 5.x, 6.x, 7.x and 8.x, and MongoDB 3.6.
Adds support to PHP 8.1.
Attempts to get the document from cache on the referenced objects only if the cacheable parameter is true.
Adds support to PHP versions: 7.3, 7.4, 8.0 and 8.1.
This release fixes a bug on setup configuration Connection/Manager.
Full Changelog: https://github.com/leroy-merlin-br/mongolid/compare/v3.1.0...v3.1.1
In this release we've made some upgrades in order to provide some improvements such as better usability, better implementation and a clearer and better documentation of this ODM.
Please find below a brief summary of the main change in this release
In case you have doubts or you just want to know more details, check the documentation
Now you can mass assign attributes using the fill
static method:
$post = new Post();
$post = $post->fill(['title' => 'Bacon'], $post);
// or
$post = Post::fill(['title' => 'Bacon'], $post);
A long time ago, we decided that we want to create a new version for Mongolid. With a better and updated documentation, removing some misconceptions and adding new features that was nice to see on Laravel's Eloquent.
We managed to create a version 3, but we could not document it, and we could not test on our scenario (in Leroy Merlin) and the fear of a breaking change stopped us to use it.
So, we decided that we want to use new (v3) Mongolid features, but in baby steps.
That's why we are "jumping" one version to use on production right away.
This release upgrades MongoDB Version to 4.2 and MongoDB Library to 1.8.0.
You will still continue to be able to use it with mongoDB 4.0 version or below.
Nothing really changed except the findOneAndUpdate
now returns an array instead of object.