2

I figured this while posting so I thought I'd just add it here anyway for others to reference. To retrieve a Soft Deleted Element using the getElementById method you can pass the fourth argument to the getElementById method and define $criteria setting trashed to true, which will include Soft Deleted items in your results: $element = Craft::$app->...


1

You need to check if the normal user has an administrate permission, you can check at user -> permission. Even a normal user you still can give it an administrate user permission without change it into a admin user, but this permission is off by default for normal user.


1

Yo, read the docs. He says to himself quietly, having not visited the plugin docs in a while.


Only top voted, non community-wiki answers of a minimum length are eligible