4 include_once
'Services/Search/classes/class.ilSearchSettings.php';
5 include_once
'./Services/PersonalDesktop/interfaces/interface.ilDesktopItemHandling.php';
6 include_once
'./Services/Administration/interfaces/interface.ilAdministrationCommandHandling.php';
55 $this->lng->loadLanguageModule(
'search');
57 $ilMainMenu->setActive(
'search');
63 global $ilLocator,
$lng;
65 $this->tpl->getStandardTemplate();
72 $this->tpl->setTitleIcon(
76 $this->tpl->setTitle($lng->txt(
"search"));
88 include_once(
"Services/Form/classes/class.ilPropertyFormGUI.php");
90 $this->form->setOpenTag(
false);
91 $this->form->setCloseTag(
false);
96 $this->form->addItem($radg);
99 if ($a_mode == self::SEARCH_FORM_STANDARD) {
109 $radg->addOption($op1);
112 $op2 =
new ilCheckboxInputGUI($this->lng->txt(
'search_filter_by_type'),
'item_filter_enabled');
119 $cbgr->setUseValuesAsKeys(
true);
120 $details = $this->getDetails();
124 if ($details[
$type]) {
127 $cbgr->addOption($cb);
129 if ($a_mode == self::SEARCH_FORM_LUCENE) {
131 $mimes = $this->getMimeDetails();
137 $cbgr->addOption($op3);
143 $op2->addSubItem($cbgr);
145 if ($a_mode != self::SEARCH_FORM_STANDARD && $det) {
146 $op2->setChecked(
true);
150 $radg->addOption($op2);
151 $this->form->addItem($radg);
153 $this->form->addItem($op2);
157 $this->form->setFormAction($ilCtrl->getFormAction($this,
'performSearch'));
167 include_once(
"Services/Form/classes/class.ilPropertyFormGUI.php");
169 $form->setOpenTag(
false);
170 $form->setCloseTag(
false);
175 $form->addItem($radg);
178 include_once(
"./Services/Form/classes/class.ilRepositorySelectorInputGUI.php");
182 $ti->readFromSession();
186 if (isset(
$_POST[
"root_id"])) {
187 $ti->setValue(
$_POST[
"root_id"]);
188 $ti->writeToSession();
190 $form->setFormAction($ilCtrl->getFormAction($this,
'performSearch'));
202 if (method_exists($this, $a_cmd)) {
215 include_once
'./Services/PersonalDesktop/classes/class.ilDesktopItemGUI.php';
217 $this->showSavedResults();
225 include_once
'./Services/PersonalDesktop/classes/class.ilDesktopItemGUI.php';
227 $this->showSavedResults();
233 public function delete()
235 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
245 $this->showSavedResults();
250 $this->showSavedResults();
258 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
260 $admin->performDelete();
268 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
278 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
285 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
292 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
294 $admin->showLinkIntoMultipleObjectsTree();
299 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
301 $admin->showMoveIntoObjectTree();
306 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
308 $admin->performPasteIntoMultipleObjects();
314 $this->ctrl->redirect($this);
320 $this->ctrl->redirect($this);
325 $_SESSION[
"il_cont_admin_panel"] =
false;
326 $this->ctrl->redirect($this);
334 $this->ctrl->redirect($this);
343 $ilLocator->addItem($this->lng->txt(
'search'), $this->ctrl->getLinkTarget($this));
344 $this->tpl->setLocator();
358 $_SESSION[
"$a_session_key"] = max(
$_SESSION[
"$a_session_key"], $this->search_cache->getResultPageNumber());
365 if ($this->search_cache->getResultPageNumber() > 1) {
366 $this->ctrl->setParameter($this,
'page_number', $this->search_cache->getResultPageNumber() - 1);
372 $this->prev_link = $this->ctrl->getLinkTarget($this,
'performSearch');
375 if (
$i == $this->search_cache->getResultPageNumber()) {
383 $this->ctrl->setParameter($this,
'page_number',
$i);
384 $link =
'<a href="' . $this->ctrl->getLinkTarget($this,
'performSearch') .
'" /a>' .
$i .
'</a> ';
393 $this->ctrl->setParameter($this,
'page_number', $this->search_cache->getResultPageNumber() + 1);
399 $this->next_link = $this->ctrl->getLinkTarget($this,
'performSearch');
407 $this->ctrl->clearParameters($this);
418 $path_arr = $tree->getPathFull($a_root_node, ROOT_FOLDER_ID);
420 foreach ($path_arr as
$data) {
423 $path .= $data[
'title'];
425 $path .= $this->lng->txt(
'repository');
436 $q = $_REQUEST[
"term"];
437 include_once(
"./Services/Search/classes/class.ilSearchAutoComplete.php");
446 $options = $this->search_cache->getCreationFilter();
448 include_once
'./Services/Form/classes/class.ilPropertyFormGUI.php';
450 $form->setOpenTag(
false);
451 $form->setCloseTag(
false);
455 $enabled->setChecked((
bool)
$options[
'enabled']);
456 $form->addItem($enabled);
458 #$group = new ilRadioGroupInputGUI('', 'screation_type'); 459 #$group->setValue((int) $options['type']); 460 #$group->addOption($opt1 = new ilRadioOption($this->lng->txt('search_filter_date'), 1)); 463 $limit_sel->setValue($options[
'ontype']);
464 $limit_sel->setOptions(
466 1 => $this->lng->txt(
'search_created_after'),
467 2 => $this->lng->txt(
'search_created_before'),
468 3 => $this->lng->txt(
'search_created_on')
471 $enabled->addSubItem($limit_sel);
474 if ($options[
'date']) {
480 $ds->setRequired(
true);
482 $enabled->addSubItem($ds);
484 #$group->addOption($opt2 = new ilRadioOption($this->lng->txt('search_filter_duration'), 2)); 486 #$duration = new ilDurationInputGUI($this->lng->txt('search_filter_duration'), 'screation_duration'); 487 #$duration->setMonths((int) $options['duration']['MM']); 488 #$duration->setDays((int) $options['duration']['dd']); 489 #$duration->setShowMonths(true); 490 #$duration->setShowDays(true); 491 #$duration->setShowHours(false); 492 #$duration->setShowMinutes(false); 493 #$duration->setTitle($this->lng->txt('search_newer_than')); 494 #$opt2->addSubItem($duration); 496 #$enabled->addSubItem($group); 498 $form->setFormAction(
$GLOBALS[
'ilCtrl']->getFormAction($this,
'performSearch'));
509 return $this->search_cache;
518 if (!$this->
settings->isDateFilterEnabled()) {
525 if (
$form->checkInput()) {
530 $options[
'duration'] =
$form->getInput(
'screation_duration');
static _getIcon( $a_obj_id="", $a_size="big", $a_type="", $a_offline=false)
Get icon for repository item.
This class represents an option in a radio group.
link()
Interface ilAdministrationCommandHandler.
loadCreationFilter()
Load creation date filter.
if(isset($_REQUEST['delete'])) $list
cancelMoveLinkObject()
Cancel move/link.
removeFromDeskObject()
Remove from dektop.
getSearchAreaForm()
Init standard search form.
This class represents an option in a checkbox group.
showLinkIntoMultipleObjectsTree()
Target selection link.
Handles Administration commands (cut, delete paste)
performDelete()
Delete objects.
addToDeskObject()
Interface methods.
$GLOBALS['loaded']
Global hash that tracks already loaded includes.
static getList($a_str)
Get completion list.
static addToDesktop()
Add desktop item public.
keepObjectsInClipboardObject()
cancel action but keep objects in clipboardvoid
buildSearchAreaPath($a_root_node)
Build path for search area.
disableAdministrationPanel()
Disable administration panel.
setValue($a_value)
Set Value.
addPager($result, $a_session_key)
Add Pager.
if(isset($_POST['submit'])) $form
cut()
Interface ilAdministrationCommandHandler.
autoComplete()
Data resource for autoComplete.
__construct()
Constructor public.
initStandardSearchForm($a_mode)
Init standard search form.
static infoPanel($a_keep=true)
cancelDelete()
Cancel delete.
redirection script todo: (a better solution should control the processing via a xml file) ...
performPasteIntoMultipleObjects()
Perform paste into multiple objects.
handleCommand($a_cmd)
Handle command.
Create styles array
The data for the language used.
showMoveIntoObjectTree()
Target selection cut.
static removeFromDesktop()
Remove item from personal desktop public.
Interface for gui classes (e.g ilLuceneSearchGUI) that offer add/remove to/from desktop.
enableAdministrationPanel()
Enable administration panel.
Add data(end) time
Method that wraps PHPs time in order to allow simulations with the workflow.
Interface for GUI classes (PDGUI, LuceneSearchGUI...) that have to handle administration commands (cu...
const SEARCH_FORM_STANDARD
if(!isset($_REQUEST['ReturnTo'])) if(!isset($_REQUEST['AuthId'])) $options
getSearchCache()
Get user search cache.