stibiumz / phalcon.eager-loading

Solves N+1 query problem in Phalcon Model
The Unlicense
36 stars 24 forks source link

Added EagerResultset; Added {alias}_eager property #7

Open josefguenther opened 8 years ago

josefguenther commented 8 years ago

Changes on 5.3 branch ONLY. Consider porting to master.

Added EagerResultset to help identify and work with result array; now adds {alias}_eager property on models to help determine if results were eager loaded (without triggering a magic fetch)

dvmedvedev commented 8 years ago

Resultset needed in any case.

Surt commented 7 years ago

@josefguenther I was triying to do the opposite, to check in model if relationship was loaded, without calling the lazy loading. But there is no luck that way.

https://github.com/phalcon/incubator/pull/754