diff --git a/plugins/admin/systems/class_printGeneric.inc b/plugins/admin/systems/class_printGeneric.inc
index 24fe12cf057acbee5ddc243475a043dc437aba20..95d2a983c63cc854a0604697e84f23c1ea29612e 100644 (file)
/* Needed values and lists */
var $base = "";
var $cn = "";
- var $macAddress = "";
- var $ipHostNumber = "";
var $l = "";
var $description = "";
var $labeledURI = "";
var $type = "";
var $dialog =NULL;
+ var $netConfigDNS;
+
/* attribute list for save action */
- var $attributes = array("cn", "description", "l", "labeledURI", "macAddress", "ipHostNumber","gotoPrinterPPD");
+ var $attributes = array("cn", "description", "l", "labeledURI", "gotoPrinterPPD");
var $objectclasses = array("top", "gotoPrinter");
function printgeneric ($config, $dn= NULL)
{
plugin::plugin ($config, $dn);
$ldap= $this->config->get_ldap_link();
+
+ $this->netConfigDNS = new termDNS($this->config, $this->dn,$this->objectclasses);
+
/* Set base */
if ($this->dn == "new"){
return $display;
}
- /* Don't show Asterisk for non-required attribute ipHostNumber and macAddress */
- $smarty->assign("staticAddress", "");
-
-
require_once ("class_ppdManager.inc");
if((isset($_SESSION['config']->data['MAIN']['PPD_PATH']))&&(is_dir($_SESSION['config']->data['MAIN']['PPD_PATH']))){
$smarty->assign("AdminMember" ,$this->AdminMember);
$smarty->assign("AdminMembers" ,$adminlist);
$smarty->assign("AdminMemberKeys",array_flip($adminlist));
- $smarty->assign("netconfig", dirname(__FILE__)."/network.tpl");
+ $smarty->assign("netconfig", $this->netConfigDNS->execute());
return($display.$smarty->fetch (get_template_path('printer.tpl', TRUE)));
}
unset($og->member[$this->dn]);
$og->save ();
}
+
+ $this->netConfigDNS->remove_from_parent();
}
}
}
- /* Save data to object */
- function save_object()
+ /* Save data to object */
+ function save_object()
{
plugin::save_object();
-
+ $this->netConfigDNS->save_object();
/* Save base, since this is no LDAP attribute */
if (isset($_POST['base']) && chkacl($this->acl, "create") == ""){
$this->base= $_POST['base'];
/* Check supplied data */
function check()
{
- $message= array();
+ $message= $this->netConfigDNS->check();
if(isset($this->parent->by_name['workgeneric'])){
if($this->parent->by_object['workgeneric']->cn == "wdefault"){
}
show_ldap_error($ldap->get_error());
+ $this->netConfigDNS->save($this->dn);
+
/* Optionally execute a command after we're done */
$this->postcreate();
}