mirror of
https://github.com/wekan/wekan.git
synced 2026-02-25 01:14:06 +01:00
Add environment variable and snap configuration option for results per page
This commit is contained in:
parent
0ebb427a00
commit
9e8399612b
2 changed files with 10 additions and 1 deletions
|
|
@ -461,6 +461,11 @@ function buildProjection(query) {
|
|||
skip = query.params.skip;
|
||||
}
|
||||
let limit = DEFAULT_LIMIT;
|
||||
const configLimit = parseInt(process.env.RESULTS_PER_PAGE, 10);
|
||||
if (!isNaN(configLimit) && configLimit > 0) {
|
||||
limit = configLimit;
|
||||
}
|
||||
|
||||
if (query.params.hasOperator(OPERATOR_LIMIT)) {
|
||||
limit = query.params.getPredicate(OPERATOR_LIMIT);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue