4include_once 
'./Services/Table/classes/class.ilTable2GUI.php';
 
   20        public function  __construct($a_parent_obj, $a_parent_cmd = 
"")
 
   22                parent::__construct($a_parent_obj, $a_parent_cmd);
 
   23                $this->
setId(
'tbl_didactic_tpl_settings');
 
   34                $lng->loadLanguageModule(
'search');
 
   35                $this->
addColumn($this->lng->txt(
'search_title_description'),
'title',
'40%');
 
   36                $this->
addColumn($this->lng->txt(
'didactic_applicable_for'),
'applicable',
'20%');
 
   37                $this->
addColumn($this->lng->txt(
'active'),
'active',
'20%');
 
   38                $this->
addColumn($this->lng->txt(
'actions'),
'',
'20%');
 
   40                $this->
setTitle($this->lng->txt(
'didactic_available_templates'));
 
   42                if($ilAccess->checkAccess(
'write',
'',
$_REQUEST[
"ref_id"]))
 
   44                        $this->
addMultiCommand(
'activateTemplates', $this->lng->txt(
'activate'));
 
   45                        $this->
addMultiCommand(
'deactivateTemplates', $this->lng->txt(
'deactivate'));
 
   53                $this->
setRowTemplate(
'tpl.didactic_template_overview_row.html',
'Services/DidacticTemplate');
 
   56                $this->
setFormAction($ilCtrl->getFormAction($this->getParentObject()));
 
   64                include_once 
'./Services/DidacticTemplate/classes/class.ilDidacticTemplateSettings.php';
 
   66                $tpls->readInactive();
 
   69                foreach($tpls->getTemplates() as 
$tpl)
 
   73                        $data[$counter][
'title'] = 
$tpl->getTitle();
 
   74                        $data[$counter][
'description'] = 
$tpl->getDescription();
 
   75                        $data[$counter][
'info'] = 
$tpl->getInfo();
 
   76                        $data[$counter][
'enabled'] = (int) 
$tpl->isEnabled();
 
   77                        $data[$counter][
'assignments'] = 
$tpl->getAssignments();
 
   95                if($ilAccess->checkAccess(
'write',
'',
$_REQUEST[
"ref_id"]))
 
   97                        $this->tpl->setVariable(
'VAL_ID',$set[
'id']);
 
  100                $this->tpl->setVariable(
'VAL_TITLE', $set[
'title']);
 
  101                $this->tpl->setVariable(
'VAL_DESC', $set[
'description']);
 
  103                foreach((array) explode(
"\n", $set[
'info']) as 
$info)
 
  105                        $trimmed_info = trim(
$info);
 
  108                                $this->tpl->setCurrentBlock(
'info');
 
  109                                $this->tpl->setVariable(
'VAL_INFO',$trimmed_info);
 
  110                                $this->tpl->parseCurrentBlock();
 
  115                $this->tpl->setVariable(
'VAL_IMAGE',
 
  120                $this->tpl->setVariable(
'VAL_ENABLED_TXT',
 
  122                        $this->lng->txt(
'active') :
 
  123                        $this->lng->txt(
'inactive')
 
  128                foreach((array) $set[
'assignments'] as $obj_type)
 
  130                        $atxt .= ($this->lng->txt(
'objs_'.$obj_type).
'<br/>');
 
  132                $this->tpl->setVariable(
'VAL_APPLICABLE', $atxt);
 
  140                if($ilAccess->checkAccess(
'write',
'',
$_REQUEST[
"ref_id"]))
 
  143                        $this->tpl->setCurrentBlock(
'action_link');
 
  144                        $this->tpl->setVariable(
 
  148                        $this->tpl->setVariable(
'A_TEXT',$this->lng->txt(
'edit'));
 
  149                        $this->tpl->parseCurrentBlock();
 
  152                        $this->tpl->setCurrentBlock(
'action_link');
 
  153                        $this->tpl->setVariable(
 
  157                        $this->tpl->setVariable(
'A_TEXT', $this->lng->txt(
'copy'));
 
  158                        $this->tpl->parseCurrentBlock();
 
  161                $this->tpl->setCurrentBlock(
'action_link');
 
  162                $this->tpl->setVariable(
 
  166                $this->tpl->setVariable(
'A_TEXT', $this->lng->txt(
'didactic_do_export'));
 
  167                $this->tpl->parseCurrentBlock();
 
Description of ilDidacticTemplateSettingsTableGUI.
parse()
Parse didactic templates.
__construct($a_parent_obj, $a_parent_cmd="")
Constructor.
static getInstance()
Get singelton instance.
addColumn($a_text, $a_sort_field="", $a_width="", $a_is_checkbox_action_column=false, $a_class="", $a_tooltip="", $a_tooltip_with_html=false)
Add a column to the header.
getParentObject()
Get parent object.
setTitle($a_title, $a_icon=0, $a_icon_alt=0)
Set title and title icon.
setData($a_data)
set table data @access public
setRowTemplate($a_template, $a_template_dir="")
Set row template.
addMultiCommand($a_cmd, $a_text)
Add Command button.
setDefaultOrderField($a_defaultorderfield)
Set Default order field.
setSelectAllCheckbox($a_select_all_checkbox)
Set the name of the checkbox that should be toggled with a select all button.
setFormAction($a_form_action, $a_multipart=false)
Set Form action parameter.
setDefaultOrderDirection($a_defaultorderdirection)
Set Default order direction.
static getImagePath($img, $module_path="", $mode="output", $offline=false)
get image path (for images located in a template directory)
if($_REQUEST['ilias_path']) define('ILIAS_HTTP_PATH' $_REQUEST['ilias_path']