5 require_once(
"./Services/Container/classes/class.ilContainerGUI.php");
6 require_once(
"./Services/AccessControl/classes/class.ilObjRole.php");
7 require_once(
"./Services/Form/classes/class.ilPropertyFormGUI.php");
8 require_once(
"./Services/AccessControl/classes/class.ilPermissionGUI.php");
9 require_once(
"./Services/InfoScreen/classes/class.ilInfoScreenGUI.php");
10 require_once(
"./Services/Object/classes/class.ilObjectAddNewItemGUI.php");
11 require_once(
"./Modules/StudyProgramme/classes/class.ilObjStudyProgrammeTreeGUI.php");
12 require_once(
'./Services/Container/classes/class.ilContainerSortingSettings.php');
13 require_once(
"./Modules/StudyProgramme/classes/types/class.ilStudyProgrammeTypeGUI.php");
14 require_once(
"./Modules/StudyProgramme/classes/model/class.ilStudyProgrammeAdvancedMetadataRecord.php");
15 require_once(
"./Services/AdvancedMetaData/classes/class.ilAdvancedMDRecordGUI.php");
16 require_once(
"./Services/Object/classes/class.ilObjectCopyGUI.php");
17 require_once(
"./Services/Repository/classes/class.ilRepUtil.php");
96 $ilToolbar = $DIC[
'ilToolbar'];
102 $ilHelp = $DIC[
'ilHelp'];
104 parent::__construct(
array(), (
int)
$_GET[
'ref_id'],
true,
false);
111 $this->toolbar = $ilToolbar;
115 $this->help = $ilHelp;
117 $lng->loadLanguageModule(
"prg");
122 $cmd = $this->ctrl->getCmd();
123 $next_class = $this->ctrl->getNextClass($this);
131 parent::prepareOutput();
136 switch ($next_class) {
137 case "ilinfoscreengui":
138 $this->tabs_gui->setTabActive(self::TAB_INFO);
142 $this->ctrl->forwardCommand(
$info);
153 case 'ilpermissiongui':
154 $this->tabs_gui->setTabActive(
'perm_settings');
156 $this->ctrl->forwardCommand($ilPermissionGUI);
158 case "ilcommonactiondispatchergui":
159 require_once(
"Services/Object/classes/class.ilCommonActionDispatcherGUI.php");
161 $this->ctrl->forwardCommand($gui);
163 case "ilobjstudyprogrammesettingsgui":
167 $this->tabs_gui->setTabActive(self::TAB_SETTINGS);
168 $this->tabs_gui->setSubTabActive(
'settings');
170 require_once(
"Modules/StudyProgramme/classes/class.ilObjStudyProgrammeSettingsGUI.php");
172 $this->ctrl->forwardCommand($gui);
184 case "ilobjstudyprogrammemembersgui":
186 $this->tabs_gui->setTabActive(self::TAB_MEMBERS);
187 require_once(
"Modules/StudyProgramme/classes/class.ilObjStudyProgrammeMembersGUI.php");
189 $this->ctrl->forwardCommand($gui);
191 case "ilobjstudyprogrammetreegui":
196 $this->tabs_gui->setTabActive(self::TAB_VIEW_CONTENT);
197 $this->tabs_gui->setSubTabActive(self::SUBTAB_VIEW_TREE);
200 $_SESSION[
"il_cont_admin_panel"] =
false;
203 $this->ctrl->forwardCommand($gui);
205 case 'ilstudyprogrammetypegui':
206 $this->tabs_gui->setTabActive(
'subtypes');
209 $this->ctrl->forwardCommand($types_gui);
211 case 'ilobjectcopygui':
212 $gui =
new ilobjectcopygui($this);
213 $this->ctrl->forwardCommand($gui);
228 $this->tabs_gui->clearTargets();
229 $this->tabs_gui->setBackTarget($this->lng->txt(
"back"), $this->ctrl->getLinkTarget($this));
230 parent::deleteObject();
232 case 'confirmedDelete':
233 parent::confirmedDeleteObject();
235 case 'editAdvancedSettings':
236 $this->tabs_gui->setTabActive(
"settings");
237 $this->tabs_gui->setSubTabActive(
'edit_advanced_settings');
241 case 'updateAdvancedSettings':
242 $this->tabs_gui->setTabActive(
"settings");
243 $this->tabs_gui->setSubTabActive(
'edit_advanced_settings');
248 $this->ctrl->redirectByClass(
"ilInfoScreenGUI",
"showSummary");
250 case 'getAsynchItemList':
251 parent::getAsynchItemListObject();
255 case 'confirmRemoveFromSystem':
256 case 'removeFromSystem':
322 throw new ilException(
"ilObjStudyProgrammeGUI: Command not supported: $cmd");
326 throw new ilException(
"ilObjStudyProgrammeGUI: Can't forward to next class $next_class");
335 parent::createObject();
345 parent::saveObject();
347 if($this->ctrl->isAsynch()) {
349 $form->setValuesByPost();
366 parent::cancelCreation();
392 $this->ctrl->setParameter($this,
"ref_id", $a_new_object->
getRefId());
394 $this->ctrl->getLinkTarget($this,
"edit",
"",
false,
false)));
403 $this->tabs_gui->setTabActive(self::TAB_VIEW_CONTENT);
405 parent::renderObject();
415 $form->setFormAction($this->ctrl->getFormAction($this));
416 $form->addCommandButton(
'updateAdvancedSettings', $this->lng->txt(
'save'));
417 $form->addCommandButton(
'editAdvancedSettings', $this->lng->txt(
'cancel'));
426 if (!$this->ilAccess->checkAccess(
"write",
"", $this->ref_id)) {
428 $this->ctrl->redirect($this);
434 $this->tpl->setContent($form->getHTML());
442 if (!$this->ilAccess->checkAccess(
"write",
"", $this->ref_id)) {
444 $this->ctrl->redirect($this);
452 if ($gui->importEditFormPostValues()) {
453 $gui->writeEditForm();
455 $this->ctrl->redirect($this,
'editAdvancedSettings');
457 $this->tpl->setContent($form->getHTML());
484 $asyncForm->cloneForm($tmp_forms[self::CFORM_NEW]);
485 $asyncForm->setAsync(
true);
495 return $this->ilAccess->checkAccess($a_which,
"", $this->ref_id);
503 foreach ($a_perms as $perm) {
511 $this->ctrl->redirectByClass(
'ilinfoscreengui',
'');
514 $this->
ilias->raiseError($this->lng->txt(
"msg_no_perm_read"), $this->
ilias->error_obj->WARNING);
528 $this->help->setScreenIdComponent(
"prg");
530 $this->tabs_gui->addTab( self::TAB_VIEW_CONTENT
531 , $this->lng->txt(
"content")
536 $this->tabs_gui->addTab( self::TAB_INFO
537 , $this->lng->txt(
"info_short")
543 $this->tabs_gui->addTab( self::TAB_SETTINGS
544 , $this->lng->txt(
"settings")
550 $this->tabs_gui->addTab( self::TAB_MEMBERS
551 , $this->lng->txt(
"members")
564 switch($a_parent_tab) {
565 case self::TAB_VIEW_CONTENT:
566 case self::SUBTAB_VIEW_TREE:
569 $this->tabs_gui->addSubTab(self::TAB_VIEW_CONTENT, $this->lng->txt(
"view"), $this->
getLinkTarget(
"view"));
573 $this->tabs_gui->addSubTab(self::SUBTAB_VIEW_TREE, $this->lng->txt(
"cntr_manage"), $this->
getLinkTarget(self::SUBTAB_VIEW_TREE));
577 case 'editAdvancedSettings':
578 $this->tabs_gui->addSubTab(
'settings', $this->lng->txt(
'settings'), $this->
getLinkTarget(
'settings'));
581 $type = ilStudyProgrammeType::find($this->
object->getSubtypeId());
583 if (!is_null($type) && count($type->getAssignedAdvancedMDRecords(
true))) {
584 $this->tabs_gui->addSubTab(
'edit_advanced_settings', $this->lng->txt(
'prg_adv_settings'), $this->ctrl->getLinkTarget($this,
'editAdvancedSettings'));
608 if ($a_cmd ==
"info_short") {
609 return $this->ctrl->getLinkTargetByClass(
"ilinfoscreengui",
"showSummary");
611 if ($a_cmd ==
"settings") {
612 return $this->ctrl->getLinkTargetByClass(
"ilobjstudyprogrammesettingsgui",
"view");
614 if($a_cmd == self::SUBTAB_VIEW_TREE) {
615 return $this->ctrl->getLinkTargetByClass(
"ilobjstudyprogrammetreegui",
"view");
617 if ($a_cmd ==
"members") {
618 return $this->ctrl->getLinkTargetByClass(
"ilobjstudyprogrammemembersgui",
"view");
620 if($a_cmd ==
"subtypes") {
621 return $this->ctrl->getLinkTargetByClass(
"ilstudyprogrammetypegui",
"listTypes");
624 return $this->ctrl->getLinkTarget($this, $a_cmd);
634 require_once(
'./Services/AdvancedMetaData/classes/class.ilAdvancedMDValues.php');
635 require_once(
'./Services/AdvancedMetaData/classes/class.ilAdvancedMDRecord.php');
636 require_once(
'Services/AdvancedMetaData/classes/class.ilAdvancedMDRecordGUI.php');
637 require_once(
'./Services/ADT/classes/class.ilADTFactory.php');
639 $type = ilStudyProgrammeType::find($this->
object->getSubtypeId());
646 $record_gui->parse();
653 $this->tabs_gui->setTabActive(self::TAB_SETTINGS);
654 $this->tabs_gui->setSubTabActive(
'settings');
656 require_once(
"Modules/StudyProgramme/classes/class.ilObjStudyProgrammeSettingsGUI.php");
658 $this->ctrl->setCmd(
"view");
659 $this->ctrl->forwardCommand($gui);
668 public static function _goto($a_target) {
673 $id = explode(
"_", $a_target);
674 $ilCtrl->setTargetScript(
"ilias.php");
675 $ilCtrl->initBaseClass(
"ilRepositoryGUI");
676 $ilCtrl->setParameterByClass(
"ilobjstudyprogrammegui",
"ref_id", $id[0]);
678 $ilCtrl->redirectByClass(
array(
"ilRepositoryGUI",
"ilobjstudyprogrammegui" ),
"view");
683 $ilNavigationHistory = $DIC[
'ilNavigationHistory'];
686 $this->ilAccess->checkAccess(
'read',
'',
$_GET[
'ref_id']))
688 $link = $this->ctrl->getLinkTargetByClass(
"ilrepositorygui",
"frameset");
690 $ilNavigationHistory->addItem(
$_GET[
'ref_id'],
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
view()
Default view method.
Base class for ILIAS Exception handling.
Class ilObjStudyProgrammeGUI class.
setSortMode($a_mode)
set sort mode
setPropertyForm($form)
set property form object
cancel()
Cancel the object generation.
Class ilObject Basic functions for all objects.
denyAccessIfNotAnyOf($a_perms)
Class ilStudyProgrammeTypeGUI.
static _goto($a_target)
_goto Deep link
getSubTabs($a_parent_tab)
Adds subtabs based on the parent tab.
const SORT_NEW_ITEMS_POSITION_BOTTOM
static encodeAsyncResponse(array $data=array())
Encode data as json for async output.
setInfoObject($info)
get info sections
getId()
get object id public
getLinkTarget($a_cmd)
Generates a link based on a cmd.
getAsyncCreationForm()
Method for implementing async windows-output Should be moved into core to enable async requests on cr...
const SORT_NEW_ITEMS_ORDER_CREATION
create()
creates the object
editAdvancedSettings()
Edit Advanced Metadata.
getTabs()
Adds the default tabs to the gui.
redirection script todo: (a better solution should control the processing via a xml file) ...
updateAdvancedSettings()
Update Advanced Metadata.
Class ilObjStudyProgrammeMembersGUI.
initCreateForm($a_new_type)
Init object creation form.
Create styles array
The data for the language used.
static sendFailure($a_info="", $a_keep=false)
Send Failure Message to Screen.
setContentSubTabs()
Disable default content subtabs.
Create new PHPExcel object
obj_idprivate
fillInfoScreen($a_info_screen)
Adding meta-data to the info-screen.
getCreationMode()
get creation mode
getRefId()
get reference id public
afterSave(ilObject $a_new_object)
After save hook Sets the sorting of the container correctly.
initCreationForms($a_new_type)
Overwritten from ilObjectGUI since copy and import are not implemented.
New PermissionGUI (extends from old ilPermission2GUI) RBAC related output.
initAdvancedSettingsForm()
Initialize the form for editing advanced meta data.
static redirect($a_script)
http redirect to other script
getReturnLocation($a_cmd, $a_location="")
get return location for command (command is method name without "Object", e.g.
static getInstanceFromAjaxCall()
(Re-)Build instance from ajax call
Class ilObjStudyProgrammeSettingsGUI.
Class ilObjStudyProgrammeTreeGUI Generates the manage view for ilTrainingProgramme-Repository objects...
static handleAsyncOutput($normal_content, $async_content=null, $apply_to_tpl=true)
Handles async output.