Config/Misc
* hardcode sql limits within their respective components instead of having them configurable * creating a new DBTypeList defaults it to being unlimited * SQL_LIMIT_NONE (0) > removed as it only existed for consistency * SQL_LIMIT_DEFAULT (300) > frontend / Listview::DEFAULT_SIZE * SQL_LIMIT_SEARCH (500) > Search::DEFAULT_MAX_RESULTS * SQL_LIMIT_QUICKSEARCH (10) > Search::SUGGESTIONS_MAX_RESULTS
This commit is contained in:
parent
b9d888ab3a
commit
c44bf4f575
69 changed files with 183 additions and 219 deletions
|
|
@ -48,7 +48,7 @@ class ObjectsBaseResponse extends TemplateResponse implements ICache
|
|||
{
|
||||
$this->h1 = Util::ucFirst(Lang::game('objects'));
|
||||
|
||||
$conditions = [];
|
||||
$conditions = [Listview::DEFAULT_SIZE];
|
||||
if (!User::isInGroup(U_GROUP_EMPLOYEE))
|
||||
$conditions[] = [['cuFlags', CUSTOM_EXCLUDE_FOR_LISTVIEW, '&'], 0];
|
||||
|
||||
|
|
@ -93,9 +93,9 @@ class ObjectsBaseResponse extends TemplateResponse implements ICache
|
|||
$tabData['visibleCols'] = ['skill'];
|
||||
|
||||
// create note if search limit was exceeded
|
||||
if ($objects->getMatches() > Cfg::get('SQL_LIMIT_DEFAULT'))
|
||||
if ($objects->getMatches() > Listview::DEFAULT_SIZE)
|
||||
{
|
||||
$tabData['note'] = sprintf(Util::$tryFilteringString, 'LANG.lvnote_objectsfound', $objects->getMatches(), Cfg::get('SQL_LIMIT_DEFAULT'));
|
||||
$tabData['note'] = sprintf(Util::$tryFilteringString, 'LANG.lvnote_objectsfound', $objects->getMatches(), Listview::DEFAULT_SIZE);
|
||||
$tabData['_truncated'] = 1;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue