ILIAS  release_5-1 Revision 5.0.0-5477-g43f3e3fab5f
class.ilObjRemoteGlossaryGUI.php
Go to the documentation of this file.
1<?php
2/* Copyright (c) 1998-2010 ILIAS open source, Extended GPL, see docs/LICENSE */
3
4include_once('Services/WebServices/ECS/classes/class.ilRemoteObjectBaseGUI.php');
5
19{
20 public function __construct($a_id = 0, $a_id_type = self::REPOSITORY_NODE_ID, $a_parent_node_id = 0)
21 {
22 parent::__construct($a_id, $a_id_type, $a_parent_node_id);
23
24 $this->lng->loadLanguageModule('rglo');
25 // $this->lng->loadLanguageModule('glo');
26 }
27
28 function getType()
29 {
30 return 'rglo';
31 }
32
33 protected function addCustomInfoFields(ilInfoScreenGUI $a_info)
34 {
35 $a_info->addProperty($this->lng->txt('ecs_availability'),$this->availabilityToString());
36 }
37
38 protected function availabilityToString()
39 {
40 switch($this->object->getAvailabilityType())
41 {
43 return $this->lng->txt('offline');
44
46 return $this->lng->txt('online');
47 }
48 return '';
49 }
50
51 protected function addCustomEditForm(ilPropertyFormGUI $a_form)
52 {
53 $radio_grp = new ilRadioGroupInputGUI($this->lng->txt('ecs_availability'),'activation_type');
54 $radio_grp->setValue($this->object->getAvailabilityType());
55 $radio_grp->setDisabled(true);
56
57 $radio_opt = new ilRadioOption($this->lng->txt('offline'),ilObjRemoteGlossary::ACTIVATION_OFFLINE);
58 $radio_grp->addOption($radio_opt);
59
60 $radio_opt = new ilRadioOption($this->lng->txt('online'),ilObjRemoteGlossary::ACTIVATION_ONLINE);
61 $radio_grp->addOption($radio_opt);
62
63 $a_form->addItem($radio_grp);
64 }
65}
66
67?>
Class ilInfoScreenGUI.
addProperty($a_name, $a_value, $a_link="")
add a property to current section
addCustomInfoFields(ilInfoScreenGUI $a_info)
Add custom fields to info screen.
addCustomEditForm(ilPropertyFormGUI $a_form)
Add custom fields to edit form.
getType()
Functions that must be overwritten.
__construct($a_id=0, $a_id_type=self::REPOSITORY_NODE_ID, $a_parent_node_id=0)
Constructor.
This class represents a property form user interface.
addItem($a_item)
Add Item (Property, SectionHeader).
This class represents a property in a property form.
This class represents an option in a radio group.