Skip to content

Releases: tattersoftware/codeigniter4-relations

Hotfix Key Comparison

Choose a tag to compare

@MGatner MGatner released this 14 Jul 20:14
7d96b9f

Fixes a backwards-incompatible strict comparison change wrought by CS Fixer (swear it was not me, team).

What's Changed

Full Changelog: v2.1.0...v2.1.1

With Deleted Relations

Choose a tag to compare

@MGatner MGatner released this 14 Jul 19:11
a3e0ea2

Adds support for including soft deleted items when then relation is controlled by a supported model.

What's Changed

Full Changelog: v2.0.7...v2.1.0

Coding Style

Choose a tag to compare

@MGatner MGatner released this 14 Jul 18:20
c443f1b

This is a housekeeping release to get this package up to speed with the latest development tools and practices from the CodeIgniter DevKit.

No content changes this release.

What's Changed

New Contributors

Full Changelog: v2.0.6...v2.0.7

Bugfixes

Choose a tag to compare

@MGatner MGatner released this 30 Dec 17:47
d033806
  • Fixes a bug where an Entity could have an existing attribute with value null, yet Relations would try to look it up as a table reference.
  • Updates the development toolkit

Improve property handling

Choose a tag to compare

@MGatner MGatner released this 08 Nov 18:31
f602add

Fixes a bug where the $with and $without properties would not be handled appropriately.

Thanks to @sfadschm!

Remove constructors, Bugfixes

Choose a tag to compare

@MGatner MGatner released this 13 Jul 20:31
b964ae2
  • Removes trait constructors to make them easier to integrate
  • Improves test performance and stability

Bugfix method name

Choose a tag to compare

@MGatner MGatner released this 23 Mar 17:37
ac1b4fe
  • Fixes an issue with a legacy method name that could cause an exception in ModelTrait

Bugfix empty relations

Choose a tag to compare

@MGatner MGatner released this 08 Jan 21:13
1d8acce

Fixed a bug where EntityTrait could throw an exception if there was a related table with no related items.

Bugfix entity __isset

Choose a tag to compare

@MGatner MGatner released this 21 Nov 20:50
aec1aa9

EntityTrait was missing a corresponding __isset() method for its magic get, causing isset() and empty() requests to fail when there were accessible relations.

Refactored: Traits, Entity support, and more

Choose a tag to compare

@MGatner MGatner released this 19 Nov 21:20
688f4ea

This is a thorough update of the functionality of Relations. Of note to current users, the relations Model no longer exists. Functionality has been moved to ModelTrait, so in order to keep using relations-aware models you should remove the extended class and replace it with the trait:

class MyModel extends \CodeIgniter\Model
{
	use \Tatter\Relations\Traits\ModelTrait;

Entities now support lazy-loading relations via magic methods. Read the docs for more info, but to add support simply include the trait and the necessary properties:

	use \Tatter\Relations\Traits\EntityTrait
	
	protected $table      = 'users';
	protected $primaryKey = 'id';

A number of bugs were fixed (or just written out) and a lot more tests were added. Up next: examples.