set max number of item in sequence chooser to 200, make it a chzn-select menu

This commit is contained in:
Uwe Steinmann 2024-04-18 19:23:47 +02:00
parent c3bd028774
commit d96cae4864
2 changed files with 6 additions and 6 deletions

View File

@ -1638,11 +1638,11 @@ $(document).ready(function() {
function getSequenceChooser($parent, $type, $keepID = -1) { /* {{{ */
$objArr = [];
if($type == 'd') {
if(($c = $parent->hasDocuments()) < 50)
if(($c = $parent->hasDocuments()) < 200)
$objArr = $parent->getDocuments('s');
$minmax = $parent->getDocumentsMinMax();
} elseif($type = 'f') {
if(($c = $parent->hasSubFolders()) < 50)
if(($c = $parent->hasSubFolders()) < 200)
$objArr = $parent->getSubFolders('s');
$minmax = $parent->getFoldersMinMax();
} else
@ -1656,7 +1656,7 @@ $(document).ready(function() {
$min = (float) $minmax['min'];
$max = $minmax['max']+1.0;
}
$content = "<select name=\"sequence\">\n";
$content = "<select class=\"chzn-select\" name=\"sequence\">\n";
if ($keepID != -1) {
$content .= " <option value=\"keep\">" . getMLText("seq_keep");
}

View File

@ -1648,11 +1648,11 @@ $(document).ready(function() {
function getSequenceChooser($parent, $type, $keepID = -1) { /* {{{ */
$objArr = [];
if($type == 'd') {
if(($c = $parent->hasDocuments()) < 50)
if(($c = $parent->hasDocuments()) < 200)
$objArr = $parent->getDocuments('s');
$minmax = $parent->getDocumentsMinMax();
} elseif($type = 'f') {
if(($c = $parent->hasSubFolders()) < 50)
if(($c = $parent->hasSubFolders()) < 200)
$objArr = $parent->getSubFolders('s');
$minmax = $parent->getFoldersMinMax();
} else
@ -1666,7 +1666,7 @@ $(document).ready(function() {
$min = (float) $minmax['min'];
$max = $minmax['max']+1.0;
}
$content = "<select class=\"form-control\" name=\"sequence\">\n";
$content = "<select class=\"form-control chzn-select\" data-allow-clear=\"false\" name=\"sequence\">\n";
if ($keepID != -1) {
$content .= " <option value=\"keep\">" . getMLText("seq_keep");
}