Commit 6970f42e authored by Filipa Lacerda's avatar Filipa Lacerda

Renders pagination again for pipelines table

parent 0aaf22de
...@@ -50,10 +50,13 @@ const CommitPipelinesStoreWithTimeAgo = require('../commit/pipelines/pipelines_s ...@@ -50,10 +50,13 @@ const CommitPipelinesStoreWithTimeAgo = require('../commit/pipelines/pipelines_s
* *
* If no scope is provided, 'all' is assumed. * If no scope is provided, 'all' is assumed.
* *
* Pagination component sends "null" when no scope is provided.
*
* @param {Number} pagenum * @param {Number} pagenum
* @param {String} apiScope = 'all' * @param {String} apiScope = 'all'
*/ */
change(pagenum, apiScope = 'all') { change(pagenum, apiScope) {
if (!apiScope) apiScope = 'all';
gl.utils.visitUrl(`?scope=${apiScope}&p=${pagenum}`); gl.utils.visitUrl(`?scope=${apiScope}&p=${pagenum}`);
}, },
}, },
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
((gl) => { ((gl) => {
const pageValues = (headers) => { const pageValues = (headers) => {
const normalized = gl.utils.normalizeHeaders(headers); const normalized = gl.utils.normalizeHeaders(headers);
const paginationInfo = gl.utils.normalizeHeaders(normalized); const paginationInfo = gl.utils.parseIntPagination(normalized);
return paginationInfo; return paginationInfo;
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment