app\models\Permission::isDeletable PHP 메소드

isDeletable() 공개 메소드

public isDeletable ( ) : boolean
리턴 boolean
    public function isDeletable()
    {
        // Protect the guest-only, basic-authenticated and open-to-all permissions from deletion.
        if ('guest-only' == $this->name || 'basic-authenticated' == $this->name || 'open-to-all' == $this->name || $this->is_used) {
            return false;
        }
        // Otherwise
        return true;
    }