ILIAS  release_5-1 Revision 5.0.0-5477-g43f3e3fab5f
ilDataCollectionRecordViewViewdefinitionGUI Class Reference

Class ilDataCollectionRecordViewViewdefinitionGUI. More...

+ Inheritance diagram for ilDataCollectionRecordViewViewdefinitionGUI:
+ Collaboration diagram for ilDataCollectionRecordViewViewdefinitionGUI:

Public Member Functions

 executeCommand ()
 execute command More...
 
 confirmDelete ()
 confirmDelete More...
 
 cancelDelete ()
 cancelDelete More...
 
 deleteView ()
 
 releasePageLock ()
 Release page lock overwrite to redirect properly. More...
 
 postOutputProcessing ($a_output)
 Finalizing output processing. More...
 
- Public Member Functions inherited from ilPageObjectGUI
 ilPageObjectGUI ($a_parent_type, $a_id, $a_old_nr=0, $a_prevent_get_id=false, $a_lang="")
 Constructor. More...
 
 afterConstructor ()
 After constructor. More...
 
 setParentType ($a_val)
 Set parent type. More...
 
 getParentType ()
 Get parent type. More...
 
 setId ($a_val)
 Set ID. More...
 
 getId ()
 Get ID. More...
 
 setOldNr ($a_val)
 Set old nr (historic page) More...
 
 getOldNr ()
 Get old nr (historic page) More...
 
 setLanguage ($a_val)
 Set language. More...
 
 getLanguage ()
 Get language. More...
 
 setEnablePCType ($a_pc_type, $a_val)
 Set enable pc type. More...
 
 getEnablePCType ($a_pc_type)
 Get enable pc type. More...
 
 setPageConfig ($a_val)
 Set page config object. More...
 
 getPageConfig ()
 Get page config object. More...
 
 setBibId ($a_id)
 Set Bib Id. More...
 
 getBibId ()
 Get Bib Id. More...
 
 setPageObject ($a_pg_obj)
 Set Page Object. More...
 
 getPageObject ()
 Get Page Object. More...
 
 setOutputMode ($a_mode=IL_PAGE_PRESENTATION)
 Set Output Mode. More...
 
 getOutputMode ()
 
 setTemplateOutput ($a_output=true)
 
 outputToTemplate ()
 
 setPresentationTitle ($a_title="")
 
 getPresentationTitle ()
 
 setHeader ($a_title="")
 
 getHeader ()
 
 setLinkParams ($l_params="")
 
 getLinkParams ()
 
 setLinkFrame ($l_frame="")
 
 getLinkFrame ()
 
 setLinkXML ($link_xml)
 
 getLinkXML ()
 
 setQuestionXML ($question_xml)
 
 setQuestionHTML ($question_html)
 
 getQuestionXML ()
 
 getQuestionHTML ()
 
 setTemplateTargetVar ($a_variable)
 
 getTemplateTargetVar ()
 
 setTemplateOutputVar ($a_value)
 
 getTemplateOutputVar ()
 
 setSourcecodeDownloadScript ($script_name)
 
 getSourcecodeDownloadScript ()
 
 enableCitation ($a_enabled)
 
 isEnabledCitation ()
 
 setLocator (&$a_locator)
 
 setTabs ($a_tabs)
 
 setPageBackTitle ($a_title)
 
 setFileDownloadLink ($a_download_link)
 
 getFileDownloadLink ()
 
 setFullscreenLink ($a_fullscreen_link)
 
 getFullscreenLink ()
 
 setIntLinkReturn ($a_return)
 
 enableChangeComments ($a_enabled)
 
 isEnabledChangeComments ()
 
 enableNotes ($a_enabled, $a_parent_id)
 
 isEnabledNotes ()
 
 setOfflineDirectory ($offdir)
 set offline directory to offdir More...
 
 getOfflineDirectory ()
 get offline directory More...
 
 setViewPageLink ($a_link, $a_target="")
 set link for "view page" button More...
 
 getViewPageLink ()
 get view page link More...
 
 getViewPageTarget ()
 get view page target frame More...
 
 setActivationListener (&$a_obj, $a_meth)
 
 setEnabledNews ($a_enabled, $a_news_obj_id=0, $a_news_obj_type=0)
 Set enabled news. More...
 
 getEnabledNews ()
 Get enabled news. More...
 
 setTabHook ($a_object, $a_function)
 Set tab hook. More...
 
 setEditPreview ($a_editpreview)
 Set Display first Edit tab, then Preview tab, instead of Page and Edit. More...
 
 getEditPreview ()
 Get Display first Edit tab, then Preview tab, instead of Page and Edit. More...
 
 setEnabledTabs ($a_enabledtabs)
 Set Output tabs. More...
 
 getEnabledTabs ()
 Get Output tabs. More...
 
 setEnabledPageFocus ($a_enabledpagefocus)
 Set Enable page focus. More...
 
 getEnabledPageFocus ()
 Get Enable page focus. More...
 
 setExplorerUpdater ($a_exp_frame, $a_exp_id, $a_exp_target_script)
 Set Explorer Updater. More...
 
 setPrependingHtml ($a_prependinghtml)
 Set Prepending HTML. More...
 
 getPrependingHtml ()
 Get Prepending HTML. More...
 
 setEnableEditing ($a_enableediting)
 Set Enable Editing. More...
 
 getEnableEditing ()
 Get Enable Editing. More...
 
 setRawPageContent ($a_rawpagecontent)
 Set Get raw page content only. More...
 
 getRawPageContent ()
 Get Get raw page content only. More...
 
 setStyleId ($a_styleid)
 Set Style Id. More...
 
 getStyleId ()
 Get Style Id. More...
 
 setCompareMode ($a_val)
 Set compare mode. More...
 
 getCompareMode ()
 Get compare mode. More...
 
 setAbstractOnly ($a_val)
 Set abstract only. More...
 
 getAbstractOnly ()
 Get abstract only. More...
 
 setRenderPageContainer ($a_val)
 Set render page container. More...
 
 getRenderPageContainer ()
 Get render page container. More...
 
 activateMetaDataEditor ($a_rep_obj, $a_type, $a_sub_obj_id, $a_observer_obj=NULL, $a_observer_func="")
 Activate meda data editor. More...
 
 determineFileDownloadLink ()
 Determine file download link. More...
 
 determineFullscreenLink ()
 Determine fullscreen link. More...
 
 determineSourcecodeDownloadScript ()
 Determine source code download script. More...
 
 getComponentPluginsXML ()
 Put information about activated plugins into XML. More...
 
executeCommand ()
 execute command More...
 
 setQEditTabs ($a_active)
 Set question editing tabs. More...
 
 onFeedbackEditingForwarding ()
 On feedback editing forwarding. More...
 
 deactivatePage ()
 
 activatePage ()
 
 showPage ()
 display content of page More...
 
 replaceCurlyBrackets ($output)
 Replace curly brackets. More...
 
 addActionsMenu ($a_tpl, $sel_media_mode, $sel_html_mode, $sel_js_mode)
 Add actions menu. More...
 
 addMultiLangActionsAndInfo ($a_list, $a_tpl)
 Add multi-language actions to menu. More...
 
 setEditMode ()
 Set edit mode. More...
 
 setDefaultLinkXml ()
 Set standard link xml. More...
 
 downloadFile ()
 Download file of file lists. More...
 
 displayMediaFullscreen ()
 Show media in fullscreen mode. More...
 
 displayMedia ($a_fullscreen=false)
 Display media. More...
 
 download_paragraph ()
 download source code paragraph More...
 
 insertContentIncludes ($a_html)
 Insert content includes. More...
 
 insertPageToc ($a_output)
 Insert page toc. More...
 
 insertResources ($a_output)
 Insert resources. More...
 
 insertAdvTrigger ($a_output)
 Insert adv content trigger. More...
 
 postOutputProcessing ($a_output)
 Finalizing output processing. More...
 
 insertHelp ($a_tpl)
 Insert help texts. More...
 
 previewHistory ()
 Preview history. More...
 
 preview ()
 preview More...
 
 edit ()
 edit ("view" before) More...
 
 insertJSAtPlaceholder ()
 InsertJS at placeholder. More...
 
 presentation ($a_mode=IL_PAGE_PRESENTATION)
 
 getHTML ()
 
 showMediaFullscreen ($a_style_id=0)
 show fullscreen view of media object More...
 
 displayValidationError ($a_error)
 display validation error More...
 
 history ()
 Get history table as HTML. More...
 
 rollbackConfirmation ()
 Rollback confirmation. More...
 
 rollback ()
 Rollback to a previous version. More...
 
 setScreenIdComponent ()
 Set screen id component. More...
 
 getTabs ($a_activate="")
 adds tabs to tab gui object More...
 
 compareVersion ()
 Compares two revisions of the page. More...
 
 replaceDiffTags ($a_html)
 
 editActivation ()
 Edit activation (only, if scheduled page activation is activated in administration) More...
 
 initActivationForm ()
 Init activation form. More...
 
 getActivationFormValues ()
 Get values for activation form. More...
 
 saveActivation ()
 Save Activation. More...
 
 getNotesHTML ($a_content_object=null, $a_enable_private_notes=true, $a_enable_public_notes=false, $a_enable_notes_deletion=false, $a_callback=null)
 Get html for public and/or private notes. More...
 
 processAnswer ()
 Process answer. More...
 
 initialOpenedContent ()
 Initially opened content. More...
 
 initOpenedContentForm ()
 Init form for initially opened content. More...
 
 saveInitialOpenedContent ()
 Save initial opened content. More...
 
 switchToLanguage ()
 Switch to language. More...
 
 confirmPageTranslationCreation ()
 Confirm page translation creation. More...
 
 editMasterLanguage ()
 Edit master language. More...
 
 createPageTranslation ()
 Create page translation. More...
 
 releasePageLock ()
 Release page lock. More...
 

Data Fields

 $ctrl
 
- Data Fields inherited from ilPageObjectGUI
 $tpl
 
 $lng
 
 $ctrl
 
 $obj
 
 $output_mode
 
 $presentation_title
 
 $target_script
 
 $return_location
 
 $target_var
 
 $template_output_var
 
 $output2template
 
 $link_params
 
 $bib_id
 
 $citation
 
 $sourcecode_download_script
 
 $change_comments
 
 $question_html
 
 $activation = false
 
 $activated = true
 
 $editpreview = false
 
 $use_meta_data = false
 
 $link_xml_set = false
 
 $enableediting = true
 
 $rawpagecontent = false
 
 $enabledcontentincludes = false
 
 $compare_mode = false
 
 $page_config = null
 
 $tabs_enabled = true
 
 $render_page_container = false
 
 $pl_start = "{{{{{"
 
 $pl_end = "}}}}}"
 

Protected Member Functions

 activate ()
 
 deactivate ()
 
- Protected Member Functions inherited from ilPageObjectGUI
 initPageObject ()
 Init page object. More...
 
 getActivationCaptions ()
 Get captions for activation action menu entries. More...
 
 isPageContainerToBeRendered ()
 

Protected Attributes

 $obj_id
 
 $table_id
 
- Protected Attributes inherited from ilPageObjectGUI
 $parent_type = ""
 
 $log
 

Additional Inherited Members

- Static Public Member Functions inherited from ilPageObjectGUI
static getTinyMenu ($a_par_type, $a_int_links=false, $a_wiki_links=false, $a_keywords=false, $a_style_id=0, $a_paragraph_styles=true, $a_save_return=true, $a_anchors=false, $a_save_new=true, $a_user_links=false)
 Get Tiny Menu. More...
 

Detailed Description

Member Function Documentation

◆ activate()

ilDataCollectionRecordViewViewdefinitionGUI::activate ( )
protected

Definition at line 139 of file class.ilDataCollectionRecordViewViewdefinitionGUI.php.

139 {
140 $page = $this->getPageObject();
141 $page->setActive(true);
142 $page->update();
143 $this->ctrl->redirect($this, 'edit');
144 }
getPageObject()
Get Page Object.

References ilPageObjectGUI\getPageObject().

+ Here is the call graph for this function:

◆ cancelDelete()

ilDataCollectionRecordViewViewdefinitionGUI::cancelDelete ( )

cancelDelete

Definition at line 178 of file class.ilDataCollectionRecordViewViewdefinitionGUI.php.

178 {
179 global $ilCtrl;
180
181 $ilCtrl->redirect($this, "edit");
182 }
global $ilCtrl
Definition: ilias.php:18

References $ilCtrl.

◆ confirmDelete()

ilDataCollectionRecordViewViewdefinitionGUI::confirmDelete ( )

confirmDelete

Definition at line 158 of file class.ilDataCollectionRecordViewViewdefinitionGUI.php.

158 {
159 global $ilCtrl, $lng, $tpl;
160
161 include_once './Services/Utilities/classes/class.ilConfirmationGUI.php';
162 $conf = new ilConfirmationGUI();
163 $conf->setFormAction($ilCtrl->getFormAction($this));
164 $conf->setHeaderText($lng->txt('dcl_confirm_delete_view_title'));
165
166 $conf->addItem('table', (int)$this->table_id, $lng->txt('dcl_confirm_delete_view_text'));
167
168 $conf->setConfirm($lng->txt('delete'), 'deleteView');
169 $conf->setCancel($lng->txt('cancel'), 'cancelDelete');
170
171 $tpl->setContent($conf->getHTML());
172 }
Confirmation screen class.

References $ilCtrl, ilPageObjectGUI\$lng, and ilPageObjectGUI\$tpl.

◆ deactivate()

ilDataCollectionRecordViewViewdefinitionGUI::deactivate ( )
protected

Definition at line 147 of file class.ilDataCollectionRecordViewViewdefinitionGUI.php.

147 {
148 $page = $this->getPageObject();
149 $page->setActive(false);
150 $page->update();
151 $this->ctrl->redirect($this, 'edit');
152 }

References ilPageObjectGUI\getPageObject().

+ Here is the call graph for this function:

◆ deleteView()

ilDataCollectionRecordViewViewdefinitionGUI::deleteView ( )

Definition at line 185 of file class.ilDataCollectionRecordViewViewdefinitionGUI.php.

185 {
186 global $ilCtrl, $lng;
187
188 if ($this->table_id && ilDataCollectionRecordViewViewdefinition::getIdByTableId($this->table_id)) {
190 include_once("./Modules/DataCollection/classes/class.ilDataCollectionRecordViewViewdefinition.php");
191 $pageObject = new ilDataCollectionRecordViewViewdefinition($id);
192 $pageObject->removeDclView($this->table_id);
193 $pageObject->delete();
194 }
195
196 ilUtil::sendSuccess($lng->txt("dcl_empty_view_success"), true);
197
198 $ilCtrl->redirectByClass("ilDataCollectionFieldListGUI", "listFields");
199 }
static getIdByTableId($a_table_id)
Get view definition id by table id.
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.

References $ilCtrl, ilPageObjectGUI\$lng, ilDataCollectionRecordViewViewdefinition\getIdByTableId(), and ilUtil\sendSuccess().

+ Here is the call graph for this function:

◆ executeCommand()

ilDataCollectionRecordViewViewdefinitionGUI::executeCommand ( )

execute command

Reimplemented from ilPageObjectGUI.

Definition at line 80 of file class.ilDataCollectionRecordViewViewdefinitionGUI.php.

