diff --git a/gosa-plugins/goto/admin/devices/class_deviceManagement.inc b/gosa-plugins/goto/admin/devices/class_deviceManagement.inc
index e8343180ec51263b49745c9fd0dd1c60b18e5615..6972caefa8d1069ca5fc529179b6cf5a64d35cb3 100644 (file)
{
/* Definitions */
- var $plHeadline = "Devices";
- var $plDescription = "Manage devices";
+ var $plHeadline = "Hotplug devices";
+ var $plDescription = "Manage hotplug devices";
/* Dialog attributes */
var $ui = NULL;
} else {
/* Ok. There seem to be errors regarding to the tab data,
show message and continue as usual. */
- show_errors($message);
+ msg_dialog::displayChecks($message);
}
}
$this->dns[$id] = $dn;
}
- $dns_names = "<br><pre>";
+ $dns_names = array();
foreach($this->dns as $dn){
add_lock ($dn, $this->ui->dn);
- $dns_names .= $dn."\n";
+ $dns_names[] =@LDAP::fix($dn);
}
- $dns_names .="</pre>";
/* Lock the current entry, so nobody will edit it during deletion */
- if (count($this->dns) == 1){
- $smarty->assign("intro", sprintf(_("You're about to delete the following entry %s"), @LDAP::fix($dns_names)));
- } else {
- $smarty->assign("intro", sprintf(_("You're about to delete the following entries %s"), @LDAP::fix($dns_names)));
- }
+ $smarty->assign("intro", msgPool::deleteInfo($dns_names),_("device"));
$smarty->assign("multiple", true);
return($smarty->fetch(get_template_path('remove.tpl', TRUE)));
}
} else {
/* Normally this shouldn't be reached, send some extra
logs to notify the administrator */
- print_red (_("You are not allowed to delete this device type!"));
+ msg_dialog::display(_("Permission error"), msgPool::permDelete(), INFO_DIALOG);
new log("security","devices/".get_class($this),$dn,array(),"Tried to trick deletion.");
}
/* Remove lock file after successfull deletion */
/* Lock the current entry, so nobody will edit it during deletion */
add_lock ($this->dn, $this->ui->dn);
$smarty= get_smarty();
- $smarty->assign("intro", sprintf(_("You're about to delete the device '%s'."), @LDAP::fix($this->dn)));
+ $smarty->assign("intro", msgPool::deleteInfo(@LDAP::fix($this->dn),_("device")));
$smarty->assign("multiple", false);
return($smarty->fetch (get_template_path('remove.tpl', TRUE)));
} else {
/* Obviously the user isn't allowed to delete. Show message and
clean session. */
- print_red (_("You are not allowed to delete this device!"));
+ msg_dialog::display(_("Permission error"), msgPool::permDelete(), INFO_DIALOG);
}
}
/* Normally this shouldn't be reached, send some extra
logs to notify the administrator */
- print_red (_("You are not allowed to delete this device!"));
+ msg_dialog::display(_("Permission error"), msgPool::permDelete(), INFO_DIALOG);
new log("security","devices/".get_class($this),$dn,array(),"Tried to trick deletion.");
}
/* Don't show buttons if tab dialog requests this */
if (!$this->devicetabs->by_object[$this->devicetabs->current]->dialog){
$display.= "<p style=\"text-align:right\">\n";
- $display.= "<input type=\"submit\" name=\"edit_finish\" style=\"width:80px\" value=\""._("Ok")."\">\n";
+ $display.= "<input type=\"submit\" name=\"edit_finish\" style=\"width:80px\" value=\"".msgPool::okButton()."\">\n";
$display.= " \n";
if ($this->dn != "new"){
- $display.= "<input type=submit name=\"edit_apply\" value=\""._("Apply")."\">\n";
+ $display.= "<input type=submit name=\"edit_apply\" value=\"".msgPool::applyButton()."\">\n";
$display.= " \n";
}
- $display.= "<input type=\"submit\" name=\"edit_cancel\" value=\""._("Cancel")."\">\n";
+ $display.= "<input type=\"submit\" name=\"edit_cancel\" value=\"".msgPool::cancelButton()."\">\n";
$display.= "</p>";
}
return ($display);
function save_object() {
$this->DivListDevices->save_object();
+ if(is_object($this->CopyPasteHandler)){
+ $this->CopyPasteHandler->save_object();
+ }
}