How to updateOwnPost on function in yii2-admin

I used yii2-admin. All roles and permissions added in browser. (/localhost/yiiproject/site/admin/)

Now my problem is how to add updateOwnPost. I allready read

I don’t have RbacController. Where i add under code.

$auth = Yii::$app->authManager;

        // add the rule

        $rule = new \app\rbac\AuthorRule;


        // add the "updateOwnPost" permission and associate the rule with it.

        $updateOwnPost = $auth->createPermission('updateOwnPost');

        $updateOwnPost->description = 'Update own post';

        $updateOwnPost->ruleName = $rule->name;


        // "updateOwnPost" will be used from "updatePost"

        $auth->addChild($updateOwnPost, $updatePost);

        // allow "author" to update their own posts

        $auth->addChild($author, $updateOwnPost);

Please reply and thanks.