80 {
81 global $ilLocator, $lng;
82
83 $next_class = $this->ctrl->getNextClass($this);
84
85 $viewdef = $this->getPageObject();
86 if ($viewdef) {
87 $this->ctrl->setParameter($this, "dclv", $viewdef->getId());
88 $title = $lng->txt("dcl_view_viewdefinition");
89 }
90
91 switch ($next_class) {
92 case "ilpageobjectgui":
93 throw new ilCOPageException("Deprecated. ilDataCollectionRecordViewViewdefinitionGUI gui forwarding to ilpageobject");
94 default:
95 if ($viewdef) {
96 $this->setPresentationTitle($title);
97 $ilLocator->addItem($title, $this->ctrl->getLinkTarget($this, "preview"));
98 }
99
100 return parent::executeCommand();
101 }
102 }
Base exception class for copage service.
setPresentationTitle($a_title="")

References ilPageObjectGUI\$lng, ilPageObjectGUI\getPageObject(), and ilPageObjectGUI\setPresentationTitle().

+ Here is the call graph for this function:

◆ postOutputProcessing()

ilDataCollectionRecordViewViewdefinitionGUI::postOutputProcessing (   $a_output)

Finalizing output processing.

Parameters
string$a_output
Returns
string

Reimplemented from ilPageObjectGUI.

Definition at line 221 of file class.ilDataCollectionRecordViewViewdefinitionGUI.php.

221 {
222 // You can use this to parse placeholders and the like before outputting
223
224 // user view (IL_PAGE_PRESENTATION?)
225 if ($this->getOutputMode() == IL_PAGE_PREVIEW) {
226 //page preview is not being used inside DataCollections - if you are here, something's probably wrong
227
228// include_once "Services/Form/classes/class.ilPropertyFormGUI.php";
229//
230// // :TODO: find a suitable presentation for matched placeholders
231// $allp = ilDataCollectionRecordViewViewdefinition::getAvailablePlaceholders($this->table_id, true);
232// foreach ($allp as $id => $item) {
233// $parsed_item = new ilTextInputGUI("", "fields[" . $item->getId() . "]");
234// $parsed_item = $parsed_item->getToolbarHTML();
235//
236// $a_output = str_replace($id, $item->getTitle() . ": " . $parsed_item, $a_output);
237// }
238 } // editor
239 else {
240 if ($this->getOutputMode() == IL_PAGE_EDIT) {
242
243 // :TODO: find a suitable markup for matched placeholders
244 foreach ($allp as $item) {
245 $a_output = str_replace($item, "<span style=\"color:green\">" . $item . "</span>", $a_output);
246 }
247 }
248 }
249
250 return $a_output;
251 }
const IL_PAGE_EDIT
const IL_PAGE_PREVIEW
static getAvailablePlaceholders($a_table_id, $a_verbose=false)
Get all placeholders for table id.

References ilDataCollectionRecordViewViewdefinition\getAvailablePlaceholders(), ilPageObjectGUI\getOutputMode(), IL_PAGE_EDIT, and IL_PAGE_PREVIEW.

+ Here is the call graph for this function:

◆ releasePageLock()

ilDataCollectionRecordViewViewdefinitionGUI::releasePageLock ( )

Release page lock overwrite to redirect properly.

Reimplemented from ilPageObjectGUI.

Definition at line 205 of file class.ilDataCollectionRecordViewViewdefinitionGUI.php.

206 {
207 global $ilCtrl, $lng;
208
209 $this->getPageObject()->releasePageLock();
210 ilUtil::sendSuccess($lng->txt("cont_page_lock_released"), true);
211 $ilCtrl->redirectByClass('ilDataCollectionFieldListGUI', "listFields");
212 }

References $ilCtrl, ilPageObjectGUI\$lng, ilPageObjectGUI\getPageObject(), and ilUtil\sendSuccess().

+ Here is the call graph for this function:

Field Documentation

◆ $ctrl

ilDataCollectionRecordViewViewdefinitionGUI::$ctrl

◆ $obj_id

ilDataCollectionRecordViewViewdefinitionGUI::$obj_id
protected

◆ $table_id

ilDataCollectionRecordViewViewdefinitionGUI::$table_id
protected

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