I have model "Contact" which hasMany "Address". When saving the Contact with a new Address
...
//$contact = some instance of Contact
$contact->addresses()->save(new Address(['street' => '4811 Example Dr.']));
dd($contact->getChanges()); // returns null
// dd($contact->addresses()->getChanges()); // method not available
// dd($contact->addresses->getChanges()); // method not available
How can I check which changes were actually made after the save call?
from Newest questions tagged laravel-5 - Stack Overflow https://ift.tt/2E1MkP6
via IFTTT
Aucun commentaire:
Enregistrer un commentaire