Welcome Guest, Not a member yet? Register   Sign In
A check if model has anything to update
#10

(This post was last modified: 04-19-2022, 03:35 AM by kenjis.)

I don't agree with the way of the user guide.
I think It is bad practice. I think you should fill only database fields.

But the description seems to be correct.

In your case, $allowedFields has only name, and name is not changed.
So there is no data to update, so stray fields are not saved.
Reply


Messages In This Thread
RE: A check if model has anything to update - by kenjis - 04-19-2022, 03:29 AM



Theme © iAndrew 2016 - Forum software by © MyBB