Componette

Componette

nextras

nextras / orm v4.0.7

Orm with clean object design, smart relationship loading and powerful collections.

download-cloud-line composer require nextras/orm

Nextras Orm

Build Status Downloads this Month Stable Version Code coverage

Lightweight and high-performance ORM with clean object design.

Supported platforms:

  • MySQL,
  • PostgreSQL,
  • MS SQL Server.

Docs & resources

Extensions

License

MIT. See full license.

  • v4.0.7 4.0.7

    What's Changed

    • [Nette] Initialize metadata on DIC startup - v4.0 by @mabar in #590
    • allow nette/utils 4.0 by @hrach in #632

    Full Changelog: v4.0.6...v4.0.7

  • v4.0.6 4.0.6

    • fix nullable type ?Type parsing [#592]
  • v4.0.5 4.0.5

    What's Changed

    • Add missing array key checks when using the debug_backtrace() function, #552 by @ste93cry
    • Conventions: fix ManyHasMany keys lookup on MySql with different key casing, #578

    Full Changelog: v4.0.4...v4.0.5

  • v4.0.4 4.0.4

    New patch version 4.0.4 is out! โ„๏ธ What's changed from 4.0.3?

    • fixed support for PHP 8.1 [2c40588]
    • build v4 branch with GitHub actions

    See full commit changelog.

  • v4.0.3 4.0.3

    New patch version 4.0.3 is out! โ˜€ What's changed from 4.0.2?

    • relationship: reading removed entity retracks it [4bea473]
    • repository: revert obtaining entity by entity instance (temporarily to easy update to v4) [d3586f8]

    See full commit changelog.

    You may support Nextras Orm by giving it a star here on GitHub โญ or by Sponsorship (even with a one-time payment).
    Thanks to current sponsors: @stpnkcrk, @vaclavpavek, @chemix, @radimvaculik, @zraly, @manweCZ, @stepapo ๐Ÿค—

  • v4.0.2 4.0.2

    New patch version 4.0.2 is out! ๐ŸŒฑ What's changed from 4.0.1?

    • dbal conventions: removed buggy optimization for finding M:M mapping columns [6763e43]
    • array mapper: fix resolving relationship mapper for proper data storage in ArrayMapper [4218ff6]

    Thanks @martenb for report.

    See full commit changelog.

    You may support Nextras Orm by giving it a star here on GitHub โญ or by Sponsorship.
    Thanks to current sponsors: @stpnkcrk, @davidkregl, @vaclavpavek, @chemix, @radimvaculik, @zraly, @manweCZ. ๐Ÿค—

  • v4.0.1 4.0.1

    New patch version 4.0.1 is out! ๐ŸŽƒ What's changed from 4.0.0?

    • collection: fix HasManyCollection::fetch() accessing invalid iterator state, thanks VojtaBrtnik for reporting [734cd96]

    See full commit changelog.

    You may support Nextras Orm by giving it a star here on GitHub โญ or by Sponsorship.
    Thanks to current sponsors: @stpnkcrk, @vaclavpavek, @chemix and @radimvaculik. ๐Ÿค—

  • v4.0.0 4.0.0

    The major 4.0.0 version is out! ๐ŸŒบ

    What's new: โœ”

    BC breaks: โ—

    See full commit changelog since 3.1 version. ๐Ÿ“ƒ

    You may support Nextras Orm by giving it a star here on GitHub โญ or by Sponsorship.
    Thanks to current sponsors: @stpnkcrk, @vaclavpavek and @chemix. ๐Ÿค—

  • v3.1.4 3.1.4

    New patch version 3.1.4 is out! ๐Ÿด What's changed from 3.1.3?

    • relationships: fix counting 1:M table with composite primary key, thanks @LuckyLuky for reporting [d781eb3]

    See full commit changelog.

    You may support Nextras Orm by giving it a star here on GitHub โญ or by Sponsorship.
    Thanks to current sponsors: @stpnkcrk, @vaclavpavek and @chemix. ๐Ÿค—

  • v4.0.0-rc1 4.0.0 RC1

    The release candidate of major 4.0.0 version is out!

    What's new: โœ”

    BC breaks: โ—

    See full commit changelog since 3.1 version. ๐Ÿ“ƒ

    The work and this release is sponzored - thanks to all donors. ๐Ÿ’ฐ

  • v3.1.3 3.1.3

    New patch version 3.1.3 is out! ๐Ÿˆ What's changed from 3.1.2?

    • fixed updating reverse side of relationship [d495ee1]

    See full commit changelog.

    You may support Nextras Orm by giving it a star here on GitHub โญ or by Sponsorship.

  • v3.1.2 3.1.2

    New patch version 3.1.2 is out! ๐Ÿฃ What's changed from 3.1.1?

    • fixed possibly uninitialized storage reflection in DbalMapper #403 [dd9d092]

    Thanks bug reporters: @honzarac.

    See full commit changelog.

  • v3.1.1 3.1.1

    New patch version 3.1.1 is out! ๐ŸŒต What's changed from 3.1.0?

    • fixed joining the same table multiple times over different relationships #390 [a52a013]
    • fixed invalidate state after persist & before flush #386 [8f98094][3ff59e1]
    • fixed counting a relationship filtered by multilpe has-many conditions #393 [8ac61d4]

    Thanks bug reporters: @step0s, @jtojnar.

    See full commit changelog.

  • v3.1.0 3.1.0

    New minor version 3.1.0 is out. ๐Ÿ˜

    What's new:

    • dropped support for PHP 7.0 [a9cccdd]
    • added support for collection filtering of IPropertyContainters - full support for enum converters [4d1a2dc]
    • added better support for composite primary keys [a0883a2], #290
    • added simple traversing support in fetchPairs() [0a6f7ca], #312
    • added "Did you mean...?" suggestion in exception message [15ef449]
    • added support for Nette 3 components

    BC breaks:
    Please check your code for the following patters to fix the compatibility:

    • (BC break!) Collection filtering by id property accepts only direct values, no Entity itself [4d1a2dc]
    • (BC break!) changed IProperty interface and introduced IEntityAwareProperty [0c46be1]
    • (BC break!) IRepository::remove() accepts only already fetched entities, [a6458da]
    • (BC break!) DbalMapper::getManyHasManyParameters() was receiving the second parameter randomly, sometime it were the metadata of symetric relationship [5521b89]

    See full commit changelog.


    You may support Nextras Dbal & Orm development by attending Akademie42 training.

  • v3.1.0-rc1 3.1 RC1

    Release candidate 1 of new minor 3.1.0 version is out.

    Notable news:

    • dropped support for PHP 7.0 [a9cccdd]
    • fixed support for collection filtering of IPropertyContainters - now it's possible to fully support enums [4d1a2dc]
    • better support for composite primary keys [a0883a2], #290
    • added simple traversing support in fetchPairs() [0a6f7ca], #312
    • implemented "Did you mean...?" [15ef449]
    • added support for Nette 3 components
    • (BC break!) Collection filtering by id property accepts only direct values, no Entity itself [4d1a2dc]
    • (BC break!) changed IProperty interface and introduced IEntityAwareProperty [0c46be1]
    • (BC break!) IRepository::remove() accepts only already fetched entities, [a6458da]
    • (BC break!) DbalMapper::getManyHasManyParameters() was receiving the second parameter randomly, sometime it were the metadata of symetric relationship [5521b89]

    See full commit changelog.

    You may support Nextras Dbal & Orm development by attending Akademie42 training.

  • v3.0.3 3.0.3

    Stable patch version 3.0.3 is out! ๐Ÿ What's changed from 3.0.2?

    • fixed DILoader for anonymous classes & compatibility with latest Nette DI 2.5.14, thanks @pavelmlejnek (#333)

    See full commit changelog.

  • v3.0.2 3.0.2

    Stable patch version 3.0.2 is out! ๐ŸŒ What's changed from 3.0.1?

    • fixed casting numeric column names, thanks @vymak (#287)
    • fixed saving DateTimeImmutable for DATE type, not shifting timezone anymore, thanks @sitole
    • fixed phpdoc of doRefreshAll()
    • removed not-needed auto-distinct

    See full commit changelog.

  • v3.0.1 3.0.1

    Stable patch version 3.0.1 is out! ๐Ÿˆ What's changed from 3.0.0?

    • readded support for Nextras\Dbal\Utils\DateTimeImmutable property type
    • fixed EntityCreator support for DateTimeImmutable
    • fixed return value of Repository::removeAndFlush()
    • fixed dependency on Nextras Dbal to stable release

    See full commit changelog.

  • v3.0.0 3.0.0

    This is new major 3.0.0 version. ๐ŸŽ‰ ๐Ÿฐ ๐Ÿฅ‡ ๐Ÿ’ฏ

    Read a release blogpost.

    What's new:

    • PHP 7.0+ code; added types, support for PHP 7.2;
    • model: added IModel::clear() method;
    • model: added IModel::refreshAll() method;
    • collection: added OR operator support;
    • collection: added custom functions allowing advanced modification of ICollection;
    • entity: added DateTimeImmutable support;
    • entity: fixed a lot of issues between relationships, their caching, and persistence;
    • added MS SQL support;
    • dropped support for DateTime (BC break!);

    We have introduced many small and some larger BC breaks, read Upgrade notes for 3.0.

    See full commit changelog.

  • v3.0.0-rc2 3.0.0 RC2

    This is prerelease RC 2 of major 3.0.0 version.

    What's changed from RC1:

    • fixed auto-setup of DbalMapperCoordinator when Dbal extension is registered later than Orm extension

    See full commit changelog.

  • v3.0.0-rc1 3.0.0 RC1

    This is prerelease RC 1 of major 3.0.0 version.

    What's new from 2.2 branch:

    • PHP 7.0+ code; added types, fixed support for PHP 7.2;
    • model: added IModel::clear() method;
    • model: added IModel::refreshAll() method;
    • collection: added OR operator support;
    • collection: added custom functions allowing advanced modification of ICollection;
    • entity: added DateTimeImmutable support;
    • dropped support for DateTime (BC break!);
    • entity: fixed a lot of issues between relationships, their caching, and persistence;
    • added MS SQL support;

    We have introduced many small and some larger BC breaks, read Upgrade notes for 3.0.

    See full commit changelog.

  • v3.0.0-beta2 3.0.0 BETA 2

    See 3.0 changes in BETA 1 release notes.

    Changes since BETA 1:

    • require IConnection instead Connection
    • fixed multi-column primary key comparison in changed entity detection in has one relationship
    • fixed many typos and smalling with PhpStan 0.9
    • fixed distinct count for MS SQL Server
    • added ICollection::getById()
    • fixed loading DI services in loadConfiguraiton of Nette DIC
    • fixed countStored() on many has many relationship
    • fixed disctinct selection for multi-column PR tables
    • fixed parsing of read-only properties
    • changed implementation of DI repository finder
    • fixed STI in multientity interator
    • See full commit changelog since 3.0-BETA1 version.
  • v3.0.0-beta1 3.0.0 BETA 1

    This is prerelease BETA 1 of major 3.0.0 version.

    What's new from 2.2 branch:

    • PHP 7.0+ code; added typehints, fixed support for PHP 7.2;
    • model: added IModel::clear() method;
    • model: added IModel::refreshAll() method;
    • collection: added OR support & custom functions;
    • entity: added DateTimeImmutable support, dropped support for DateTime
    • entity: fixed a lot of issues between relationships, their caching, and perstitence.
    • engines: added MS SQL support;

    We have introduced many small and some larger BC breaks, read Upgrade notes for 3.0.

    See full commit changelog.

    How to install:

    • set require for 3.0 version od Nextras Dbal nextras/dbal@rc
    • set require for 3.0 version od Nextras Orm nextras/orm@beta
  • v2.2.3 2.2.3

    Stable patch version 2.2.3 is out! ๐Ÿฅ› What's changed from 2.2.2?

    • fixed bug when metadata parser didn't parsed enum with wildcard without a name prefix, e.g. ClassWithConstants::* now works correctly. [6e46e40]
  • v2.2.2 2.2.2

    Stable patch version 2.2.2 is out! ๐Ÿˆ What's changed from 2.2.1?

    • fixed bug when total cache cleanup didn't flush relationship mapper cache in DbalMapper; thanks @matej21 [0dd82ca]
  • v2.2.1 2.2.1

    Stable patch version 2.2.1 is out! ๐Ÿฅ What's changed from 2.2.0?

    • fixed bug when derived relationship would cause loading whole relationship during persist [b56a1a0]
    • fixed bug in null & date time comparison [eeff907]
  • v2.2.0 2.2.0

    Next minor version 2.2.0 is out! ๐ŸŒ What's changed from 2.1?

    • minimal PHP version changed to 5.6
    • added support for multi-column default ordering in relationship [915acb1]
    • many core changes & bugfixes; these changes are extensive therefore they are not pushed as patch version update;
    • see full commit changelog
  • v2.2.0-rc1 2.2.0-rc1

    RC of minor version 2.2.0 is out! ๐ŸŒ What's changed from 2.1?

    • added support for multi-column default ordering in relationship [915acb1]
    • many core changes & bugfixes; these changes are extensive therefore they are not pushed as patch version update; Please help us test it
    • see full commit changelog
  • v2.1.1 2.1.1

    Stable patch version 2.1.1 is out! ๐Ÿท What's changed from 2.0?

    • fixed bug of persisting entity with no changed properties
    • see full commit changelog
  • v2.1.0 2.1.0

    Stable minor version 2.1.0 is out! ๐Ÿ‡ What's changed from 2.0?

    • StorageReflection::addMapping() checks for redefinition, #174
    • many core changes & bugfixes; these changes are extensive therefore they are not pushed as patch version update;
    • see full commit changelog
bar-chart-fill

Statistics

download-cloud-fill
416818
star-fill
305
bug-fill
34
flashlight-fill
8d
price-tag-2-line

Badges

guide-fill

Dependencies

php (>=7.1)
nette/caching (~2.5 || ~3.0@rc)
nette/utils (~2.5 || ~3.0@rc)
nette/tokenizer (~2.3 || ~3.0@rc)
nextras/dbal (~3.0 || ~3.1@dev)
Componette Componette felix@nette.org