public function getPermissionIdFromName($perm_name)
    {
        $permission = static::$app['db']->connection()
            ->table('permissions')->where('name', '=', $perm_name)->first();

        return $permission->id;
    }