PreUpdate [orm] - TagMerge

PreUpdate [orm]

YoukeZhangAsked 4 months ago

Bug Report

Update releated object failed in PreUpdate

| Q | A |------------ | ------ | BC Break | yes/no | Version | 2.10.3

Summary

I try to change attrs of object B when PreUpdate trigger for object A.

Failed in fact.

How to reproduce

public function preUpdate(A $a, PreUpdateEventArgs $args) { if ($args->hasChangedField('status')) { $a->getB()->setName('xxx'); } }

Source: link

Recent Issues

    Programming Languages