public function getQueryString()
    {
        $query = [];
        if (!empty($this->pagination)) {
            $query[self::PARAM_PAGINATION] = $this->pagination;
        }
        if (!empty($this->filters)) {
            $query[self::PARAM_FILTERING] = $this->filters;
        }
        foreach ($this->fields as $modelType => $fields) {
            $query[self::PARAM_FIELDSETS][$modelType] = implode(',', $fields);
        }
        $sort = [];
        foreach ($this->sorting as $key => $direction) {
            $sort[] = (1 === $direction) ? $key : sprintf('-%s', $key);
        }
        if (!empty($sort)) {
            $query[self::PARAM_SORTING] = implode(',', $sort);
        }
        return http_build_query($query);
    }