issues
search
yiisoft
/
active-record
Active Record database abstraction layer
https://www.yiiframework.com/
BSD 3-Clause "New" or "Revised" License
68
stars
28
forks
source link
Allow pre- and post-processing values
#363
Open
Tigrov
opened
3 months ago
Tigrov
commented
3 months ago
Allow processing events
After read
Before insert
After insert
Before update
After update
Before save (before insert or update)
After save (after insert or update)
Before delete
After delete
Could be realized as a
trait
samdark
commented
3 months ago
It could be done in two ways:
Overriding methods as in Yii2. This is alright, but there will be conflicts when multiple traits are used.
Events is a better way since you can add multiple behaviors simultaneously and, also, can handle these outside of the AR itself.
Allow processing events
Could be realized as a
trait