Something I've used in a few of my projects is additional behaviours for models. In Laravel 3, I write a basic soft-delete mechanism (back then it wasn't supported in Eloquent). This led to a behavioural system whereby developers could add behaviours for certain conditions (such as soft-delete, count caches and more).
I believe the time is now right to re-implement this behaviour for Eloquence (and Laravel 5). My first order of business would be a count cache.
Count caches in effect remove the need for joins on associated tables to count the records. A good example is a user hasMany posts - how many posts have they added?
I am wondering if anyone would be interested in just such behaviour as a part of Eloquence?
Something I've used in a few of my projects is additional behaviours for models. In Laravel 3, I write a basic soft-delete mechanism (back then it wasn't supported in Eloquent). This led to a behavioural system whereby developers could add behaviours for certain conditions (such as soft-delete, count caches and more).
I believe the time is now right to re-implement this behaviour for Eloquence (and Laravel 5). My first order of business would be a count cache.
Count caches in effect remove the need for joins on associated tables to count the records. A good example is a user hasMany posts - how many posts have they added?
I am wondering if anyone would be interested in just such behaviour as a part of Eloquence?
Let me know.