diff --git a/gosa-plugins/goto/admin/systems/services/shares/class_goShareServer.inc b/gosa-plugins/goto/admin/systems/services/shares/class_goShareServer.inc
index b29744a66d16f0ae30006bb364c44711ef0ef023..23f527b527b4b1608fe5e8344eaad83be7f2d36d 100644 (file)
{
goService::goService($config,$dn);
- $this->DisplayName = _("File service");
+ $this->DisplayName = _("File service (Shares)");
$tmp =array();
if(isset($this->attrs['goExportEntry'])){
if(isset($_POST['NFSsave']) && isset($this->o_subWindow) && is_object($this->o_subWindow)){
if(count($this->o_subWindow->check())>0){
foreach($this->o_subWindow->check() as $msg) {
- print_red($msg);
+ msg_dialog::display(_("Error"), $msg, ERROR_DIALOG);
}
}else{
$this->o_subWindow->save_object();
{
$fields = goService::getListEntry();
$fields['Message'] = _("File service (Shares)");
- $fields['AllowEdit'] = true;
+ #$fields['AllowEdit'] = true;
return($fields);
}
$ldap = $this->config->get_ldap_link();
$ldap->cd($this->config->current['BASE']);
$ldap->search("(|(gotoProfileServer=*|$id)(gotoShare=*|$id|*||*))", array("cn"));
- $cnt= $ldap->count();
- if ($cnt){
- $msg= sprintf(_("The share can't be removed since it is still used by %d users:"), $cnt);
- $msg.= "<br><br><ul>";
+ if ($ldap->count != 0){
while ($attrs= $ldap->fetch()){
- $msg.= "<li>".$attrs["cn"][0]."</li>";
+ $obj[$ldap->getDN()]= $attrs['cn'][0];
}
- $msg.= "</ul>"._("Please correct the share-/profile settings of these users");
- print_red($msg);
+ msg_dialog::display(_("Error"), msgPool::stillInUse(_("share"), msgPool::buildList($obj)), ERROR_DIALOG);
} else {
/* Finally remove it */