ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ilObjPortfolioBaseGUI Class Reference

Portfolio view gui base class. More...

+ Inheritance diagram for ilObjPortfolioBaseGUI:
+ Collaboration diagram for ilObjPortfolioBaseGUI:

Public Member Functions

 __construct (int $a_id=0, int $a_id_type=self::REPOSITORY_NODE_ID, int $a_parent_node_id=0)
 
 setAdditional (array $a_additional)
 Set Additonal Information (used in public profile?) More...
 
 getAdditional ()
 
 setPermaLink (int $a_obj_id, string $a_type)
 Set custom perma link (used in public profile?) More...
 
 getPageGUIClassName ()
 
 view ()
 Show list of portfolio pages. More...
 
 initPageForm (string $a_mode="create")
 Init portfolio page form. More...
 
 savePage ()
 Create new portfolio page. More...
 
 savePortfolioPagesOrdering ()
 Save ordering of portfolio pages. More...
 
 confirmPortfolioPageDeletion ()
 
 deletePortfolioPages ()
 
 export (bool $a_with_comments=false)
 
 exportWithComments ()
 
 copyPageForm (?ilPropertyFormGUI $a_form=null)
 Select target portfolio for page(s) copy. More...
 
 copyPage ()
 
 initCopyPageForm ()
 
 setContentStyleSheet (?ilGlobalTemplateInterface $a_tpl=null)
 
- Public Member Functions inherited from ilObject2GUI
 __construct (int $id=0, int $id_type=self::REPOSITORY_NODE_ID, int $parent_node_id=0)
 
 executeCommand ()
 execute command More...
 
 getIdType ()
 
 delete ()
 Display delete confirmation form (repository/workspace switch) More...
 
 confirmedDelete ()
 Delete objects (repository/workspace switch) More...
 
 getHTML ()
 
 withReferences ()
 Final/Private declaration of unchanged parent methods. More...
 
 setCreationMode (bool $mode=true)
 If true, a creation screen is displayed the current [ref_id] does belong to the parent class The mode is determined in ilRepositoryGUI. More...
 
 getCreationMode ()
 
 prepareOutput (bool $show_sub_objects=true)
 
 isVisible (int $ref_id, string $type)
 
 setColumnSettings (ilColumnGUI $column_gui)
 
 view ()
 view object content (repository/workspace switch) More...
 
 getType ()
 Functions that must be overwritten. More...
 
 create ()
 CRUD. More...
 
 save ()
 
 edit ()
 
 update ()
 
 cancel ()
 
 putObjectInTree (ilObject $obj, ?int $parent_node_id=null)
 Add object to tree at given position. More...
 
- Public Member Functions inherited from ilObjectGUI
 getRefId ()
 
 setAdminMode (string $mode)
 
 getAdminMode ()
 
 getObject ()
 
 executeCommand ()
 
 withReferences ()
 determines whether objects are referenced or not (got ref ids or not) More...
 
 setCreationMode (bool $mode=true)
 If true, a creation screen is displayed the current [ref_id] does belong to the parent class The mode is determined in ilRepositoryGUI. More...
 
 getCreationMode ()
 
 prepareOutput (bool $show_sub_objects=true)
 
 getAdminTabs ()
 administration tabs show only permissions and trash folder More...
 
 getHTML ()
 
 confirmedDeleteObject ()
 confirmed deletion of object -> objects are moved to trash or deleted immediately, if trash is disabled More...
 
 cancelObject ()
 cancel action and go back to previous page More...
 
 createObject ()
 create new object form More...
 
 editAvailabilityPeriodObject ()
 
 saveAvailabilityPeriodObject ()
 
 cancelCreation ()
 cancel create action and go back to repository parent More...
 
 saveObject ()
 
 getDidacticTemplateVar (string $type)
 Get didactic template setting from creation screen. More...
 
 putObjectInTree (ilObject $obj, ?int $parent_node_id=null)
 Add object to tree at given position. More...
 
 editObject ()
 
 addExternalEditFormCustom (ilPropertyFormGUI $form)
 
 updateObject ()
 updates object entry in object_data More...
 
 getFormAction (string $cmd, string $default_form_action="")
 Get form action for command (command is method name without "Object", e.g. More...
 
 isVisible (int $ref_id, string $type)
 
 viewObject ()
 viewObject container presentation for "administration -> repository, trash, permissions" More...
 
 deleteObject (bool $error=false)
 Display deletion confirmation screen. More...
 
 setColumnSettings (ilColumnGUI $column_gui)
 
 addToDeskObject ()
 
 removeFromDeskObject ()
 
- Public Member Functions inherited from ILIAS\Object\ImplementsCreationCallback
 callCreationCallback (\ilObject $object, \ilObjectDefinition $obj_definition, int $requested_crtcb)
 

Static Public Member Functions

static renderFullscreenHeader (ilObjPortfolioBase $a_portfolio, ilGlobalTemplateInterface $a_tpl, int $a_user_id, bool $a_export=false)
 
- Static Public Member Functions inherited from ilObject2GUI
static handleAfterSaveCallback (ilObject $obj, ?int $callback_ref_id)
 After creation callback. More...
 
- Static Public Member Functions inherited from ilObjectGUI
static _gotoRepositoryRoot (bool $raise_error=false)
 Goto repository root. More...
 
static _gotoRepositoryNode (int $ref_id, string $cmd="")
 
static _gotoSharedWorkspaceNode (int $wsp_id)
 

Protected Member Functions

 addLocatorItems ()
 Functions to be overwritten. More...
 
 determinePageCall ()
 
 handlePageCall (string $a_cmd)
 
 setSettingsSubTabs (string $a_active)
 
 initEditCustomForm (ilPropertyFormGUI $a_form)
 Add custom fields to update form. More...
 
 getEditFormCustomValues (array &$a_values)
 Add values to custom edit fields. More...
 
 updateCustom (ilPropertyFormGUI $form)
 Insert custom update form values into object. More...
 
 getPageInstance (?int $a_page_id=null, ?int $a_portfolio_id=null)
 
 getPageGUIInstance (int $a_page_id)
 
 addPage ()
 Show portfolio page creation form. More...
 
 getCurrentPage ()
 
 getCommentGUI ()
 
 showEditButton (int $page_id)
 
 initCopyPageFormOptions (ilPropertyFormGUI $a_form)
 
- Protected Member Functions inherited from ilObject2GUI
 afterConstructor ()
 Do anything that should be done after constructor in here. More...
 
 assignObject ()
 create object instance as internal property (repository/workspace switch) More...
 
 getAccessHandler ()
 
 setLocator ()
 set Locator More...
 
 deleteConfirmedObjects ()
 Delete objects (workspace specific) This should probably be moved elsewhere as done with RepUtil. More...
 
 setTitleAndDescription ()
 
 omitLocator (bool $omit=true)
 
 getTargetFrame (string $cmd, string $target_frame="")
 get target frame for command (command is method name without "Object", e.g. More...
 
 setTargetFrame (string $cmd, string $target_frame)
 Set specific target frame for command. More...
 
 getCenterColumnHTML ()
 Get center column. More...
 
 getRightColumnHTML ()
 Display right column. More...
 
 checkPermission (string $perm, string $cmd="", string $type="", ?int $ref_id=null)
 
 showPossibleSubObjects ()
 show possible sub objects (pull down menu) More...
 
 redirectToRefId (int $ref_id, string $cmd="")
 redirects to (repository) view per ref id usually to a container and usually used at the end of a save/import method where the object gui type (of the new object) doesn't match with the type of the current ["ref_id"] value of the request More...
 
 addAdminLocatorItems (bool $do_not_add_object=false)
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 setTabs ()
 create tabs (repository/workspace switch) More...
 
 getReturnLocation (string $cmd, string $location="")
 Deprecated functions. More...
 
 setReturnLocation (string $cmd, string $location)
 set specific return location for command More...
 
 showActions ()
 
 getTabs ()
 @abstract overwrite in derived GUI class of your object type More...
 
 addLocatorItems ()
 Functions to be overwritten. More...
 
 checkPermissionBool (string $perm, string $cmd="", string $type="", ?int $node_id=null)
 
 initHeaderAction (?string $sub_type=null, ?int $sub_id=null)
 Add header action menu. More...
 
 redrawHeaderAction ()
 Updating icons after ajax call. More...
 
- Protected Member Functions inherited from ilObjectGUI
 getObjectService ()
 
 assignObject ()
 
 setTitleAndDescription ()
 
 createActionDispatcherGUI ()
 
 initHeaderAction (?string $sub_type=null, ?int $sub_id=null)
 Add header action menu. More...
 
 insertHeaderAction (?ilObjectListGUI $list_gui=null)
 Insert header action into main template. More...
 
 addHeaderAction ()
 Add header action menu. More...
 
 redrawHeaderActionObject ()
 Ajax call: redraw action header only. More...
 
 setTabs ()
 set admin tabs More...
 
 setAdminTabs ()
 set admin tabs More...
 
 setLocator ()
 
 addLocatorItems ()
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 omitLocator (bool $omit=true)
 
 addAdminLocatorItems (bool $do_not_add_object=false)
 should be overwritten to add object specific items (repository items are preloaded) More...
 
 getCreationFormsHTML (StandardForm|ilPropertyFormGUI|array $form)
 
 getTitleForCreationFormPage ()
 
 getCreationFormTitle ()
 
 initCreateForm (string $new_type)
 
 didacticTemplatesToForm ()
 
 initDidacticTemplate (ilPropertyFormGUI $form)
 
 retrieveAdditionalDidacticTemplateOptions ()
 
 addAdoptContentLinkToToolbar ()
 
 addImportButtonToToolbar ()
 
 addAvailabilityPeriodButtonToToolbar (ilToolbarGUI $toolbar)
 
 parseDidacticTemplateVar (string $var, string $type)
 
 afterSave (ilObject $new_object)
 Post (successful) object creation hook. More...
 
 initEditForm ()
 
 initEditCustomForm (ilPropertyFormGUI $a_form)
 Add custom fields to update form. More...
 
 getEditFormValues ()
 
 getEditFormCustomValues (array &$a_values)
 Add values to custom edit fields. More...
 
 validateCustom (ilPropertyFormGUI $form)
 Validate custom values (if not possible with checkInput()) More...
 
 updateCustom (ilPropertyFormGUI $form)
 Insert custom update form values into object. More...
 
 afterUpdate ()
 Post (successful) object update hook. More...
 
 routeImportCmdObject ()
 
 importFile (string $file_to_import, string $path_to_uploaded_file_in_temp_dir)
 
 deleteUploadedImportFile (string $path_to_uploaded_file_in_temp_dir)
 
 afterImport (ilObject $new_object)
 Post (successful) object import hook. More...
 
 setFormAction (string $cmd, string $form_action)
 
 getReturnLocation (string $cmd, string $default_location="")
 Get return location for command (command is method name without "Object", e.g. More...
 
 setReturnLocation (string $cmd, string $location)
 set specific return location for command More...
 
 getTargetFrame (string $cmd, string $default_target_frame="")
 get target frame for command (command is method name without "Object", e.g. More...
 
 setTargetFrame (string $cmd, string $target_frame)
 Set specific target frame for command. More...
 
 showPossibleSubObjects ()
 show possible sub objects (pull down menu) More...
 
 getTabs ()
 @abstract overwrite in derived GUI class of your object type More...
 
 redirectToRefId (int $ref_id, string $cmd="")
 redirects to (repository) view per ref id usually to a container and usually used at the end of a save/import method where the object gui type (of the new object) doesn't match with the type of the current ["ref_id"] value of the request More...
 
 getCenterColumnHTML ()
 Get center column. More...
 
 getRightColumnHTML ()
 Display right column. More...
 
 checkPermission (string $perm, string $cmd="", string $type="", ?int $ref_id=null)
 
 checkPermissionBool (string $perm, string $cmd="", string $type="", ?int $ref_id=null)
 
 enableDragDropFileUpload ()
 Enables the file upload into this object by dropping files. More...
 
 getCreatableObjectTypes ()
 
 buildAddNewItemElements (array $subtypes, string $create_target_class=ilRepositoryGUI::class, ?int $redirect_target_ref_id=null,)
 
 buildGroup (string $create_target_class, array $obj_types_in_group, string $title, array $subtypes)
 

Protected Attributes

ILIAS Notes Service $notes
 
ILIAS Portfolio InternalGUIService $gui
 
StandardGUIRequest $port_request
 
ilHelpGUI $help
 
int $user_id = 0
 
array $additional = array()
 
array $perma_link = []
 
int $page_id = 0
 
string $page_mode
 
int $requested_ppage
 
int $requested_user_page
 
string $requested_back_url = ""
 
ILIAS DI UIServices $ui
 
ILIAS Style Content GUIService $content_style_gui
 
ILIAS Style Content Object ObjectFacade $content_style_domain
 
- Protected Attributes inherited from ilObject2GUI
ilObjectDefinition $obj_definition
 
ilGlobalTemplateInterface $tpl
 
ilCtrl $ctrl
 
ilLanguage $lng
 
ilTabsGUI $tabs_gui
 
ilFavouritesManager $favourites
 
ilErrorHandling $error
 
ilLocatorGUI $locator
 
ilObjUser $user
 
ilAccessHandler $access
 
ilToolbarGUI $toolbar
 
Factory $refinery
 
ilRbacAdmin $rbac_admin
 
ilRbacSystem $rbac_system
 
ilRbacReview $rbac_review
 
int $request_ref_id
 
int $id_type
 
int $parent_id
 
string $type
 
string $html
 
int $object_id
 
int $node_id = null
 
array $creation_forms = []
 
 $access_handler
 
- Protected Attributes inherited from ilObjectGUI
ILIAS Notes Service $notes_service
 
GlobalHttpState $http
 
ServerRequestInterface $request
 
ilLocatorGUI $locator
 
ilObjUser $user
 
ilAccessHandler $access
 
ilSetting $settings
 
ilToolbarGUI $toolbar
 
ilRbacAdmin $rbac_admin
 
ilRbacSystem $rbac_system
 
ilRbacReview $rbac_review
 
ilObjectService $object_service
 
ilObjectDefinition $obj_definition
 
ilGlobalTemplateInterface $tpl
 
ilTree $tree
 
ilCtrl $ctrl
 
ilErrorHandling $error
 
ilLanguage $lng
 
ilTabsGUI $tabs_gui
 
ILIAS $ilias
 
ArrayBasedRequestWrapper $post_wrapper
 
RequestWrapper $request_wrapper
 
Refinery $refinery
 
ilFavouritesManager $favourites
 
CustomIconFactory $custom_icon_factory
 
UIFactory $ui_factory
 
UIRenderer $ui_renderer
 
Filesystem $temp_file_system
 
ilObject $object = null
 
bool $creation_mode = false
 
 $data
 
int $id
 
bool $call_by_reference = false
 
bool $prepare_output
 
int $ref_id
 
int $obj_id
 
int $maxcount
 
array $form_action = []
 
array $return_location = []
 
array $target_frame = []
 
string $tmp_import_dir
 
string $sub_objects = ""
 
bool $omit_locator = false
 
string $type = ""
 
string $admin_mode = self::ADMIN_MODE_NONE
 
int $requested_ref_id = 0
 
int $requested_crtptrefid = 0
 
int $requested_crtcb = 0
 
string $requested_new_type = ""
 
string $link_params
 
string $html = ""
 

Additional Inherited Members

- Data Fields inherited from ilObject2GUI
const OBJECT_ID = 0
 
const REPOSITORY_NODE_ID = 1
 
const WORKSPACE_NODE_ID = 2
 
const REPOSITORY_OBJECT_ID = 3
 
const WORKSPACE_OBJECT_ID = 4
 
const PORTFOLIO_OBJECT_ID = 5
 
- Data Fields inherited from ilObjectGUI
const ADMIN_MODE_NONE = ""
 
const ADMIN_MODE_SETTINGS = "settings"
 
const ADMIN_MODE_REPOSITORY = "repository"
 
const UPLOAD_TYPE_LOCAL = 1
 
const UPLOAD_TYPE_UPLOAD_DIRECTORY = 2
 
const CFORM_NEW = 1
 
const CFORM_IMPORT = 2
 
const CFORM_CLONE = 3
 
const SUPPORTED_IMPORT_MIME_TYPES = [MimeType::APPLICATION__ZIP, MimeType::APPLICATION__X_ZIP_COMPRESSED]
 

Detailed Description

Portfolio view gui base class.

Author
Jörg Lützenkirchen luetz.nosp@m.enki.nosp@m.rchen.nosp@m.@lei.nosp@m.fos.c.nosp@m.om

Definition at line 28 of file class.ilObjPortfolioBaseGUI.php.

Constructor & Destructor Documentation

◆ __construct()

ilObjPortfolioBaseGUI::__construct ( int  $a_id = 0,
int  $a_id_type = self::REPOSITORY_NODE_ID,
int  $a_parent_node_id = 0 
)

Reimplemented from ilObject2GUI.

Reimplemented in ilObjPortfolioTemplateGUI.

Definition at line 46 of file class.ilObjPortfolioBaseGUI.php.

50 {
51 global $DIC;
52
53 $this->user = $DIC->user();
54 $this->locator = $DIC["ilLocator"];
55 $this->toolbar = $DIC->toolbar();
56 $this->settings = $DIC->settings();
57 $this->tree = $DIC->repositoryTree();
58 $this->help = $DIC["ilHelp"];
59 $this->tpl = $DIC["tpl"];
60 $ilUser = $DIC->user();
61 $this->ui = $DIC->ui();
62
63 $this->port_request = $DIC->portfolio()
64 ->internal()
65 ->gui()
66 ->standardRequest();
67
68 parent::__construct($a_id, $a_id_type, $a_parent_node_id);
69
70 $this->user_id = $ilUser->getId();
71
72 $this->lng->loadLanguageModule("prtf");
73 $this->lng->loadLanguageModule("user");
74 $this->lng->loadLanguageModule("obj");
75
76 $this->requested_ppage = $this->port_request->getPortfolioPageId();
77 $this->requested_user_page = $this->port_request->getUserPage();
78
79 // temp sanitization, should be done smarter in the future
80 $back = str_replace("&", ":::", $this->port_request->getBackUrl());
81 $back = preg_replace(
82 "/[^a-zA-Z0-9_\.\?=:\s]/",
83 "",
84 $back
85 );
86 $this->requested_back_url = str_replace(":::", "&", $back);
87
88 $this->ctrl->setParameterByClass("ilobjportfoliogui", "back_url", rawurlencode($this->requested_back_url));
89 $cs = $DIC->contentStyle();
90 $this->content_style_gui = $cs->gui();
91 if ($this->object) {
92 $this->content_style_domain = $cs->domain()->styleForObjId($this->object->getId());
93 }
94 $this->gui = $DIC->portfolio()->internal()->gui();
95 $this->notes = $DIC->notes();
96 }
__construct(Container $dic, ilPlugin $plugin)
@inheritDoc
global $DIC
Definition: shib_login.php:26

References $DIC, ILIAS\GlobalScreen\Provider\__construct(), ILIAS\Repository\ctrl(), ILIAS\Repository\help(), ILIAS\Repository\lng(), ILIAS\Repository\locator(), ILIAS\Repository\object(), ILIAS\Repository\settings(), ILIAS\Repository\toolbar(), ILIAS\Repository\ui(), and ILIAS\Repository\user().

+ Here is the call graph for this function:

Member Function Documentation

◆ addLocatorItems()

ilObjPortfolioBaseGUI::addLocatorItems ( )
protected

Functions to be overwritten.

Reimplemented from ilObject2GUI.

Definition at line 98 of file class.ilObjPortfolioBaseGUI.php.

98 : void
99 {
100 $ilLocator = $this->locator;
101
102 if ($this->object) {
103 $ilLocator->addItem(
104 strip_tags($this->object->getTitle()),
105 $this->ctrl->getLinkTarget($this, "view")
106 );
107 }
108
109 if ($this->page_id > 0) {
110 $page = $this->getPageInstance($this->page_id);
111 $title = $page->getTitle();
112 $this->ctrl->setParameterByClass($this->getPageGUIClassName(), "ppage", $this->page_id);
113 $ilLocator->addItem(
114 $title,
115 $this->ctrl->getLinkTargetByClass($this->getPageGUIClassName(), "edit")
116 );
117 }
118 }
getPageInstance(?int $a_page_id=null, ?int $a_portfolio_id=null)
ilLocatorGUI $locator

References ilObject2GUI\$locator, ILIAS\Repository\ctrl(), getPageGUIClassName(), getPageInstance(), and ILIAS\Repository\object().

+ Here is the call graph for this function:

◆ addPage()

ilObjPortfolioBaseGUI::addPage ( )
protected

Show portfolio page creation form.

Definition at line 386 of file class.ilObjPortfolioBaseGUI.php.

386 : void
387 {
388 $ilHelp = $this->help;
389
390 $this->tabs_gui->clearTargets();
391 $this->tabs_gui->setBackTarget(
392 $this->lng->txt("back"),
393 $this->ctrl->getLinkTarget($this, "view")
394 );
395
396 $ilHelp->setScreenIdComponent("prtf");
397 $ilHelp->setScreenId("add_page");
398
399
400 $form = $this->initPageForm("create");
401 $this->tpl->setContent($form->getHTML());
402 }
setScreenIdComponent(string $a_comp)
initPageForm(string $a_mode="create")
Init portfolio page form.

References ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ confirmPortfolioPageDeletion()

ilObjPortfolioBaseGUI::confirmPortfolioPageDeletion ( )

Definition at line 515 of file class.ilObjPortfolioBaseGUI.php.

515 : void
516 {
517 $prtf_pages = $this->port_request->getPortfolioPageIds();
518
519 if (count($prtf_pages) === 0) {
520 $this->tpl->setOnScreenMessage('info', $this->lng->txt("no_checkbox"), true);
521 $this->ctrl->redirect($this, "view");
522 } else {
523 $this->tabs_gui->activateTab("pages");
524
525 $cgui = new ilConfirmationGUI();
526 $cgui->setFormAction($this->ctrl->getFormAction($this));
527 $cgui->setHeaderText($this->lng->txt("prtf_sure_delete_portfolio_pages"));
528 $cgui->setCancel($this->lng->txt("cancel"), "view");
529 $cgui->setConfirm($this->lng->txt("delete"), "deletePortfolioPages");
530
531 foreach ($prtf_pages as $id) {
532 $page = $this->getPageInstance($id);
533 if ($page->getPortfolioId() !== $this->object->getId()) {
534 continue;
535 }
536
537 $title = $page->getTitle();
538 $cgui->addItem("prtf_pages[]", $id, $title);
539 }
540
541 $this->tpl->setContent($cgui->getHTML());
542 }
543 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...

References $id, ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ copyPage()

ilObjPortfolioBaseGUI::copyPage ( )

Definition at line 886 of file class.ilObjPortfolioBaseGUI.php.

886 : void
887 {
888 $form = $this->initCopyPageForm();
889 if ($form->checkInput()) {
890 // existing
891 if ($form->getInput("target") === "old") {
892 $portfolio_id = $form->getInput("prtf");
893 }
894 // new
895 else {
896 $portfolio = new ilObjPortfolio();
897 $portfolio->setTitle($form->getInput("title"));
898 $portfolio->create();
899 $portfolio_id = $portfolio->getId();
900 }
901
902 // copy page(s)
903 $page_ids = $this->port_request->getPortfolioPageIds();
904 foreach ($page_ids as $page_id) {
905 $source = $this->getPageInstance($page_id);
906 $target = $this->getPageInstance(null, $portfolio_id);
907 $target->setXMLContent($source->copyXmlContent(true)); // copy mobs
908 $target->setType($source->getType());
909 $target->setTitle($source->getTitle());
910 $target->create();
911 }
912
913 $this->tpl->setOnScreenMessage('success', $this->lng->txt("prtf_pages_copied"), true);
914 $this->ctrl->redirect($this, "view");
915 }
916
917 $form->setValuesByPost();
918 $this->copyPageForm($form);
919 }
copyPageForm(?ilPropertyFormGUI $a_form=null)
Select target portfolio for page(s) copy.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...

References ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ copyPageForm()

ilObjPortfolioBaseGUI::copyPageForm ( ?ilPropertyFormGUI  $a_form = null)

Select target portfolio for page(s) copy.

Definition at line 861 of file class.ilObjPortfolioBaseGUI.php.

863 : void {
864 $prtf_pages = $this->port_request->getPortfolioPageIds();
865
866 if (count($prtf_pages) === 0) {
867 $this->tpl->setOnScreenMessage('info', $this->lng->txt("no_checkbox"), true);
868 $this->ctrl->redirect($this, "view");
869 } else {
870 $this->tabs_gui->activateTab("pages");
871
872 if (!$a_form) {
873 $a_form = $this->initCopyPageForm();
874 }
875
876 foreach ($prtf_pages as $page_id) {
877 $item = new ilHiddenInputGUI("prtf_pages[]");
878 $item->setValue($page_id);
879 $a_form->addItem($item);
880 }
881
882 $this->tpl->setContent($a_form->getHTML());
883 }
884 }
This class represents a hidden form property in a property form.

References ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ deletePortfolioPages()

ilObjPortfolioBaseGUI::deletePortfolioPages ( )

Definition at line 545 of file class.ilObjPortfolioBaseGUI.php.

545 : void
546 {
547 if (!$this->checkPermissionBool("write")) {
548 return;
549 }
550
551 $page_ids = $this->port_request->getPortfolioPageIds();
552 foreach ($page_ids as $id) {
553 $page = $this->getPageInstance($id);
554 $page->delete();
555 }
556 $this->tpl->setOnScreenMessage('success', $this->lng->txt("prtf_portfolio_page_deleted"), true);
557 $this->ctrl->redirect($this, "view");
558 }
checkPermissionBool(string $perm, string $cmd="", string $type="", ?int $node_id=null)

References $id, ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ determinePageCall()

ilObjPortfolioBaseGUI::determinePageCall ( )
protected

Definition at line 120 of file class.ilObjPortfolioBaseGUI.php.

120 : bool
121 {
122 // edit
123 if ($this->requested_ppage > 0) {
124 if (!$this->checkPermissionBool("write")) {
125 $this->ctrl->redirect($this, "view");
126 }
127
128 $this->page_id = $this->requested_ppage;
129 $this->page_mode = "edit";
130 $this->ctrl->setParameter($this, "ppage", $this->page_id);
131 return true;
132 }
133
134 // preview
135 $this->page_id = $this->requested_user_page;
136 $this->page_mode = "preview";
137 $this->ctrl->setParameter($this, "user_page", $this->page_id);
138 return false;
139 }

References $requested_ppage, $requested_user_page, ilObject2GUI\checkPermissionBool(), and ILIAS\Repository\ctrl().

Referenced by ilObjPortfolioTemplateGUI\executeCommand().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ export()

ilObjPortfolioBaseGUI::export ( bool  $a_with_comments = false)

Definition at line 844 of file class.ilObjPortfolioBaseGUI.php.

846 : void {
847 $port_export = new \ILIAS\Portfolio\Export\PortfolioHtmlExport($this);
848 $port_export->includeComments($a_with_comments);
849 $port_export->exportHtml();
850 $port_export->deliver($this->object->getTitle() . ".zip", true);
851 }

◆ exportWithComments()

ilObjPortfolioBaseGUI::exportWithComments ( )

Definition at line 853 of file class.ilObjPortfolioBaseGUI.php.

853 : void
854 {
855 $this->export(true);
856 }
export(bool $a_with_comments=false)

◆ getAdditional()

ilObjPortfolioBaseGUI::getAdditional ( )

Definition at line 188 of file class.ilObjPortfolioBaseGUI.php.

188 : array
189 {
190 return $this->additional;
191 }

References $additional.

◆ getCommentGUI()

ilObjPortfolioBaseGUI::getCommentGUI ( )
protected

Definition at line 738 of file class.ilObjPortfolioBaseGUI.php.

739 {
740 $gui = $this->notes->gui()->getCommentsGUI(
741 $this->object->getId(),
742 $this->getCurrentPage(),
743 "pfpg"
744 );
745 $gui->setRepositoryMode(false);
746 $gui->enablePublicNotesDeletion(($this->user_id === $this->object->getOwner()) &&
747 $this->settings->get("comments_del_tutor", '1'));
748 return $gui;
749 }
ILIAS Portfolio InternalGUIService $gui

References ILIAS\Repository\object(), and ilNoteGUI\setRepositoryMode().

+ Here is the call graph for this function:

◆ getCurrentPage()

ilObjPortfolioBaseGUI::getCurrentPage ( )
protected

Definition at line 710 of file class.ilObjPortfolioBaseGUI.php.

710 : ?int
711 {
712 $pages = ilPortfolioPage::getAllPortfolioPages($this->object->getId());
713 $current_page = (int) $this->requested_user_page;
714
715 // validate current page
716 if ($pages && $current_page) {
717 $found = false;
718 foreach ($pages as $page) {
719 if ((int) $page["id"] === $current_page) {
720 $found = true;
721 break;
722 }
723 }
724 if (!$found) {
725 $current_page = null;
726 }
727 }
728
729 // display first page of portfolio if none given
730 if (!$current_page && $pages) {
731 $current_page = $pages;
732 $current_page = array_shift($current_page);
733 $current_page = (int) $current_page["id"];
734 }
735 return $current_page;
736 }
static getAllPortfolioPages(int $a_portfolio_id)
Get pages of portfolio.

References ilPortfolioPage\getAllPortfolioPages(), ILIAS\Repository\int(), and ILIAS\Repository\object().

+ Here is the call graph for this function:

◆ getEditFormCustomValues()

ilObjPortfolioBaseGUI::getEditFormCustomValues ( array &  $a_values)
protected

Add values to custom edit fields.

Reimplemented from ilObjectGUI.

Reimplemented in ilObjPortfolioGUI, and ilObjPortfolioTemplateGUI.

Definition at line 257 of file class.ilObjPortfolioBaseGUI.php.

257 : void
258 {
259 $a_values["comments"] = $this->object->hasPublicComments();
260 $a_values["ppic"] = $this->object->hasProfilePicture();
261 /*
262 $a_values["bg_color"] = $this->object->getBackgroundColor();
263 $a_values["font_color"] = $this->object->getFontColor();
264 */
265 }

◆ getPageGUIClassName()

ilObjPortfolioBaseGUI::getPageGUIClassName ( )
abstract

Reimplemented in ilObjPortfolioGUI, and ilObjPortfolioTemplateGUI.

Referenced by addLocatorItems().

+ Here is the caller graph for this function:

◆ getPageGUIInstance()

ilObjPortfolioBaseGUI::getPageGUIInstance ( int  $a_page_id)
abstractprotected

Reimplemented in ilObjPortfolioGUI, and ilObjPortfolioTemplateGUI.

Referenced by handlePageCall().

+ Here is the caller graph for this function:

◆ getPageInstance()

ilObjPortfolioBaseGUI::getPageInstance ( ?int  $a_page_id = null,
?int  $a_portfolio_id = null 
)
abstractprotected

Reimplemented in ilObjPortfolioGUI, and ilObjPortfolioTemplateGUI.

Referenced by addLocatorItems().

+ Here is the caller graph for this function:

◆ handlePageCall()

ilObjPortfolioBaseGUI::handlePageCall ( string  $a_cmd)
protected

Definition at line 141 of file class.ilObjPortfolioBaseGUI.php.

141 : void
142 {
143 if (!$this->page_id) {
144 $this->ctrl->redirect($this, "view");
145 }
146
147 $page_gui = $this->getPageGUIInstance($this->page_id);
148
149 $this->tabs_gui->clearTargets();
150 $this->tabs_gui->setBackTarget(
151 $this->lng->txt("back"),
152 $this->ctrl->getLinkTarget($this, "view")
153 );
154
155 // needed for editor
156 $page_gui->setStyleId($this->content_style_domain->getEffectiveStyleId());
157
158 $ret = $this->ctrl->forwardCommand($page_gui);
159 if ($ret != "" && $ret !== true) {
160 // preview (fullscreen)
161 if ($this->page_mode === "preview") {
162 // embedded call which did not generate any output (e.g. calendar month navigation)
164 // suppress (portfolio) notes for blog postings
165 $this->preview(false, $ret, ($a_cmd !== "previewEmbedded"));
166 } else {
167 $this->preview(false);
168 }
169 }
170 // edit
171 else {
172 $this->setContentStyleSheet();
173 if (is_string($ret)) {
174 $this->tpl->setContent($ret);
175 }
176 }
177 }
178 }
getPageGUIInstance(int $a_page_id)
setContentStyleSheet(?ilGlobalTemplateInterface $a_tpl=null)

References ILIAS\Repository\ctrl(), ilPortfolioPageGUI\EMBEDDED_NO_OUTPUT, getPageGUIInstance(), ILIAS\Repository\lng(), ILIAS\UI\examples\Symbol\Glyph\Preview\preview(), and setContentStyleSheet().

Referenced by ilObjPortfolioTemplateGUI\executeCommand().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ initCopyPageForm()

ilObjPortfolioBaseGUI::initCopyPageForm ( )

Definition at line 923 of file class.ilObjPortfolioBaseGUI.php.

924 {
925 $form = new ilPropertyFormGUI();
926 $form->setFormAction($this->ctrl->getFormAction($this));
927 $form->setTitle($this->lng->txt("prtf_copy_page"));
928
929 $this->initCopyPageFormOptions($form);
930
931 $form->addCommandButton("copyPage", $this->lng->txt("save"));
932 $form->addCommandButton("view", $this->lng->txt("cancel"));
933
934 return $form;
935 }
initCopyPageFormOptions(ilPropertyFormGUI $a_form)
This class represents a property form user interface.

References ILIAS\Repository\ctrl(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ initCopyPageFormOptions()

ilObjPortfolioBaseGUI::initCopyPageFormOptions ( ilPropertyFormGUI  $a_form)
abstractprotected

◆ initEditCustomForm()

ilObjPortfolioBaseGUI::initEditCustomForm ( ilPropertyFormGUI  $a_form)
protected

Add custom fields to update form.

Reimplemented from ilObjectGUI.

Definition at line 229 of file class.ilObjPortfolioBaseGUI.php.

229 : void
230 {
231 $this->setSettingsSubTabs("properties");
232
233
234 // profile picture
235 $ppic = new ilCheckboxInputGUI($this->lng->txt("prtf_profile_picture"), "ppic");
236 $a_form->addItem($ppic);
237
238 $prfa_set = new ilSetting("prfa");
239
240 $section = new ilFormSectionHeaderGUI();
241 $section->setTitle($this->lng->txt('obj_features'));
242 $a_form->addItem($section);
243
244 // comments
245 $comments = new ilCheckboxInputGUI($this->lng->txt("prtf_public_comments"), "comments");
246 $a_form->addItem($comments);
247
248 /* #15000
249 $bg_color = new ilColorPickerInputGUI($this->lng->txt("prtf_background_color"), "bg_color");
250 $a_form->addItem($bg_color);
251
252 $font_color = new ilColorPickerInputGUI($this->lng->txt("prtf_font_color"), "font_color");
253 $a_form->addItem($font_color);
254 */
255 }
This class represents a checkbox property in a property form.
This class represents a section header in a property form.
ILIAS Setting Class.
$comments

References $comments, ilPropertyFormGUI\addItem(), and ILIAS\Repository\lng().

+ Here is the call graph for this function:

◆ initPageForm()

ilObjPortfolioBaseGUI::initPageForm ( string  $a_mode = "create")

Init portfolio page form.

Definition at line 407 of file class.ilObjPortfolioBaseGUI.php.

408 {
409 $form = new ilPropertyFormGUI();
410 $form->setFormAction($this->ctrl->getFormAction($this));
411
412 // title
413 $ti = new ilTextInputGUI($this->lng->txt("title"), "title");
414 $ti->setMaxLength(200);
415 $ti->setRequired(true);
416 $form->addItem($ti);
417
418 // save and cancel commands
419 if ($a_mode === "create") {
421 if ($templates) {
422 $use_template = new ilRadioGroupInputGUI($this->lng->txt("prtf_use_page_layout"), "tmpl");
423 $use_template->setRequired(true);
424 $form->addItem($use_template);
425
426 $opt = new ilRadioOption($this->lng->txt("none"), 0);
427 $use_template->addOption($opt);
428
429 foreach ($templates as $templ) {
430 $templ->readObject();
431
432 $opt = new ilRadioOption($templ->getTitle() . $templ->getPreview(), $templ->getId());
433 $use_template->addOption($opt);
434 }
435 }
436
437 $form->setTitle($this->lng->txt("prtf_add_page") . ": " .
438 $this->object->getTitle());
439 $form->addCommandButton("savePage", $this->lng->txt("save"));
440 $form->addCommandButton("view", $this->lng->txt("cancel"));
441 }
442
443 return $form;
444 }
static activeLayouts(int $a_module=0)
Get active layouts.
This class represents a property in a property form.
This class represents an option in a radio group.
This class represents a text property in a property form.

References ilPageLayout\activeLayouts(), ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), and ilPageLayout\MODULE_PORTFOLIO.

+ Here is the call graph for this function:

◆ renderFullscreenHeader()

static ilObjPortfolioBaseGUI::renderFullscreenHeader ( ilObjPortfolioBase  $a_portfolio,
ilGlobalTemplateInterface  $a_tpl,
int  $a_user_id,
bool  $a_export = false 
)
static

Definition at line 794 of file class.ilObjPortfolioBaseGUI.php.

799 : void {
800 global $DIC;
801
802 $ilUser = $DIC->user();
803
804 if (!$a_export) {
806 $a_portfolio->getType(),
807 ($a_portfolio->getType() === "prtt")
808 ? $a_portfolio->getRefId()
809 : $a_portfolio->getId(),
810 $a_portfolio->getId(),
811 $ilUser->getId()
812 );
813 }
814
815 $name = ilObjUser::_lookupName($a_user_id);
816 $name = $name["lastname"] . ", " . (($t = $name["title"]) ? $t . " " : "") . $name["firstname"];
817
818 $prfa_set = new ilSetting("prfa");
819
820 // profile picture
821 $ppic = null;
822 if ($a_portfolio->hasProfilePicture()) {
823 $ppic = ilObjUser::_getPersonalPicturePath($a_user_id, "xsmall", true, true);
824 if ($a_export) {
825 $ppic = basename($ppic);
826 }
827 }
828
829 $a_tpl->resetHeaderBlock(false);
830 // $a_tpl->setBackgroundColor($a_portfolio->getBackgroundColor());
831 // @todo fix this
832 $a_tpl->setTitleIcon((string) $ppic);
833 $a_tpl->setTitle($a_portfolio->getTitle());
834 // $a_tpl->setTitleColor($a_portfolio->getFontColor());
835 $a_tpl->setDescription($name);
836
837 // to get rid of locator in portfolio template preview
838 $a_tpl->setVariable("LOCATOR", "");
839
840 // :TODO: obsolete?
841 // $a_tpl->setBodyClass("std ilExternal ilPortfolio");
842 }
static _recordReadEvent(string $a_type, int $a_ref_id, int $obj_id, int $usr_id, bool $isCatchupWriteEvents=true, $a_ext_rc=null, $a_ext_time=null)
static _lookupName(int $a_user_id)
static _getPersonalPicturePath(int $a_usr_id, string $a_size='small', bool $a_force_pic=false)
setDescription(string $a_descr)
Sets description below title in standard template.
setVariable(string $variable, $value='')
Sets the given variable to the given value.
setTitle(string $a_title, bool $hidden=false)
Sets title in standard template.
setTitleIcon(string $a_icon_path, string $a_icon_desc="")
set title icon
resetHeaderBlock(bool $a_reset_header_action=true)
Reset all header properties: title, icon, description, alerts, action menu.

References ilChangeEvent\_recordReadEvent(), ilObject\getId(), ilObject\getRefId(), and ilObject\getType().

+ Here is the call graph for this function:

◆ savePage()

ilObjPortfolioBaseGUI::savePage ( )

Create new portfolio page.

Definition at line 449 of file class.ilObjPortfolioBaseGUI.php.

449 : void
450 {
451 $form = $this->initPageForm("create");
452 if ($form->checkInput() && $this->checkPermissionBool("write")) {
453 $page = $this->getPageInstance();
454 $page->setType(ilPortfolioPage::TYPE_PAGE);
455 $page->setTitle($form->getInput("title"));
456
457 // use template as basis
458 $layout_id = $form->getInput("tmpl");
459 if ($layout_id) {
460 $layout_obj = new ilPageLayout($layout_id);
461 $page->setXMLContent($layout_obj->copyXmlContent(false));
462 }
463
464 $page->create();
465
466 $this->tpl->setOnScreenMessage('success', $this->lng->txt("prtf_page_created"), true);
467 $this->ctrl->redirect($this, "view");
468 }
469
470 $this->tabs_gui->clearTargets();
471 $this->tabs_gui->setBackTarget(
472 $this->lng->txt("back"),
473 $this->ctrl->getLinkTarget($this, "view")
474 );
475
476 $form->setValuesByPost();
477 $this->tpl->setContent($form->getHTML());
478 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...

References ILIAS\Repository\ctrl(), ILIAS\Repository\lng(), and ilPortfolioPage\TYPE_PAGE.

+ Here is the call graph for this function:

◆ savePortfolioPagesOrdering()

ilObjPortfolioBaseGUI::savePortfolioPagesOrdering ( )

Save ordering of portfolio pages.

Definition at line 483 of file class.ilObjPortfolioBaseGUI.php.

483 : void
484 {
485 if (!$this->checkPermissionBool("write")) {
486 return;
487 }
488
489 $title_changes = array();
490
491 $order = $this->port_request->getOrder();
492 $titles = $this->port_request->getTitles();
493 if (count($order) > 0) {
494 foreach ($order as $k => $v) {
495 $page = $this->getPageInstance(ilUtil::stripSlashes($k));
496 if ($titles[$k] ?? "") {
497 $new_title = $titles[$k] ?? "";
498 if ($page->getTitle() != $new_title) {
499 $title_changes[$page->getId()] = array("old" => $page->getTitle(), "new" => $new_title);
500 $page->setTitle($new_title);
501 }
502 }
503 $page->setOrderNr(ilUtil::stripSlashes($v));
504 $page->update();
505 }
506 ilPortfolioPage::fixOrdering($this->object->getId());
507 }
508
509 $this->object->fixLinksOnTitleChange($title_changes);
510
511 $this->tpl->setOnScreenMessage('success', $this->lng->txt("msg_obj_modified"), true);
512 $this->ctrl->redirect($this, "view");
513 }
static fixOrdering(int $a_portfolio_id)
static stripSlashes(string $a_str, bool $a_strip_html=true, string $a_allow="")

References ILIAS\Repository\ctrl(), ilPortfolioPage\fixOrdering(), ILIAS\Repository\lng(), ILIAS\Repository\object(), and ilUtil\stripSlashes().

+ Here is the call graph for this function:

◆ setAdditional()

ilObjPortfolioBaseGUI::setAdditional ( array  $a_additional)

Set Additonal Information (used in public profile?)

Definition at line 183 of file class.ilObjPortfolioBaseGUI.php.

183 : void
184 {
185 $this->additional = $a_additional;
186 }

◆ setContentStyleSheet()

ilObjPortfolioBaseGUI::setContentStyleSheet ( ?ilGlobalTemplateInterface  $a_tpl = null)

Definition at line 942 of file class.ilObjPortfolioBaseGUI.php.

944 : void {
946
947 if ($a_tpl) {
948 $ctpl = $a_tpl;
949 } else {
950 $ctpl = $tpl;
951 }
952
953 $this->content_style_gui->addCss(
954 $ctpl,
955 $this->object->getRefId(),
956 $this->object->getId()
957 );
958 }
ilGlobalTemplateInterface $tpl
addCss(string $a_css_file, string $media="screen")
Add a css file that should be included in the header.

Referenced by handlePageCall().

+ Here is the caller graph for this function:

◆ setPermaLink()

ilObjPortfolioBaseGUI::setPermaLink ( int  $a_obj_id,
string  $a_type 
)

Set custom perma link (used in public profile?)

Definition at line 196 of file class.ilObjPortfolioBaseGUI.php.

199 : void {
200 $this->perma_link = array("obj_id" => $a_obj_id, "type" => $a_type);
201 }

◆ setSettingsSubTabs()

ilObjPortfolioBaseGUI::setSettingsSubTabs ( string  $a_active)
protected

Definition at line 208 of file class.ilObjPortfolioBaseGUI.php.

208 : void
209 {
210 // #17455
211 $this->lng->loadLanguageModule($this->getType());
212
213 // general properties
214 $this->tabs_gui->addSubTab(
215 "properties",
216 $this->lng->txt($this->getType() . "_properties"),
217 $this->ctrl->getLinkTarget($this, 'edit')
218 );
219
220 $this->tabs_gui->addSubTab(
221 "style",
222 $this->lng->txt("obj_sty"),
223 $this->ctrl->getLinkTargetByClass("ilobjectcontentstylesettingsgui", "")
224 );
225
226 $this->tabs_gui->activateSubTab($a_active);
227 }
getType()
Functions that must be overwritten.

References ILIAS\Repository\lng().

Referenced by ilObjPortfolioTemplateGUI\executeCommand().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ showEditButton()

ilObjPortfolioBaseGUI::showEditButton ( int  $page_id)
protected

Definition at line 751 of file class.ilObjPortfolioBaseGUI.php.

753 : void {
754 $page_class = ($this->getType() === "prtt")
755 ? "ilPortfolioTemplatePageGUI"
756 : "ilportfoliopagegui";
757 $button = null;
758 if ($this->checkPermissionBool("write") &&
760 if ($this->getType() === "prtt") {
761 $button = $this->ui->factory()->button()->standard(
762 $this->lng->txt("prtt_edit"),
763 $this->ctrl->getLinkTargetByClass(["ilobjportfoliotemplategui"], "view")
764 );
765 } else {
766 $button = $this->ui->factory()->button()->standard(
767 $this->lng->txt("prtf_edit_portfolio"),
768 $this->ctrl->getLinkTargetByClass([
769 ilDashboardGUI::class,
770 ilPortfolioRepositoryGUI::class,
771 ilObjPortfolioGUI::class
772 ], "view")
773 );
774 }
775 $this->toolbar->addComponent($button);
776 $button = null;
777 }
779 $this->ctrl->setParameterByClass($page_class, "ppage", $page_id);
780 $button = $this->ui->factory()->button()->standard(
781 $this->lng->txt("edit_page"),
782 $this->ctrl->getLinkTargetByClass($page_class, "edit")
783 );
784 if ($this->checkPermissionBool("write")) {
785 $this->toolbar->addComponent($button);
786 }
787 $button = null;
788 }
789 if ($button && $this->checkPermissionBool("write")) {
790 $this->tpl->setHeaderActionMenu($this->ui->renderer()->render($button));
791 }
792 }
static lookupType($a_page_id)

References ILIAS\Repository\lng(), ILIAS\Repository\toolbar(), and ILIAS\Repository\ui().

+ Here is the call graph for this function:

◆ updateCustom()

ilObjPortfolioBaseGUI::updateCustom ( ilPropertyFormGUI  $form)
protected

Insert custom update form values into object.

Reimplemented from ilObjectGUI.

Reimplemented in ilObjPortfolioGUI, and ilObjPortfolioTemplateGUI.

Definition at line 267 of file class.ilObjPortfolioBaseGUI.php.

267 : void
268 {
269 $this->object->setPublicComments($form->getInput("comments"));
270 $this->object->setProfilePicture($form->getInput("ppic"));
271 $prfa_set = new ilSetting("prfa");
272 }
getInput(string $a_post_var, bool $ensureValidation=true)
Returns the input of an item, if item provides getInput method and as fallback the value of the HTTP-...

References ilPropertyFormGUI\getInput().

+ Here is the call graph for this function:

◆ view()

ilObjPortfolioBaseGUI::view ( )

Show list of portfolio pages.

Reimplemented from ilObject2GUI.

Definition at line 291 of file class.ilObjPortfolioBaseGUI.php.

291 : void
292 {
293 $ilToolbar = $this->toolbar;
296
297 if (!$this->checkPermissionBool("write")) {
298 $this->ctrl->redirect($this, "infoScreen");
299 }
300
301 $this->tabs_gui->activateTab("pages");
302
304
305 $this->gui->button(
306 $this->lng->txt("prtf_add_page"),
307 $this->ctrl->getLinkTarget($this, "addPage")
308 )->toToolbar(true);
309
310
311 // #16571
312 $modal_html = "";
313 if ($this->getType() === "prtf" && count($pages) > 0) {
314 $ilToolbar->addSeparator();
315
316 $ui = $this->ui;
317
318 if ($this->object->isCommentsExportPossible()) {
319 $this->lng->loadLanguageModule("note");
320 $comment_export_helper = new \ILIAS\Notes\Export\ExportHelperGUI();
321 $comment_modal = $comment_export_helper->getCommentIncludeModalDialog(
322 $this->lng->txt("export_html"),
323 $this->lng->txt("note_html_export_include_comments"),
324 $this->ctrl->getLinkTarget($this, "export"),
325 $this->ctrl->getLinkTarget($this, "exportWithComments")
326 );
327 $button = $ui->factory()->button()->standard($this->lng->txt("export_html"), '')
328 ->withOnClick($comment_modal->getShowSignal());
329 $ilToolbar->addComponent($button);
330 $modal_html = $ui->renderer()->render($comment_modal);
331 } else {
332 $this->gui->button(
333 $this->lng->txt("export_html"),
334 $this->ctrl->getLinkTarget($this, "export")
335 )->toToolbar();
336 }
337
338 $print_view = $this->getPrintView();
339 $modal_elements = $print_view->getModalElements($this->ctrl->getLinkTarget(
340 $this,
341 "printSelection"
342 ));
343 $modal_html .= $ui->renderer()->render($modal_elements->modal);
344 $ilToolbar->addComponent($modal_elements->button);
345 }
346
347 $table = new ilPortfolioPageTableGUI($this, "view");
348
349
350 $this->tpl->setContent($table->getHTML() . $modal_html);
351 }
ilToolbarGUI $toolbar
ilSetting $settings
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
global $ilSetting
Definition: privfeed.php:31

References $ilSetting, $lng, ILIAS\Repository\ctrl(), ilPortfolioPage\getAllPortfolioPages(), ILIAS\Survey\Mode\getId(), ILIAS\Repository\lng(), and ILIAS\Repository\object().

+ Here is the call graph for this function:

Field Documentation

◆ $additional

array ilObjPortfolioBaseGUI::$additional = array()
protected

Definition at line 35 of file class.ilObjPortfolioBaseGUI.php.

Referenced by getAdditional().

◆ $content_style_domain

ILIAS Style Content Object ObjectFacade ilObjPortfolioBaseGUI::$content_style_domain
protected

Definition at line 44 of file class.ilObjPortfolioBaseGUI.php.

◆ $content_style_gui

ILIAS Style Content GUIService ilObjPortfolioBaseGUI::$content_style_gui
protected

Definition at line 43 of file class.ilObjPortfolioBaseGUI.php.

◆ $gui

ILIAS Portfolio InternalGUIService ilObjPortfolioBaseGUI::$gui
protected

◆ $help

ilHelpGUI ilObjPortfolioBaseGUI::$help
protected

Definition at line 33 of file class.ilObjPortfolioBaseGUI.php.

◆ $notes

ILIAS Notes Service ilObjPortfolioBaseGUI::$notes
protected

Definition at line 30 of file class.ilObjPortfolioBaseGUI.php.

◆ $page_id

int ilObjPortfolioBaseGUI::$page_id = 0
protected

Definition at line 37 of file class.ilObjPortfolioBaseGUI.php.

◆ $page_mode

string ilObjPortfolioBaseGUI::$page_mode
protected

Definition at line 38 of file class.ilObjPortfolioBaseGUI.php.

◆ $perma_link

array ilObjPortfolioBaseGUI::$perma_link = []
protected

Definition at line 36 of file class.ilObjPortfolioBaseGUI.php.

◆ $port_request

StandardGUIRequest ilObjPortfolioBaseGUI::$port_request
protected

Definition at line 32 of file class.ilObjPortfolioBaseGUI.php.

◆ $requested_back_url

string ilObjPortfolioBaseGUI::$requested_back_url = ""
protected

Definition at line 41 of file class.ilObjPortfolioBaseGUI.php.

◆ $requested_ppage

int ilObjPortfolioBaseGUI::$requested_ppage
protected

Definition at line 39 of file class.ilObjPortfolioBaseGUI.php.

Referenced by determinePageCall().

◆ $requested_user_page

int ilObjPortfolioBaseGUI::$requested_user_page
protected

Definition at line 40 of file class.ilObjPortfolioBaseGUI.php.

Referenced by determinePageCall().

◆ $ui

ILIAS DI UIServices ilObjPortfolioBaseGUI::$ui
protected

Definition at line 42 of file class.ilObjPortfolioBaseGUI.php.

◆ $user_id

int ilObjPortfolioBaseGUI::$user_id = 0
protected

Definition at line 34 of file class.ilObjPortfolioBaseGUI.php.


The documentation for this class was generated from the following file: