/** * Get toolbar * * @return object toolbar */ function getToolbar() { global $ilCtrl, $lng, $tpl; // toolbar $tb = new ilToolbarGUI(); $tb->setFormAction($ilCtrl->getFormAction($this)); include_once "./Services/Form/classes/class.ilSelectInputGUI.php"; $options = array("WholePicture" => $lng->txt("cont_WholePicture"), "Rect" => $lng->txt("cont_Rect"), "Circle" => $lng->txt("cont_Circle"), "Poly" => $lng->txt("cont_Poly")); $si = new ilSelectInputGUI($lng->txt("cont_shape"), "shape"); $si->setOptions($options); $tb->addInputItem($si, true); $tb->addFormButton($lng->txt("cont_add_area"), "addNewArea"); // highlight mode /* if (strtolower(get_class($this)) == "ilimagemapeditorgui") { $st_item = $this->media_object->getMediaItem("Standard"); $tb->addSeparator(); $options = ilMapArea::getAllHighlightModes(); $hl = new ilSelectInputGUI($lng->txt("cont_highlight_mode"), "highlight_mode"); $hl->setOptions($options); // $hl->setValue($st_item->getHighlightMode()); $tb->addInputItem($hl, true); $options = ilMapArea::getAllHighlightClasses(); $hc = new ilSelectInputGUI($lng->txt("cont_highlight_class"), "highlight_class"); $hc->setOptions($options); // $hc->setValue($st_item->getHighlightClass()); $tb->addInputItem($hc, false); $tb->addFormButton($lng->txt("cont_set"), "setHighlight"); }*/ return $tb; }
/** * list fields */ public function listFields() { // Show tables require_once "./Modules/DataCollection/classes/class.ilDataCollectionTable.php"; $tables = $this->parent_obj->object->getTables(); foreach ($tables as $table) { $options[$table->getId()] = $table->getTitle(); } include_once './Services/Form/classes/class.ilSelectInputGUI.php'; $table_selection = new ilSelectInputGUI('', 'table_id'); $table_selection->setOptions($options); $table_selection->setValue($this->table_id); $this->toolbar->setFormAction($this->ctrl->getFormActionByClass("ilDataCollectionFieldListGUI", "doTableSwitch")); $this->toolbar->addText($this->lng->txt("dcl_table")); $this->toolbar->addInputItem($table_selection); $this->toolbar->addFormButton($this->lng->txt('change'), 'doTableSwitch'); $this->toolbar->addSeparator(); $this->toolbar->addButton($this->lng->txt("dcl_add_new_table"), $this->ctrl->getLinkTargetByClass("ildatacollectiontableeditgui", "create")); $this->toolbar->addSeparator(); $this->ctrl->setParameterByClass("ildatacollectiontableeditgui", "table_id", $this->table_id); $this->toolbar->addButton($this->lng->txt("dcl_table_settings"), $this->ctrl->getLinkTargetByClass("ildatacollectiontableeditgui", "edit")); $this->toolbar->addButton($this->lng->txt("dcl_delete_table"), $this->ctrl->getLinkTargetByClass("ildatacollectiontableeditgui", "confirmDelete")); $this->toolbar->addButton($this->lng->txt("dcl_add_new_field"), $this->ctrl->getLinkTargetByClass("ildatacollectionfieldeditgui", "create")); // requested not to implement this way... // $tpl->addJavaScript("Modules/DataCollection/js/fastTableSwitcher.js"); require_once './Modules/DataCollection/classes/class.ilDataCollectionFieldListTableGUI.php'; $list = new ilDataCollectionFieldListTableGUI($this, $this->ctrl->getCmd(), $this->table_id); $this->tpl->setContent($list->getHTML()); }
/** * Display mark schema * @param ilPropertyFormGUI $ects_form */ protected function showMarkSchema(ilPropertyFormGUI $ects_form = null) { if (!$this->object->canEditMarks()) { ilUtil::sendInfo($this->lng->txt('cannot_edit_marks')); } $this->toolbar->setFormAction($this->ctrl->getFormAction($this, 'showMarkSchema')); if ($this->object->canEditMarks()) { require_once 'Services/UIComponent/Button/classes/class.ilSubmitButton.php'; $create_simple_mark_schema_button = ilSubmitButton::getInstance(); $create_simple_mark_schema_button->setCaption($this->lng->txt('tst_mark_create_simple_mark_schema'), false); $create_simple_mark_schema_button->setCommand('addSimpleMarkSchema'); $this->toolbar->addButtonInstance($create_simple_mark_schema_button); } require_once 'Modules/Test/classes/tables/class.ilMarkSchemaTableGUI.php'; $mark_schema_table = new ilMarkSchemaTableGUI($this, 'showMarkSchema', '', $this->object); $content_parts = array($mark_schema_table->getHTML()); if ($this->objectSupportsEctsGrades() && $this->object->canEditEctsGrades()) { if (!$ects_form instanceof ilPropertyFormGUI) { $ects_form = $this->getEctsForm(); $this->populateEctsForm($ects_form); } $content_parts[] = $ects_form->getHTML(); } $this->tpl->setContent(implode('<br />', $content_parts)); }
/** * Get toolbar * * @return object toolbar */ function getToolbar() { global $ilCtrl, $lng; // toolbar $tb = new ilToolbarGUI(); $tb->setFormAction($ilCtrl->getFormAction($this)); include_once "./Services/Form/classes/class.ilSelectInputGUI.php"; $options = array("Rect" => $lng->txt("cont_Rect"), "Circle" => $lng->txt("cont_Circle"), "Poly" => $lng->txt("cont_Poly"), "Marker" => $lng->txt("cont_marker")); $si = new ilSelectInputGUI($lng->txt("cont_trigger_area"), "shape"); $si->setOptions($options); $tb->addInputItem($si, true); $tb->addFormButton($lng->txt("add"), "addNewArea"); return $tb; }
function manageObject() { global $ilUser, $objDefinition, $ilCtrl, $lng; $objects = array(); $this->manage = true; $this->setAvailableDetailLevels(1, 1); $top_tb = new ilToolbarGUI(); $top_tb->setFormAction($ilCtrl->getFormAction($this)); $top_tb->setLeadingImage(ilUtil::getImagePath("arrow_upright.png"), $lng->txt("actions")); if ($this->view == self::VIEW_MY_OFFERS) { $top_tb->addFormButton($lng->txt("remove"), "confirmRemove"); } else { $top_tb->addFormButton($lng->txt("pd_unsubscribe_memberships"), "confirmRemove"); } $top_tb->addSeparator(); $top_tb->addFormButton($lng->txt("cancel"), "getHTML"); $top_tb->setCloseFormTag(false); $bot_tb = new ilToolbarGUI(); $bot_tb->setLeadingImage(ilUtil::getImagePath("arrow_downright.png"), $lng->txt("actions")); if ($this->view == self::VIEW_MY_OFFERS) { $bot_tb->addFormButton($lng->txt("remove"), "confirmRemove"); } else { $bot_tb->addFormButton($lng->txt("pd_unsubscribe_memberships"), "confirmRemove"); } $bot_tb->addSeparator(); $bot_tb->addFormButton($lng->txt("cancel"), "getHTML"); $bot_tb->setOpenFormTag(false); return $top_tb->getHTML() . $this->getHTML() . $bot_tb->getHTML(); /* if($this->view == self::VIEW_MY_OFFERS) { return $top_tb->getHTML().$this->getHTML().$bot_tb->getHTML(); foreach($ilUser->getDesktopItems() as $item) { $objects[] = $item; } } else { $objtype_groups = $objDefinition->getGroupedRepositoryObjectTypes( array("cat", "crs", "grp", "fold")); foreach($objtype_groups as $grpdata) { foreach($this->getObjectsByMembership($grpdata["objs"]) as $item) { $objects[] = $item; } } } include_once "Services/PersonalDesktop/classes/class.ilPDSelectedItemsTableGUI.php"; $tbl = new ilPDSelectedItemsTableGUI($this, "manage", $objects, $this->view, ($ilUser->getPref("pd_order_items") == 'location')); return $tbl->getHTML(); */ }
function linkChecker() { global $ilias, $ilUser, $tpl; $this->__initLinkChecker(); $this->setTabs(); $this->setContentSubTabs("link_check"); require_once './Services/LinkChecker/classes/class.ilLinkCheckerTableGUI.php'; $toolbar = new ilToolbarGUI(); if ((bool) $ilias->getSetting('cron_web_resource_check')) { include_once './Services/LinkChecker/classes/class.ilLinkCheckNotify.php'; include_once 'Services/Form/classes/class.ilPropertyFormGUI.php'; $chb = new ilCheckboxInputGUI($this->lng->txt('link_check_message_a'), 'link_check_message'); $chb->setValue(1); $chb->setChecked((bool) ilLinkCheckNotify::_getNotifyStatus($ilUser->getId(), $this->object->getId())); $chb->setOptionTitle($this->lng->txt('link_check_message_b')); $toolbar->addInputItem($chb); $toolbar->addFormButton($this->lng->txt('save'), 'saveLinkCheck'); $toolbar->setFormAction($this->ctrl->getLinkTarget($this, 'saveLinkCheck')); } $tgui = new ilLinkCheckerTableGUI($this, 'linkChecker'); $tgui->setLinkChecker($this->link_checker_obj)->setRowHandler($this)->setRefreshButton($this->lng->txt('refresh'), 'refreshLinkCheck'); return $tpl->setContent($tgui->prepareHTML()->getHTML() . $toolbar->getHTML()); }
/** * Get confirmation screen HTML. * * @return string HTML code. */ public final function getHTML() { global $lng; ilUtil::sendQuestion($this->getHeaderText()); include_once "./Services/Utilities/classes/class.ilConfirmationTableGUI.php"; // delete/handle items if (count($this->item) > 0) { $ctab = new ilConfirmationTableGUI($this->use_images); $ctab->setData($this->item); // other buttons foreach ($this->buttons as $b) { $ctab->addCommandButton($b["cmd"], $b["txt"]); } $ctab->addCommandButton($this->confirm_cmd, $this->confirm_txt); $ctab->addCommandButton($this->cancel_cmd, $this->cancel_txt); $ctab->setFormAction($this->getFormAction()); foreach ($this->hidden_item as $hidden_item) { $ctab->addHiddenInput($hidden_item["var"], $hidden_item["value"]); } if ($this->form_name) { $ctab->setFormName($this->form_name); } return $ctab->getHTML(); } else { $tb = new ilToolbarGUI(); $tb->setPreventDoubleSubmission(true); $tb->setFormAction($this->getFormAction()); if ($this->hidden_item) { require_once 'Services/Form/classes/class.ilPropertyFormGUI.php'; foreach ($this->hidden_item as $hidden_item) { $hiddenInput = new ilHiddenInputGUI($hidden_item['var']); $hiddenInput->setValue($hidden_item['value']); $tb->addInputItem($hiddenInput); } } require_once 'Services/UIComponent/Button/classes/class.ilSubmitButton.php'; $confirm = ilSubmitButton::getInstance(); $confirm->setCommand($this->confirm_cmd); $confirm->setCaption($this->confirm_txt, false); $cancel = ilSubmitButton::getInstance(); $cancel->setCommand($this->cancel_cmd); $cancel->setCaption($this->cancel_txt, false); $tb->addButtonInstance($confirm); $tb->addButtonInstance($cancel); return $tb->getHTML(); } }
/** * Assign materials to skill level * * @param * @return */ function assignMaterial() { global $tpl, $ilUser, $ilCtrl, $ilTabs, $lng, $ilSetting; if (!$ilSetting->get("disable_personal_workspace")) { ilUtil::sendInfo($lng->txt("skmg_ass_materials_from_workspace") . " » <a href='ilias.php?baseClass=ilPersonalDesktopGUI&cmd=jumpToWorkspace'>" . $lng->txt("personal_workspace") . "</a>"); } $ilCtrl->saveParameter($this, "skill_id"); $ilCtrl->saveParameter($this, "level_id"); $ilCtrl->saveParameter($this, "tref_id"); $ilCtrl->saveParameter($this, "basic_skill_id"); $ilTabs->setBackTarget($lng->txt("back"), $ilCtrl->getLinkTarget($this, "assignMaterials")); // get ws tree include_once "Services/PersonalWorkspace/classes/class.ilWorkspaceTree.php"; $tree = new ilWorkspaceTree($ilUser->getId()); // get access handler include_once "./Services/PersonalWorkspace/classes/class.ilWorkspaceAccessHandler.php"; $acc_handler = new ilWorkspaceAccessHandler($tree); // get es explorer include_once "./Services/PersonalWorkspace/classes/class.ilWorkspaceExplorer.php"; $exp = new ilWorkspaceExplorer(ilWorkspaceExplorer::SEL_TYPE_CHECK, '', 'skill_wspexpand', $tree, $acc_handler); $exp->setTargetGet('wsp_id'); $exp->setFiltered(false); $exp->removeAllFormItemTypes(); $exp->addFormItemForType("file"); $exp->addFormItemForType("tstv"); $exp->addFormItemForType("excv"); if ($_GET['skill_wspexpand'] == '') { // not really used as session is already set [see above] $expanded = $tree->readRootId(); } else { $expanded = $_GET['skill_wspexpand']; } $exp->setCheckedItems(array((int) $_POST['wsp_id'])); $exp->setExpandTarget($ilCtrl->getLinkTarget($this, 'assignMaterial')); $exp->setPostVar('wsp_id[]'); $exp->setExpand($expanded); $exp->setOutput(0); // fill template $mtpl = new ilTemplate("tpl.materials_selection.html", true, true, "Services/Skill"); $mtpl->setVariable("EXP", $exp->getOutput()); // toolbars $tb = new ilToolbarGUI(); $tb->addFormButton($lng->txt("select"), "selectMaterial"); $tb->setFormAction($ilCtrl->getFormAction($this)); $tb->setOpenFormTag(true); $tb->setCloseFormTag(false); $mtpl->setVariable("TOOLBAR1", $tb->getHTML()); $tb->setOpenFormTag(false); $tb->setCloseFormTag(true); $mtpl->setVariable("TOOLBAR2", $tb->getHTML()); $tpl->setContent($mtpl->get()); }
/** * Show paste tree */ public function showPasteTreeObject() { global $ilTabs, $ilToolbar; $ilTabs->setTabActive('view_content'); if (!in_array($_SESSION['clipboard']['cmd'], array('link', 'copy', 'cut'))) { $message = __METHOD__ . ": Unknown action."; $this->ilias->raiseError($message, $this->ilias->error_obj->WARNING); } $cmd = $_SESSION['clipboard']['cmd']; // $exp = $this->getTreeSelectorGUI($cmd); if ($exp->handleCommand()) { return; } $output = $exp->getHTML(); $txt_var = $cmd == "copy" ? "copy" : "paste"; // toolbars $t = new ilToolbarGUI(); $t->setFormAction($this->ctrl->getFormAction($this, "performPasteIntoMultipleObjects")); $t->addFormButton($this->lng->txt($txt_var), "performPasteIntoMultipleObjects"); $t->addSeparator(); $t->addFormButton($this->lng->txt("obj_insert_into_clipboard"), "keepObjectsInClipboard"); $t->addFormButton($this->lng->txt("cancel"), "cancelMoveLink"); $t->setCloseFormTag(false); $t->setLeadingImage(ilUtil::getImagePath("arrow_upright.svg"), " "); $output = $t->getHTML() . $output; $t->setLeadingImage(ilUtil::getImagePath("arrow_downright.svg"), " "); $t->setCloseFormTag(true); $t->setOpenFormTag(false); $output .= "<br />" . $t->getHTML(); $this->tpl->setContent($output); }
/** * @return ilToolbarGUI */ private function buildSkillSelectorToolbarGUI() { require_once 'Services/UIComponent/Toolbar/classes/class.ilToolbarGUI.php'; $skillSelectorToolbarGUI = new ilToolbarGUI(); $skillSelectorToolbarGUI->setFormAction($this->ctrl->getFormAction($this)); $skillSelectorToolbarGUI->addFormButton($this->lng->txt('qpl_save_skill_assigns_update'), self::CMD_UPDATE_SKILL_QUEST_ASSIGNS); $skillSelectorToolbarGUI->addFormButton($this->lng->txt('qpl_cancel_skill_assigns_update'), self::CMD_SHOW_SKILL_QUEST_ASSIGNS); return $skillSelectorToolbarGUI; }
/** * Shows a card * Implemented here to ensure a common look & feel for all training modes * This method needs $_GET["card_id"] to be set */ protected function showCard() { $card_id = (int) $_GET["card_id"]; $this->ctrl->saveParameter($this, "card_id"); $tpl = $this->plugin->getTemplate("tpl.training_show_card.html"); // show the status text if ($text = $this->getTrainingStatusText()) { $tpl->setVariable("TRAINING_STATUS_TEXT", $text); } // show the flashcard $this->plugin->includeClass("class.ilFlashcardGUI.php"); $card = $this->object->getCard($card_id); if (!is_object($card)) { $tpl->setVariable("CARD_PRESENTATION", $this->plugin->txt('card_is_deleted')); } else { $card_gui = new ilFlashcardGUI($this, $this->object->getCard($card_id)); $tpl->setVariable("CARD_PRESENTATION", $card_gui->getCardForTrainingHTML()); } // show the training actions for the card require_once "./Services/UIComponent/Toolbar/classes/class.ilToolbarGUI.php"; $toolbar = new ilToolbarGUI(); $toolbar->setFormAction($this->ctrl->getFormAction($this)); $actions = $this->getCardActions($card_id); foreach ($actions as $action) { $toolbar->addFormButton($action["txt"], $action["cmd"]); } if (count($actions) > 1) { $toolbar->addSeparator(); } $toolbar->addFormButton($this->txt("cancel_training"), "cancelTraining"); $tpl->setVariable("CARD_ACTIONS", $toolbar->getHTML()); $this->tpl->setContent($tpl->get()); }
function manageObject() { global $ilUser, $objDefinition, $ilCtrl, $lng; $objects = array(); $this->manage = true; $this->setAvailableDetailLevels(1, 1); $top_tb = new ilToolbarGUI(); $top_tb->setFormAction($ilCtrl->getFormAction($this)); $top_tb->setLeadingImage(ilUtil::getImagePath("arrow_upright.svg"), $lng->txt("actions")); if ($this->view == self::VIEW_SELECTED_ITEMS) { $top_tb->addFormButton($lng->txt("remove"), "confirmRemove"); } else { $top_tb->addFormButton($lng->txt("pd_unsubscribe_memberships"), "confirmRemove"); } $top_tb->addSeparator(); $top_tb->addFormButton($lng->txt("cancel"), "getHTML"); $top_tb->setCloseFormTag(false); $bot_tb = new ilToolbarGUI(); $bot_tb->setLeadingImage(ilUtil::getImagePath("arrow_downright.svg"), $lng->txt("actions")); if ($this->view == self::VIEW_SELECTED_ITEMS) { $bot_tb->addFormButton($lng->txt("remove"), "confirmRemove"); } else { $bot_tb->addFormButton($lng->txt("pd_unsubscribe_memberships"), "confirmRemove"); } $bot_tb->addSeparator(); $bot_tb->addFormButton($lng->txt("cancel"), "getHTML"); $bot_tb->setOpenFormTag(false); return $top_tb->getHTML() . $this->getHTML() . $bot_tb->getHTML(); }
/** * Get confirmation screen HTML. * * @return string HTML code. */ public final function getHTML() { global $lng; ilUtil::sendQuestion($this->getHeaderText()); include_once "./Services/Utilities/classes/class.ilConfirmationTableGUI.php"; // delete/handle items if (count($this->item) > 0) { $ctab = new ilConfirmationTableGUI($this->use_images); $ctab->setData($this->item); // other buttons foreach ($this->buttons as $b) { $ctab->addCommandButton($b["cmd"], $b["txt"]); } $ctab->addCommandButton($this->confirm_cmd, $this->confirm_txt); $ctab->addCommandButton($this->cancel_cmd, $this->cancel_txt); $ctab->setFormAction($this->getFormAction()); foreach ($this->hidden_item as $hidden_item) { $ctab->addHiddenInput($hidden_item["var"], $hidden_item["value"]); } if ($this->form_name) { $ctab->setFormName($this->form_name); } return $ctab->getHTML(); } else { $tb = new ilToolbarGUI(); $tb->setFormAction($this->getFormAction()); $tb->addFormButton($this->confirm_txt, $this->confirm_cmd); $tb->addFormButton($this->cancel_txt, $this->cancel_cmd); return $tb->getHTML(); } }
/** * Show target selection */ public function showTargetSelectionTree() { global $ilTabs, $ilToolbar, $ilCtrl, $tree, $tpl, $objDefinition, $lng; $this->tpl = $tpl; if ($objDefinition->isContainer($this->getType())) { ilUtil::sendInfo($this->lng->txt('msg_copy_clipboard_container')); } else { ilUtil::sendInfo($this->lng->txt('msg_copy_clipboard')); } // include_once "./Services/Repository/classes/class.ilRepositorySelectorExplorerGUI.php"; $exp = new ilRepositorySelectorExplorerGUI($this, "showTargetSelectionTree"); $exp->setTypeWhiteList(array("root", "cat", "grp", "crs", "fold")); $exp->setSelectMode("target", false); if ($exp->handleCommand()) { return; } $output = $exp->getHTML(); // toolbars $t = new ilToolbarGUI(); $t->setFormAction($ilCtrl->getFormAction($this, "saveTarget")); if ($objDefinition->isContainer($this->getType())) { $t->addFormButton($lng->txt("btn_next"), "saveTarget"); } else { $t->addFormButton($lng->txt("paste"), "saveTarget"); } $t->addSeparator(); $t->addFormButton($lng->txt("obj_insert_into_clipboard"), "keepObjectsInClipboard"); $t->addFormButton($lng->txt("cancel"), "cancel"); $t->setCloseFormTag(false); $t->setLeadingImage(ilUtil::getImagePath("arrow_upright.svg"), " "); $output = $t->getHTML() . $output; $t->setLeadingImage(ilUtil::getImagePath("arrow_downright.svg"), " "); $t->setCloseFormTag(true); $t->setOpenFormTag(false); $output .= "<br />" . $t->getHTML(); $this->tpl->setContent($output); return; // old implementation $this->tpl->addBlockfile('ADM_CONTENT', 'adm_content', 'tpl.paste_into_multiple_objects.html', "Services/Object"); include_once './Services/Object/classes/class.ilPasteIntoMultipleItemsExplorer.php'; $exp = new ilPasteIntoMultipleItemsExplorer(ilPasteIntoMultipleItemsExplorer::SEL_TYPE_RADIO, 'ilias.php?baseClass=ilRepositoryGUI&cmd=goto', 'paste_copy_repexpand'); // Target selection should check for create permission $required_perm = 'visible'; $create_perm = 'create_' . ilObject::_lookupType($this->getSource(), true); if ($create_perm) { $required_perm .= ',' . $create_perm; } $exp->setRequiredFormItemPermission($required_perm); $exp->setExpandTarget($ilCtrl->getLinkTarget($this, 'showTargetSelectionTree')); $exp->setTargetGet('ref_id'); $exp->setPostVar('target'); $exp->highlightNode($_GET['ref_id']); $exp->setCheckedItems(array((int) $_POST['target'])); // Filter to container foreach (array('cat', 'root', 'crs', 'grp', 'fold') as $container) { /* if($this->getType() == 'crs' and $container == 'crs') { continue; } */ $sub = $objDefinition->getSubObjects($container); if (!isset($sub[$this->getType()])) { $exp->removeFormItemForType($container); } } if ($_GET['paste_copy_repexpand'] == '') { $expanded = $tree->readRootId(); } else { $expanded = $_GET['paste_copy_repexpand']; } $this->tpl->setVariable('FORM_TARGET', '_self'); $this->tpl->setVariable('FORM_ACTION', $ilCtrl->getFormAction($this, 'copySelection')); $exp->setExpand($expanded); // build html-output $exp->setOutput(0); $output = $exp->getOutput(); $this->tpl->setVariable('OBJECT_TREE', $output); $this->tpl->setVariable('CMD_SUBMIT', 'saveTarget'); if ($objDefinition->isContainer($this->getType())) { $this->tpl->setVariable('TXT_SUBMIT', $this->lng->txt('btn_next')); } else { if (!$objDefinition->isPlugin($this->getType())) { $submit = $this->lng->txt('obj_' . $this->getType() . '_duplicate'); } else { // get plugin instance include_once "Services/Component/classes/class.ilPlugin.php"; $plugin = ilPlugin::getPluginObject(IL_COMP_SERVICE, "Repository", "robj", ilPlugin::lookupNameForId(IL_COMP_SERVICE, "Repository", "robj", $this->getType())); $submit = $plugin->txt('obj_' . $this->getType() . '_duplicate'); } $this->tpl->setVariable('TXT_SUBMIT', $submit); } $ilToolbar->addButton($this->lng->txt('cancel'), $ilCtrl->getLinkTarget($this, 'cancel')); }