mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-03-11 16:35:38 +00:00
reoganize database search form, don't show results without a search criteria
This commit is contained in:
parent
f5af648b37
commit
b6f60e8c7f
|
@ -623,12 +623,11 @@ class SeedDMS_Core_DMS {
|
|||
foreach($attributes as $attrdefid=>$attribute) {
|
||||
if($attribute) {
|
||||
$attrdef = $this->getAttributeDefinition($attrdefid);
|
||||
if($attrdef->getObjType() == SeedDMS_Core_AttributeDefinition::objtype_document) {
|
||||
if($attrdef->getObjType() == SeedDMS_Core_AttributeDefinition::objtype_folder) {
|
||||
if($attrdef->getValueSet())
|
||||
$searchAttributes[] = "`tblFolderAttributes`.`attrdef`=".$attrdefid." AND `tblFolderAttributes`.`value`='".$attribute."'";
|
||||
else
|
||||
$searchAttributes[] = "`tblFolderAttributes`.`attrdef`=".$attrdefid." AND `tblFolderAttributes`.`value` like '%".$attribute."%'";
|
||||
} elseif($attrdef->getObjType() == SeedDMS_Core_AttributeDefinition::objtype_documentcontent) {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -665,11 +664,14 @@ class SeedDMS_Core_DMS {
|
|||
if (strlen($searchCreateDate)>0) {
|
||||
$searchQuery .= " AND (".$searchCreateDate.")";
|
||||
}
|
||||
if ($searchAttributes) {
|
||||
$searchQuery .= " AND (".implode(" AND ", $searchAttributes).")";
|
||||
}
|
||||
|
||||
/* Do not search for folders if not at least a search for a key,
|
||||
* an owner, or creation date is requested.
|
||||
*/
|
||||
if($searchKey || $searchOwner || $searchCreateDate) {
|
||||
if($searchKey || $searchOwner || $searchCreateDate || $searchAttributes) {
|
||||
// Count the number of rows that the search will produce.
|
||||
$resArr = $this->db->getResultArray("SELECT COUNT(*) AS num ".$searchQuery);
|
||||
if ($resArr && isset($resArr[0]) && is_numeric($resArr[0]["num"]) && $resArr[0]["num"]>0) {
|
||||
|
@ -895,6 +897,7 @@ class SeedDMS_Core_DMS {
|
|||
$searchQuery .= " AND `tblDocumentStatusLog`.`status` IN (".implode(',', $status).")";
|
||||
}
|
||||
|
||||
if($searchKey || $searchOwner || $searchCategories || $searchCreateDate || $searchExpirationDate || $searchAttributes || $status) {
|
||||
// Count the number of rows that the search will produce.
|
||||
$resArr = $this->db->getResultArray("SELECT COUNT(*) AS num FROM (SELECT DISTINCT `tblDocuments`.id ".$searchQuery.") a");
|
||||
$totalDocs = 0;
|
||||
|
@ -946,6 +949,9 @@ class SeedDMS_Core_DMS {
|
|||
} else {
|
||||
$docresult = array('totalDocs'=>0, 'docs'=>array());
|
||||
}
|
||||
} else {
|
||||
$docresult = array('totalDocs'=>0, 'docs'=>array());
|
||||
}
|
||||
|
||||
if($limit) {
|
||||
$totalPages = (integer)(($totalDocs+$totalFolders)/$limit);
|
||||
|
@ -1500,7 +1506,7 @@ class SeedDMS_Core_DMS {
|
|||
* @return array array of notifications
|
||||
*/
|
||||
function getNotificationsByUser($user, $type=0) { /* {{{ */
|
||||
$queryStr = "SELECT `tblNotify`.* FROM `tblNotify` ".
|
||||
$queryStr = "SELECT `tblNotify`.* FROM `tblNotify` ".
|
||||
"WHERE `tblNotify`.`userID` = ". $user->getID();
|
||||
if($type) {
|
||||
$queryStr .= " AND `tblNotify`.`targetType` = ". (int) $type;
|
||||
|
|
|
@ -349,6 +349,8 @@ URL: [url]',
|
|||
'files_deletion' => 'مسح الملف',
|
||||
'files_deletion_warning' => 'من خلال تلك الخاصية يمكنك مسح كل الملفات على مجلدات النظام. ملفات معلومات الاصدارات فقط ستظل متاحة للرؤية.',
|
||||
'file_size' => 'حجم الملف',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => 'مجلد',
|
||||
'folders' => 'مجلدات',
|
||||
'folders_and_documents_statistic' => 'رؤية عامة للمحتوى',
|
||||
|
|
|
@ -300,6 +300,8 @@ $text = array(
|
|||
'files_deletion' => 'Eliminació de fitxers',
|
||||
'files_deletion_warning' => 'Amb aquesta opció es poden eliminar tots els fitxers del DMS complet. La informació de versionat romandrà visible.',
|
||||
'file_size' => 'Mida',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => 'Carpeta',
|
||||
'folders' => 'Carpetes',
|
||||
'folders_and_documents_statistic' => 'Vista general de continguts',
|
||||
|
|
|
@ -356,6 +356,8 @@ URL: [url]',
|
|||
'files_deletion' => 'Soubor odstraněn',
|
||||
'files_deletion_warning' => 'Pomocí této volby můžete odstranit všechny soubory z celé složky DMS. Verzovací informace zůstanou viditelné.',
|
||||
'file_size' => 'Velikost souboru',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => 'Složka',
|
||||
'folders' => 'Složky',
|
||||
'folders_and_documents_statistic' => 'Přehled složek a dokumentů',
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
// along with this program; if not, write to the Free Software
|
||||
// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
//
|
||||
// Translators: Admin (1904)
|
||||
// Translators: Admin (1906)
|
||||
|
||||
$text = array(
|
||||
'accept' => 'Übernehmen',
|
||||
|
@ -356,6 +356,8 @@ URL: [url]',
|
|||
'files_deletion' => 'Dateien löschen',
|
||||
'files_deletion_warning' => 'Durch diese Operation können Sie Dokumente des DMS löschen. Die Versions-Information bleibt erhalten.',
|
||||
'file_size' => 'Dateigröße',
|
||||
'filter_for_documents' => 'Zusätzliche Filter für Dokumente',
|
||||
'filter_for_folders' => 'Zusätzliche Filter für Ordner',
|
||||
'folder' => 'Ordner',
|
||||
'folders' => 'Verzeichnisse',
|
||||
'folders_and_documents_statistic' => 'Ordner- und Dokumentenübersicht',
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
// along with this program; if not, write to the Free Software
|
||||
// Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
//
|
||||
// Translators: Admin (1044), netixw (14)
|
||||
// Translators: Admin (1046), netixw (14)
|
||||
|
||||
$text = array(
|
||||
'accept' => 'Accept',
|
||||
|
@ -356,6 +356,8 @@ URL: [url]',
|
|||
'files_deletion' => 'Files deletion',
|
||||
'files_deletion_warning' => 'With this option you can delete all files of entire DMS folders. The versioning information will remain visible.',
|
||||
'file_size' => 'Filesize',
|
||||
'filter_for_documents' => 'Additional filter for documents',
|
||||
'filter_for_folders' => 'Additional filter for folders',
|
||||
'folder' => 'Folder',
|
||||
'folders' => 'Folders',
|
||||
'folders_and_documents_statistic' => 'Contents overview',
|
||||
|
|
|
@ -356,6 +356,8 @@ URL: [url]',
|
|||
'files_deletion' => 'Eliminación de ficheros',
|
||||
'files_deletion_warning' => 'Con esta opción se puede eliminar todos los ficheros del DMS completo. La información de versionado permanecerá visible.',
|
||||
'file_size' => 'Tamaño',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => 'Carpeta',
|
||||
'folders' => 'Carpetas',
|
||||
'folders_and_documents_statistic' => 'Vista general de contenidos',
|
||||
|
|
|
@ -349,6 +349,8 @@ URL: [url]',
|
|||
'files_deletion' => 'Suppression de fichiers',
|
||||
'files_deletion_warning' => 'Avec cette option, vous pouvez supprimer tous les fichiers d\'un dossier DMS. Les informations de version resteront visibles.',
|
||||
'file_size' => 'Taille',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => 'Dossier',
|
||||
'folders' => 'Dossiers',
|
||||
'folders_and_documents_statistic' => 'Aperçu du contenu',
|
||||
|
|
|
@ -356,6 +356,8 @@ URL: [url]',
|
|||
'files_deletion' => 'Állományok törlése',
|
||||
'files_deletion_warning' => 'Ezzel az opcióval törölheti az összes állományt valamennyi DMS mappában. A változási információk láthatók maradnak.',
|
||||
'file_size' => 'Állomány méret',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => 'Mappa',
|
||||
'folders' => 'Mappák',
|
||||
'folders_and_documents_statistic' => 'Tartalmak áttekintése',
|
||||
|
|
|
@ -300,6 +300,8 @@ $text = array(
|
|||
'files_deletion' => 'Cancellazione file',
|
||||
'files_deletion_warning' => 'Con questa operazione è possible cancellare i file di intere cartelle. Dopo la cancellazione le informazioni di versionamento resteranno disponibili.',
|
||||
'file_size' => 'Grandezza',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => 'Cartella',
|
||||
'folders' => 'Cartelle',
|
||||
'folders_and_documents_statistic' => 'Visualizzazione generale',
|
||||
|
|
|
@ -349,6 +349,8 @@ URL: [url]',
|
|||
'files_deletion' => 'Bestanden verwijderen',
|
||||
'files_deletion_warning' => 'Met deze handeling verwijdert U ALLE bestanden uit het DMS. Versie informatie blijft beschikbaar',
|
||||
'file_size' => 'Bestandsomvang',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => 'Map',
|
||||
'folders' => 'Mappen',
|
||||
'folders_and_documents_statistic' => 'Inhoudsopgave',
|
||||
|
|
|
@ -349,6 +349,8 @@ URL: [url]',
|
|||
'files_deletion' => 'Usuwanie plików',
|
||||
'files_deletion_warning' => 'Ta operacja pozwala usunąć wszystkie pliki z repozytorium. Informacje o wersjonowaniu pozostaną widoczne.',
|
||||
'file_size' => 'Rozmiar pliku',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => 'Folder',
|
||||
'folders' => 'Foldery',
|
||||
'folders_and_documents_statistic' => 'Podsumowanie zawartości',
|
||||
|
|
|
@ -355,6 +355,8 @@ URL: [url]',
|
|||
'files_deletion' => 'Arquivos deletados',
|
||||
'files_deletion_warning' => 'With this option you can delete all files of entire DMS folders. The versioning information will remain visible.',
|
||||
'file_size' => 'Tamanho',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => 'Pasta',
|
||||
'folders' => 'Pastas',
|
||||
'folders_and_documents_statistic' => 'Relatórios de pastas e documentos',
|
||||
|
|
|
@ -349,6 +349,8 @@ URL: [url]',
|
|||
'files_deletion' => 'Удалить файлы',
|
||||
'files_deletion_warning' => 'Эта операция удалит все файлы во всех каталогах. Информация о версиях останется доступна',
|
||||
'file_size' => 'Размер',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => 'Каталог',
|
||||
'folders' => 'кат.',
|
||||
'folders_and_documents_statistic' => 'Обзор содержимого',
|
||||
|
|
|
@ -300,6 +300,8 @@ $text = array(
|
|||
'files_deletion' => 'Odstránenie súboru',
|
||||
'files_deletion_warning' => 'Touto akciou môžete odstrániť celú DMS zložku. Verziovacie informácie zostanú viditeľné.',
|
||||
'file_size' => 'Veľkosť súboru',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => 'Zlozka',
|
||||
'folders' => 'Zložky',
|
||||
'folders_and_documents_statistic' => 'Prehľad zložiek a dokumentov',
|
||||
|
|
|
@ -349,6 +349,8 @@ URL: [url]',
|
|||
'files_deletion' => 'Ta bort alla filer',
|
||||
'files_deletion_warning' => 'Med detta alternativ kan du ta bort alla filer i en dokumentkatalog. Versionsinformationen kommer fortfarande att visas.',
|
||||
'file_size' => 'Filstorlek',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => 'Katalog',
|
||||
'folders' => 'Kataloger',
|
||||
'folders_and_documents_statistic' => 'Innehållsöversikt',
|
||||
|
|
|
@ -304,6 +304,8 @@ URL: [url]',
|
|||
'files_deletion' => '删除文件',
|
||||
'files_deletion_warning' => '通过此操作,您可以删除整个DMS(文档管理系统)文件夹里的所有文件.但版本信息将被保留',
|
||||
'file_size' => '文件大小',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => '文件夹',
|
||||
'folders' => '文件夹',
|
||||
'folders_and_documents_statistic' => '内容概要',
|
||||
|
|
|
@ -300,6 +300,8 @@ $text = array(
|
|||
'files_deletion' => '',
|
||||
'files_deletion_warning' => '',
|
||||
'file_size' => '',
|
||||
'filter_for_documents' => '',
|
||||
'filter_for_folders' => '',
|
||||
'folder' => '',
|
||||
'folders' => '',
|
||||
'folders_and_documents_statistic' => '',
|
||||
|
|
|
@ -436,7 +436,7 @@ if(count($entries) == 1 && ($resArr['totalDocs'] + $resArr['totalFolders']) == 1
|
|||
$view->setParam('status', isset($status) ? $status : array());
|
||||
$view->setParam('categories', isset($categories) ? $categories : '');
|
||||
$view->setParam('attributes', isset($attributes) ? $attributes : '');
|
||||
$attrdefs = $dms->getAllAttributeDefinitions(array(SeedDMS_Core_AttributeDefinition::objtype_document, SeedDMS_Core_AttributeDefinition::objtype_documentcontent/*, SeedDMS_Core_AttributeDefinition::objtype_all*/));
|
||||
$attrdefs = $dms->getAllAttributeDefinitions(array(SeedDMS_Core_AttributeDefinition::objtype_document, SeedDMS_Core_AttributeDefinition::objtype_documentcontent, SeedDMS_Core_AttributeDefinition::objtype_folder/*, SeedDMS_Core_AttributeDefinition::objtype_all*/));
|
||||
$view->setParam('attrdefs', $attrdefs);
|
||||
$allCats = $dms->getDocumentCategories();
|
||||
$view->setParam('allcategories', $allCats);
|
||||
|
|
|
@ -100,11 +100,11 @@ class SeedDMS_View_Search extends SeedDMS_Bootstrap_Style {
|
|||
</ul>
|
||||
<div class="tab-content">
|
||||
<div class="tab-pane <?php echo ($fullsearch == false) ? 'active' : ''; ?>" id="database">
|
||||
<form action="../op/op.Search.php" name="form1" onsubmit="return checkForm();">
|
||||
<?php
|
||||
// Database search Form {{{
|
||||
$this->contentContainerStart();
|
||||
?>
|
||||
<form action="../op/op.Search.php" name="form1" onsubmit="return checkForm();">
|
||||
<table class="table-condensed">
|
||||
<tr>
|
||||
<td><?php printMLText("search_query");?>:</td>
|
||||
|
@ -125,51 +125,6 @@ class SeedDMS_View_Search extends SeedDMS_Bootstrap_Style {
|
|||
<label class="checkbox" for="attributes"><input type="checkbox" name="searchin[]" id="attributes" value="4" <?php if(in_array('4', $searchin)) echo " checked"; ?>><?php printMLText("attributes");?></label>
|
||||
</td>
|
||||
</tr>
|
||||
<?php
|
||||
if($attrdefs) {
|
||||
foreach($attrdefs as $attrdef) {
|
||||
?>
|
||||
<tr>
|
||||
<td><?php echo htmlspecialchars($attrdef->getName()); ?></td>
|
||||
<td><?php $this->printAttributeEditField($attrdef, isset($attributes[$attrdef->getID()]) ? $attributes[$attrdef->getID()] : '') ?></td>
|
||||
</tr>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
?>
|
||||
<tr>
|
||||
<td><?php printMLText("category");?>:<br />(<?php printMLText('documents_only'); ?>)</td>
|
||||
<td>
|
||||
<select class="chzn-select" name="categoryids[]" multiple="multiple" data-placeholder="<?php printMLText('select_category'); ?>" data-no_results_text="<?php printMLText('unknown_document_category'); ?>">
|
||||
<!--
|
||||
<option value="-1"><?php printMLText("all_categories");?>
|
||||
-->
|
||||
<?php
|
||||
$tmpcatids = array();
|
||||
foreach($categories as $tmpcat)
|
||||
$tmpcatids[] = $tmpcat->getID();
|
||||
foreach ($allCats as $catObj) {
|
||||
print "<option value=\"".$catObj->getID()."\" ".(in_array($catObj->getID(), $tmpcatids) ? "selected" : "").">" . htmlspecialchars($catObj->getName()) . "\n";
|
||||
}
|
||||
?>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php printMLText("status");?>:<br />(<?php printMLText('documents_only'); ?>)</td>
|
||||
<td>
|
||||
<?php if($workflowmode == 'traditional') { ?>
|
||||
<label class="checkbox" for='pendingReview'><input type="checkbox" id="pendingReview" name="pendingReview" value="1" <?php echo in_array(S_DRAFT_REV, $status) ? "checked" : ""; ?>><?php printOverallStatusText(S_DRAFT_REV);?></label>
|
||||
<label class="checkbox" for='pendingApproval'><input type="checkbox" id="pendingApproval" name="pendingApproval" value="1" <?php echo in_array(S_DRAFT_APP, $status) ? "checked" : ""; ?>><?php printOverallStatusText(S_DRAFT_APP);?></label>
|
||||
<?php } else { ?>
|
||||
<label class="checkbox" for='inWorkflow'><input type="checkbox" id="inWorkflow" name="inWorkflow" value="1" <?php echo in_array(S_IN_WORKFLOW, $status) ? "checked" : ""; ?>><?php printOverallStatusText(S_IN_WORKFLOW);?></label>
|
||||
<?php } ?>
|
||||
<label class="checkbox" for='released'><input type="checkbox" id="released" name="released" value="1" <?php echo in_array(S_RELEASED, $status) ? "checked" : ""; ?>><?php printOverallStatusText(S_RELEASED);?></label>
|
||||
<label class="checkbox" for='rejected'><input type="checkbox" id="rejected" name="rejected" value="1" <?php echo in_array(S_REJECTED, $status) ? "checked" : ""; ?>><?php printOverallStatusText(S_REJECTED);?></label>
|
||||
<label class="checkbox" for='obsolete'><input type="checkbox" id="obsolete" name="obsolete" value="1" <?php echo in_array(S_OBSOLETE, $status) ? "checked" : ""; ?>><?php printOverallStatusText(S_OBSOLETE);?></label>
|
||||
<label class="checkbox" for='expired'><input type="checkbox" id="expired" name="expired" value="1" <?php echo in_array(S_EXPIRED, $status) ? "checked" : ""; ?>><?php printOverallStatusText(S_EXPIRED);?></label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php printMLText("owner");?>:</td>
|
||||
<td>
|
||||
|
@ -207,7 +162,79 @@ class SeedDMS_View_Search extends SeedDMS_Bootstrap_Style {
|
|||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php printMLText("expires");?>:<br />(<?php printMLText('documents_only'); ?>)</td>
|
||||
<td></td><td><button type="submit" class="btn"><i class="icon-search"></i> <?php printMLText("search"); ?></button></td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
<?php
|
||||
$this->contentContainerEnd();
|
||||
// }}}
|
||||
|
||||
/* First check if any of the folder filters are set. If it is,
|
||||
* open the accordion.
|
||||
*/
|
||||
$openfilterdlg = false;
|
||||
if($attrdefs) {
|
||||
foreach($attrdefs as $attrdef) {
|
||||
$attricon = '';
|
||||
if($attrdef->getObjType() == SeedDMS_Core_AttributeDefinition::objtype_document || $attrdef->getObjType() == SeedDMS_Core_AttributeDefinition::objtype_documentcontent) {
|
||||
if(!empty($attributes[$attrdef->getID()]))
|
||||
$openfilterdlg = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
if($categories)
|
||||
$openfilterdlg = true;
|
||||
if($status)
|
||||
$openfilterdlg = true;
|
||||
if($expirationdate)
|
||||
$openfilterdlg = true;
|
||||
?>
|
||||
<div class="accordion" id="accordion2">
|
||||
<div class="accordion-group">
|
||||
<div class="accordion-heading">
|
||||
<a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapseOne">
|
||||
<?php printMLText('filter_for_documents'); ?>
|
||||
</a>
|
||||
</div>
|
||||
<div id="collapseOne" class="accordion-body <?php if(!$openfilterdlg) echo "collapse";?>" style="_height: 0px;">
|
||||
<div class="accordion-inner">
|
||||
<table class="table-condensed">
|
||||
<tr>
|
||||
<td><?php printMLText("category");?>:</td>
|
||||
<td>
|
||||
<select class="chzn-select" name="categoryids[]" multiple="multiple" data-placeholder="<?php printMLText('select_category'); ?>" data-no_results_text="<?php printMLText('unknown_document_category'); ?>">
|
||||
<!--
|
||||
<option value="-1"><?php printMLText("all_categories");?>
|
||||
-->
|
||||
<?php
|
||||
$tmpcatids = array();
|
||||
foreach($categories as $tmpcat)
|
||||
$tmpcatids[] = $tmpcat->getID();
|
||||
foreach ($allCats as $catObj) {
|
||||
print "<option value=\"".$catObj->getID()."\" ".(in_array($catObj->getID(), $tmpcatids) ? "selected" : "").">" . htmlspecialchars($catObj->getName()) . "\n";
|
||||
}
|
||||
?>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php printMLText("status");?>:</td>
|
||||
<td>
|
||||
<?php if($workflowmode == 'traditional') { ?>
|
||||
<label class="checkbox" for='pendingReview'><input type="checkbox" id="pendingReview" name="pendingReview" value="1" <?php echo in_array(S_DRAFT_REV, $status) ? "checked" : ""; ?>><?php printOverallStatusText(S_DRAFT_REV);?></label>
|
||||
<label class="checkbox" for='pendingApproval'><input type="checkbox" id="pendingApproval" name="pendingApproval" value="1" <?php echo in_array(S_DRAFT_APP, $status) ? "checked" : ""; ?>><?php printOverallStatusText(S_DRAFT_APP);?></label>
|
||||
<?php } else { ?>
|
||||
<label class="checkbox" for='inWorkflow'><input type="checkbox" id="inWorkflow" name="inWorkflow" value="1" <?php echo in_array(S_IN_WORKFLOW, $status) ? "checked" : ""; ?>><?php printOverallStatusText(S_IN_WORKFLOW);?></label>
|
||||
<?php } ?>
|
||||
<label class="checkbox" for='released'><input type="checkbox" id="released" name="released" value="1" <?php echo in_array(S_RELEASED, $status) ? "checked" : ""; ?>><?php printOverallStatusText(S_RELEASED);?></label>
|
||||
<label class="checkbox" for='rejected'><input type="checkbox" id="rejected" name="rejected" value="1" <?php echo in_array(S_REJECTED, $status) ? "checked" : ""; ?>><?php printOverallStatusText(S_REJECTED);?></label>
|
||||
<label class="checkbox" for='obsolete'><input type="checkbox" id="obsolete" name="obsolete" value="1" <?php echo in_array(S_OBSOLETE, $status) ? "checked" : ""; ?>><?php printOverallStatusText(S_OBSOLETE);?></label>
|
||||
<label class="checkbox" for='expired'><input type="checkbox" id="expired" name="expired" value="1" <?php echo in_array(S_EXPIRED, $status) ? "checked" : ""; ?>><?php printOverallStatusText(S_EXPIRED);?></label>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php printMLText("expires");?>:</td>
|
||||
<td>
|
||||
<label class="checkbox inline">
|
||||
<input type="checkbox" name="expirationdate" value="true" <?php if($expirationdate) echo "checked"; ?>/><?php printMLText("between");?>
|
||||
|
@ -223,16 +250,73 @@ class SeedDMS_View_Search extends SeedDMS_Bootstrap_Style {
|
|||
</span>
|
||||
</td>
|
||||
</tr>
|
||||
<?php
|
||||
if($attrdefs) {
|
||||
foreach($attrdefs as $attrdef) {
|
||||
$attricon = '';
|
||||
if($attrdef->getObjType() == SeedDMS_Core_AttributeDefinition::objtype_document || $attrdef->getObjType() == SeedDMS_Core_AttributeDefinition::objtype_documentcontent) {
|
||||
?>
|
||||
<tr>
|
||||
<td></td><td><button type="submit" class="btn"><i class="icon-search"></i> <?php printMLText("search"); ?></button></td>
|
||||
<td><?php echo htmlspecialchars($attrdef->getName()); ?>:</td>
|
||||
<td><?php $this->printAttributeEditField($attrdef, isset($attributes[$attrdef->getID()]) ? $attributes[$attrdef->getID()] : '') ?></td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
</form>
|
||||
<?php
|
||||
$this->contentContainerEnd();
|
||||
// }}}
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php
|
||||
/* First check if any of the folder filters are set. If it is,
|
||||
* open the accordion.
|
||||
*/
|
||||
$openfilterdlg = false;
|
||||
if($attrdefs) {
|
||||
foreach($attrdefs as $attrdef) {
|
||||
$attricon = '';
|
||||
if($attrdef->getObjType() == SeedDMS_Core_AttributeDefinition::objtype_folder) {
|
||||
if(!empty($attributes[$attrdef->getID()]))
|
||||
$openfilterdlg = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
<div class="accordion" id="accordion3">
|
||||
<div class="accordion-group">
|
||||
<div class="accordion-heading">
|
||||
<a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion3" href="#collapseFolder">
|
||||
<?php printMLText('filter_for_folders'); ?>
|
||||
</a>
|
||||
</div>
|
||||
<div id="collapseFolder" class="accordion-body <?php if(!$openfilterdlg) echo "collapse";?>" style="_height: 0px;">
|
||||
<div class="accordion-inner">
|
||||
<table class="table-condensed">
|
||||
<?php
|
||||
if($attrdefs) {
|
||||
foreach($attrdefs as $attrdef) {
|
||||
$attricon = '';
|
||||
if($attrdef->getObjType() == SeedDMS_Core_AttributeDefinition::objtype_folder) {
|
||||
?>
|
||||
<tr>
|
||||
<td><?php echo htmlspecialchars($attrdef->getName()); ?>:</td>
|
||||
<td><?php $this->printAttributeEditField($attrdef, isset($attributes[$attrdef->getID()]) ? $attributes[$attrdef->getID()] : '') ?></td>
|
||||
</tr>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<?php
|
||||
if($enablefullsearch) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user