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");
98 $ilToolbar = $DIC[
'ilToolbar'];
100 $tree = $DIC[
'tree'];
104 $ilHelp = $DIC[
'ilHelp'];
106 parent::__construct(
array(), (
int)
$_GET[
'ref_id'],
true,
false);
113 $this->toolbar = $ilToolbar;
117 $this->help = $ilHelp;
119 $lng->loadLanguageModule(
"prg");
125 $cmd = $this->ctrl->getCmd();
126 $next_class = $this->ctrl->getNextClass($this);
134 parent::prepareOutput();
139 switch ($next_class) {
140 case "ilinfoscreengui":
141 $this->tabs_gui->setTabActive(self::TAB_INFO);
145 $this->ctrl->forwardCommand(
$info);
156 case 'ilpermissiongui':
157 $this->tabs_gui->setTabActive(
'perm_settings');
159 $this->ctrl->forwardCommand($ilPermissionGUI);
161 case "ilcommonactiondispatchergui":
162 require_once(
"Services/Object/classes/class.ilCommonActionDispatcherGUI.php");
164 $this->ctrl->forwardCommand($gui);
166 case "ilobjstudyprogrammesettingsgui":
170 $this->tabs_gui->setTabActive(self::TAB_SETTINGS);
171 $this->tabs_gui->setSubTabActive(
'settings');
173 require_once(
"Modules/StudyProgramme/classes/class.ilObjStudyProgrammeSettingsGUI.php");
175 $this->ctrl->forwardCommand($gui);
187 case "ilobjstudyprogrammemembersgui":
189 $this->tabs_gui->setTabActive(self::TAB_MEMBERS);
190 require_once(
"Modules/StudyProgramme/classes/class.ilObjStudyProgrammeMembersGUI.php");
192 $this->ctrl->forwardCommand($gui);
194 case "ilobjstudyprogrammetreegui":
199 $this->tabs_gui->setTabActive(self::TAB_VIEW_CONTENT);
200 $this->tabs_gui->setSubTabActive(self::SUBTAB_VIEW_TREE);
203 $_SESSION[
"il_cont_admin_panel"] =
false;
206 $this->ctrl->forwardCommand($gui);
208 case 'ilstudyprogrammetypegui':
209 $this->tabs_gui->setTabActive(
'subtypes');
212 $this->ctrl->forwardCommand($types_gui);
214 case 'ilobjectcopygui':
215 $gui =
new ilobjectcopygui($this);
216 $this->ctrl->forwardCommand($gui);
232 $this->tabs_gui->clearTargets();
233 $this->tabs_gui->setBackTarget($this->lng->txt(
"back"), $this->ctrl->getLinkTarget($this));
234 parent::deleteObject();
236 case 'confirmedDelete':
237 parent::confirmedDeleteObject();
239 case 'editAdvancedSettings':
240 $this->tabs_gui->setTabActive(
"settings");
241 $this->tabs_gui->setSubTabActive(
'edit_advanced_settings');
245 case 'updateAdvancedSettings':
246 $this->tabs_gui->setTabActive(
"settings");
247 $this->tabs_gui->setSubTabActive(
'edit_advanced_settings');
252 $this->ctrl->redirectByClass(
"ilInfoScreenGUI",
"showSummary");
254 case 'getAsynchItemList':
255 parent::getAsynchItemListObject();
259 case 'confirmRemoveFromSystem':
260 case 'removeFromSystem':
326 throw new ilException(
"ilObjStudyProgrammeGUI: Command not supported: $cmd");
330 throw new ilException(
"ilObjStudyProgrammeGUI: Can't forward to next class $next_class");
340 parent::createObject();
351 parent::saveObject();
353 if ($this->ctrl->isAsynch()) {
355 $form->setValuesByPost();
373 parent::cancelCreation();
399 $this->ctrl->setParameter($this,
"ref_id", $a_new_object->
getRefId());
402 $this->ctrl->getLinkTarget($this,
"edit",
"",
false,
false)
413 $this->tabs_gui->setTabActive(self::TAB_VIEW_CONTENT);
415 parent::renderObject();
426 $form->setFormAction($this->ctrl->getFormAction($this));
427 $form->addCommandButton(
'updateAdvancedSettings', $this->lng->txt(
'save'));
428 $form->addCommandButton(
'editAdvancedSettings', $this->lng->txt(
'cancel'));
440 $this->ctrl->redirect($this);
446 $this->tpl->setContent(
$form->getHTML());
457 $this->ctrl->redirect($this);
465 if ($gui->importEditFormPostValues()) {
466 $gui->writeEditForm();
468 $this->ctrl->redirect($this,
'editAdvancedSettings');
470 $this->tpl->setContent(
$form->getHTML());
499 $asyncForm->cloneForm($tmp_forms[self::CFORM_NEW]);
500 $asyncForm->setAsync(
true);
521 foreach ($a_perms as $perm) {
529 $this->ctrl->redirectByClass(
'ilinfoscreengui',
'');
532 $this->
ilias->raiseError($this->lng->txt(
"msg_no_perm_read"), $this->
ilias->error_obj->WARNING);
547 $this->help->setScreenIdComponent(
"prg");
549 $this->tabs_gui->addTab(self::TAB_VIEW_CONTENT, $this->lng->txt(
"content"), $this->
getLinkTarget(
"view"));
553 $this->tabs_gui->addTab(
555 $this->lng->txt(
"info_short"),
561 $this->tabs_gui->addTab(
563 $this->lng->txt(
"settings"),
569 $this->tabs_gui->addTab(
571 $this->lng->txt(
"members"),
585 switch ($a_parent_tab) {
586 case self::TAB_VIEW_CONTENT:
587 case self::SUBTAB_VIEW_TREE:
590 $this->tabs_gui->addSubTab(self::TAB_VIEW_CONTENT, $this->lng->txt(
"view"), $this->
getLinkTarget(
"view"));
594 $this->tabs_gui->addSubTab(self::SUBTAB_VIEW_TREE, $this->lng->txt(
"cntr_manage"), $this->
getLinkTarget(self::SUBTAB_VIEW_TREE));
598 case 'editAdvancedSettings':
599 $this->tabs_gui->addSubTab(
'settings', $this->lng->txt(
'settings'), $this->
getLinkTarget(
'settings'));
602 $type = ilStudyProgrammeType::find($this->
object->getSubtypeId());
604 if (!is_null(
$type) && count(
$type->getAssignedAdvancedMDRecords(
true))) {
605 $this->tabs_gui->addSubTab(
'edit_advanced_settings', $this->lng->txt(
'prg_adv_settings'), $this->ctrl->getLinkTarget($this,
'editAdvancedSettings'));
630 if ($a_cmd ==
"info_short") {
631 return $this->ctrl->getLinkTargetByClass(
"ilinfoscreengui",
"showSummary");
633 if ($a_cmd ==
"settings") {
634 return $this->ctrl->getLinkTargetByClass(
"ilobjstudyprogrammesettingsgui",
"view");
636 if ($a_cmd == self::SUBTAB_VIEW_TREE) {
637 return $this->ctrl->getLinkTargetByClass(
"ilobjstudyprogrammetreegui",
"view");
639 if ($a_cmd ==
"members") {
640 return $this->ctrl->getLinkTargetByClass(
"ilobjstudyprogrammemembersgui",
"view");
642 if ($a_cmd ==
"subtypes") {
643 return $this->ctrl->getLinkTargetByClass(
"ilstudyprogrammetypegui",
"listTypes");
646 return $this->ctrl->getLinkTarget($this, $a_cmd);
657 require_once(
'./Services/AdvancedMetaData/classes/class.ilAdvancedMDValues.php');
658 require_once(
'./Services/AdvancedMetaData/classes/class.ilAdvancedMDRecord.php');
659 require_once(
'Services/AdvancedMetaData/classes/class.ilAdvancedMDRecordGUI.php');
660 require_once(
'./Services/ADT/classes/class.ilADTFactory.php');
662 $type = ilStudyProgrammeType::find($this->
object->getSubtypeId());
669 $record_gui->parse();
677 $this->tabs_gui->setTabActive(self::TAB_SETTINGS);
678 $this->tabs_gui->setSubTabActive(
'settings');
680 require_once(
"Modules/StudyProgramme/classes/class.ilObjStudyProgrammeSettingsGUI.php");
682 $this->ctrl->setCmd(
"view");
683 $this->ctrl->forwardCommand($gui);
692 public static function _goto($a_target)
698 $id = explode(
"_", $a_target);
699 $ilCtrl->setTargetScript(
"ilias.php");
700 $ilCtrl->initBaseClass(
"ilRepositoryGUI");
701 $ilCtrl->setParameterByClass(
"ilobjstudyprogrammegui",
"ref_id",
$id[0]);
703 $ilCtrl->redirectByClass(
array(
"ilRepositoryGUI",
"ilobjstudyprogrammegui" ),
"view");
709 $ilNavigationHistory = $DIC[
'ilNavigationHistory'];
715 $ilNavigationHistory->addItem(
static sendSuccess($a_info="", $a_keep=false)
Send Success Message to Screen.
view()
Default view method.
Class ilObjStudyProgrammeGUI class.
setPropertyForm($form)
set property form object
cancel()
Cancel the object generation.
denyAccessIfNotAnyOf($a_perms)
if(!array_key_exists('StateId', $_REQUEST)) $id
static _getStudyProgrammeUserProgressDB()
Get an instance of ilStudyProgrammeUserProgressDB.
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.
checkAccess($a_permission, $a_cmd, $a_ref_id, $a_type="", $a_obj_id="", $a_tree_id="")
check access for an object (provide $a_type and $a_obj_id if available for better performance)(option...
setInfoObject($info)
get info sections
if(isset($_POST['submit'])) $form
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)
getReturnLocation($a_cmd, $a_location="")
get return location for command (command is method name without "Object", e.g.
static _getLink($a_ref_id, $a_type='', $a_params=array(), $append="")
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.