Code

Fixed problems in kolab/server tabs
[gosa.git] / plugins / admin / systems / class_servDNS.inc
1 <?php
3 class servdns extends plugin
4 {
5   /* CLI vars */
6   var $cli_summary= "Manage server basic objects";
7   var $cli_description= "Some longer text\nfor help";
8   var $cli_parameters= array("eins" => "Eins ist toll", "zwei" => "Zwei ist noch besser");
10   /* attribute list for save action */
11   var $ignore_account= TRUE;
12   var $attributes= array();
13   var $objectclasses= array("whatever");
15   function servdns ($config, $dn= NULL)
16   {
17     plugin::plugin ($config, $dn);
18   }
20   function execute()
21   {
22     /* Fill templating stuff */
23     $smarty= get_smarty();
24     $display= "";
26     /* Do we need to flip is_account state? */
27     if (isset($_POST['modify_state'])){
28       $this->is_account= !$this->is_account;
29     }
31     /* Show tab dialog headers */
32     if ($this->is_account){
33       $display= $this->show_header(_("Remove DNS service"),
34           _("This server has DNS features enabled. You can disable them by clicking below."));
35     } else {
36       $display= $this->show_header(_("Add DNS service"),
37           _("This server has DNS features disabled. You can enable them by clicking below."));
38       return ($display);
39     }
41     $display.= $smarty->fetch(get_template_path('servdns.tpl', TRUE));
42     return($display);
43   }
45   function remove_from_parent()
46   {
47     /* This cannot be removed... */
48   }
51   /* Save data to object */
52   function save_object()
53   {
54     plugin::save_object();
55   }
58   /* Check supplied data */
59   function check()
60   {
61     $message= array();
63     return ($message);
64   }
67   /* Save to LDAP */
68   function save()
69   {
70     plugin::save();
72     /* Optionally execute a command after we're done */
73     #$this->handle_post_events($mode);
74   }
76 }
78 // vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
79 ?>