You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
on this update : $this->subscriptions()->update(['is_active' => false]); the subscribed_at column also get affected with current timestamp.
And the table column after migration looks as below.
But after changing the subscribed_at as nullable in migration it's working as expected. Still, have a question why is the column being affected on every update?
Did I miss anything?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I have created a customized subscription model (not Laravel Cashier).
the Migration as below
and the user model (User.php) relations and methods connected to subscriptions as below
on this update :

$this->subscriptions()->update(['is_active' => false]);
the subscribed_at column also get affected with current timestamp.And the table column after migration looks as below.
But after changing the subscribed_at as nullable in migration it's working as expected. Still, have a question why is the column being affected on every update?
Did I miss anything?
Beta Was this translation helpful? Give feedback.
All reactions