ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
class.ilObjRemoteWikiGUI.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('rwik');
25 $this->lng->loadLanguageModule('wiki');
26 }
27
28 public function getType()
29 {
30 return 'rwik';
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()) {
42 return $this->lng->txt('offline');
43
45 return $this->lng->txt('online');
46 }
47 return '';
48 }
49
50 protected function addCustomEditForm(ilPropertyFormGUI $a_form)
51 {
52 $radio_grp = new ilRadioGroupInputGUI($this->lng->txt('ecs_availability'), 'activation_type');
53 $radio_grp->setValue($this->object->getAvailabilityType());
54 $radio_grp->setDisabled(true);
55
56 $radio_opt = new ilRadioOption($this->lng->txt('offline'), ilObjRemoteWiki::ACTIVATION_OFFLINE);
57 $radio_grp->addOption($radio_opt);
58
59 $radio_opt = new ilRadioOption($this->lng->txt('online'), ilObjRemoteWiki::ACTIVATION_ONLINE);
60 $radio_grp->addOption($radio_opt);
61
62 $a_form->addItem($radio_grp);
63 }
64}
An exception for terminatinating execution or to throw for unit testing.
Class ilInfoScreenGUI.
addProperty($a_name, $a_value, $a_link="")
add a property to current section
__construct($a_id=0, $a_id_type=self::REPOSITORY_NODE_ID, $a_parent_node_id=0)
Constructor.
getType()
Functions that must be overwritten.
addCustomInfoFields(ilInfoScreenGUI $a_info)
Add custom fields to info screen.
addCustomEditForm(ilPropertyFormGUI $a_form)
Add custom fields to edit form.
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.