/**
* ExtensionDetailsForm constructor.
- *
+ *
* @global <type> $shout_extensions
* @param <type> $vars
- * @return <type>
+ * @return <type>
*/
function __construct(&$vars)
{
global $shout_extensions;
+
$context = $_SESSION['shout']['context'];
$action = $vars->get('action');
if ($action == 'edit') {
$formtitle = "Add User";
}
+ parent::__construct($vars, _("$formtitle - Context: $context"));
+
$extension = $vars->get('extension');
- parent::__construct($vars, _("$formtitle - Context: $context"));
-
$this->addHidden('', 'action', 'text', true);
$this->addHidden('', 'oldextension', 'text', false);
$this->addVariable(_("Full Name"), 'name', 'text', true);
$extension = $this->_vars->get('extension');
$shout_extensions->deleteExtension($context, $extension);
}
-}
\ No newline at end of file
+}
<td class="uheader">E-Mail Address</td>
</tr>
<?php
+ $expandAttrs = array('onclick' => 'javascript:alert(this.getNode().parent);',
+ 'id' => 'myid');
+ $expandButton = Horde::img('tree/plusonly.png', _("Expand"), $expandAttrs,
+ $registry->getImageDir('horde'));
foreach ($extensions as $extension => $info) {
$url = Horde::applicationUrl("extensions.php");
<td style="width: 20%">
<?php echo Horde::link($editurl); echo $extension; ?></a>
</td>
- <td style="width: 35%;" id="myid">
+ <td style="width: 35%;">
+ <?php echo $expandButton; ?>
<?php echo Horde::link($editurl); echo $info['name']; ?></a>
+ <span id="destX<?php echo $extension; ?>summary">
<?php
foreach ($info['devices'] as $device) {
echo Horde::img('shout.png');
echo Horde::img('telephone-pole.png');
}
?>
+ </span>
+
+ <form>
+ <div class="extensionDestinations" id="destX<?php echo $extension; ?>">
+ <input type="hidden" name="extension" value="<?php echo $extension; ?>">
+ <?php
+ foreach ($info['devices'] as $device) {
+ echo Horde::img('shout.png') . " " . $device . "<br>\n";
+ }
+ foreach ($info['numbers'] as $number) {
+ echo Horde::img('telephone-pole.png') . " " . $number . "<br>\n";
+ }
+ ?>
+ </div>
+ </form>
</td>
<td style="width: 45%">
<?php echo $info['email']; ?>