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
@mvz thanks for your hints.
Yes, I do know with_deleted.
However, it is metaprogramming, what instance/model/ruby code passed is out of my control. The model may or may not enable acts_as_paranoid. But as you mentioned, whatever passed to the method, must be with_deleted actually.
After defining
acts_as_paranoid
for models, it will add default_scopenot_deleted
for the model.Now, we have such a strange req., within one particular method, we hope to ignore
acts_as_paranoid
defaultnot_deleted
scope.Also, we don't know what model/instance will be passed to this method since we are using metaprogramming for this method.
We do have a req, please ignore
acts_as_paranoid
in this method :)I know it is very strange. Is it doable?
The text was updated successfully, but these errors were encountered: