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 $ilMainMenu = $DIC[
'ilMainMenu'];
61 $this->lng->loadLanguageModule(
'search');
63 $ilMainMenu->setActive(
'search');
71 $ilLocator = $DIC[
'ilLocator'];
74 $this->tpl->getStandardTemplate();
81 $this->tpl->setTitleIcon(
82 ilObject::_getIcon(
"",
"big",
"src"),
85 $this->tpl->setTitle(
$lng->txt(
"search"));
100 include_once(
"Services/Form/classes/class.ilPropertyFormGUI.php");
102 $this->form->setOpenTag(
false);
103 $this->form->setCloseTag(
false);
108 $this->form->addItem($radg);
111 if ($a_mode == self::SEARCH_FORM_STANDARD) {
121 $radg->addOption($op1);
124 $op2 =
new ilCheckboxInputGUI($this->lng->txt(
'search_filter_by_type'),
'item_filter_enabled');
131 $cbgr->setUseValuesAsKeys(
true);
132 $details = $this->getDetails();
136 if ($details[
$type]) {
139 $cbgr->addOption($cb);
141 if ($a_mode == self::SEARCH_FORM_LUCENE) {
143 $mimes = $this->getMimeDetails();
149 $cbgr->addOption($op3);
154 $cbgr->
setValue(array_merge((array) $details, (array) $mimes));
155 $op2->addSubItem($cbgr);
157 if ($a_mode != self::SEARCH_FORM_STANDARD && $det) {
158 $op2->setChecked(
true);
162 $radg->addOption($op2);
163 $this->form->addItem($radg);
165 $this->form->addItem($op2);
169 $this->form->setFormAction(
$ilCtrl->getFormAction($this,
'performSearch'));
182 include_once(
"Services/Form/classes/class.ilPropertyFormGUI.php");
184 $form->setOpenTag(
false);
185 $form->setCloseTag(
false);
190 $form->addItem($radg);
193 include_once(
"./Services/Form/classes/class.ilRepositorySelectorInputGUI.php");
197 $ti->readFromSession();
201 if (isset(
$_POST[
"root_id"])) {
202 $ti->setValue(
$_POST[
"root_id"]);
203 $ti->writeToSession();
205 $form->setFormAction(
$ilCtrl->getFormAction($this,
'performSearch'));
217 if (method_exists($this, $a_cmd)) {
230 include_once
'./Services/PersonalDesktop/classes/class.ilDesktopItemGUI.php';
232 $this->showSavedResults();
240 include_once
'./Services/PersonalDesktop/classes/class.ilDesktopItemGUI.php';
242 $this->showSavedResults();
248 public function delete()
250 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
260 $this->showSavedResults();
265 $this->showSavedResults();
273 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
275 $admin->performDelete();
283 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
293 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
300 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
307 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
309 $admin->showLinkIntoMultipleObjectsTree();
314 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
316 $admin->showPasteTree();
321 include_once
'./Services/Administration/classes/class.ilAdministrationCommandGUI.php';
323 $admin->performPasteIntoMultipleObjects();
329 $this->ctrl->redirect($this);
335 $this->ctrl->redirect($this);
340 $_SESSION[
"il_cont_admin_panel"] =
false;
341 $this->ctrl->redirect($this);
349 $this->ctrl->redirect($this);
358 $ilLocator->addItem($this->lng->txt(
'search'), $this->ctrl->getLinkTarget($this));
359 $this->tpl->setLocator();
375 $_SESSION[
"$a_session_key"] = max(
$_SESSION[
"$a_session_key"], $this->search_cache->getResultPageNumber());
382 if ($this->search_cache->getResultPageNumber() > 1) {
383 $this->ctrl->setParameter($this,
'page_number', $this->search_cache->getResultPageNumber() - 1);
389 $this->prev_link = $this->ctrl->getLinkTarget($this,
'performSearch');
392 if (
$i == $this->search_cache->getResultPageNumber()) {
400 $this->ctrl->setParameter($this,
'page_number',
$i);
401 $link =
'<a href="' . $this->ctrl->getLinkTarget($this,
'performSearch') .
'" /a>' .
$i .
'</a> ';
410 $this->ctrl->setParameter($this,
'page_number', $this->search_cache->getResultPageNumber() + 1);
416 $this->next_link = $this->ctrl->getLinkTarget($this,
'performSearch');
424 $this->ctrl->clearParameters($this);
435 $tree = $DIC[
'tree'];
437 $path_arr =
$tree->getPathFull($a_root_node, ROOT_FOLDER_ID);
439 foreach ($path_arr as
$data) {
442 $path .= $data[
'title'];
444 $path .= $this->lng->txt(
'repository');
455 $q = $_REQUEST[
"term"];
456 include_once(
"./Services/Search/classes/class.ilSearchAutoComplete.php");
465 $options = $this->search_cache->getCreationFilter();
467 include_once
'./Services/Form/classes/class.ilPropertyFormGUI.php';
469 $form->setOpenTag(
false);
470 $form->setCloseTag(
false);
474 $enabled->setChecked((
bool)
$options[
'enabled']);
475 $form->addItem($enabled);
477 #$group = new ilRadioGroupInputGUI('', 'screation_type'); 478 #$group->setValue((int) $options['type']); 479 #$group->addOption($opt1 = new ilRadioOption($this->lng->txt('search_filter_date'), 1)); 482 $limit_sel->setValue($options[
'ontype']);
483 $limit_sel->setOptions(
485 1 => $this->lng->txt(
'search_created_after'),
486 2 => $this->lng->txt(
'search_created_before'),
487 3 => $this->lng->txt(
'search_created_on')
490 $enabled->addSubItem($limit_sel);
493 if ($options[
'date']) {
499 $ds->setRequired(
true);
501 $enabled->addSubItem($ds);
503 #$group->addOption($opt2 = new ilRadioOption($this->lng->txt('search_filter_duration'), 2)); 505 #$duration = new ilDurationInputGUI($this->lng->txt('search_filter_duration'), 'screation_duration'); 506 #$duration->setMonths((int) $options['duration']['MM']); 507 #$duration->setDays((int) $options['duration']['dd']); 508 #$duration->setShowMonths(true); 509 #$duration->setShowDays(true); 510 #$duration->setShowHours(false); 511 #$duration->setShowMinutes(false); 512 #$duration->setTitle($this->lng->txt('search_newer_than')); 513 #$opt2->addSubItem($duration); 515 #$enabled->addSubItem($group); 517 $form->setFormAction(
$GLOBALS[
'DIC'][
'ilCtrl']->getFormAction($this,
'performSearch'));
528 return $this->search_cache;
537 if (!$this->
settings->isDateFilterEnabled()) {
544 if (
$form->checkInput()) {
549 $options[
'duration'] =
$form->getInput(
'screation_duration');
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.
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.
showPasteTree()
Target selection cut.
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.
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.
Interface for GUI classes (PDGUI, LuceneSearchGUI...) that have to handle administration commands (cu...
const SEARCH_FORM_STANDARD
$GLOBALS['JPEG_Segment_Names']
Global Variable: XMP_tag_captions.
getSearchCache()
Get user search cache.