diff --git a/gosa-plugins/goto/admin/systems/goto/class_workstationStartup.inc b/gosa-plugins/goto/admin/systems/goto/class_workstationStartup.inc
index 4b3164c40fb27f7d8860505b0f7930d793f33135..fc29543b07e6e34eb6ff4f57dfb75e50cec0f1b2 100644 (file)
$this->gotoLdapServers[] = preg_replace("/^[0-9]*:/","",$value);
}
}
$this->gotoLdapServers[] = preg_replace("/^[0-9]*:/","",$value);
}
}
+ natcasesort($this->gotoLdapServerList);
+
if(!count($this->gotoLdapServers) && $this->member_of_ogroup){
$this->gotoLdap_inherit = TRUE;
}
if(!count($this->gotoLdapServers) && $this->member_of_ogroup){
$this->gotoLdap_inherit = TRUE;
}
}
if((isset($this->FAIclassInfo[$_POST['FAIclassesSel']]['FAIpartitionTable']))&&($found>0)){
}
if((isset($this->FAIclassInfo[$_POST['FAIclassesSel']]['FAIpartitionTable']))&&($found>0)){
- msg_dialog(_("Error"), _("There is already a profile containing a partition table in your configuration!") , ERROR_DIALOG);
+ msg_dialog::display(_("Error"), _("There is already a profile containing a partition table in your configuration!") , ERROR_DIALOG);
}else{
$this->FAIclass[$_POST['FAIclassesSel']]=$_POST['FAIclassesSel'];
}
}else{
$this->FAIclass[$_POST['FAIclassesSel']]=$_POST['FAIclassesSel'];
}
if((isset($_POST['gotoShareAdd'])) && ($this->acl_is_writeable("gotoShare"))) {
/* We assign a share to this user, if we don't know where to mount the share */
if((!isset($_POST['gotoShareMountPoint']))||(empty($_POST['gotoShareMountPoint']))||(preg_match("/[\|]/i",$_POST['gotoShareMountPoint']))){
if((isset($_POST['gotoShareAdd'])) && ($this->acl_is_writeable("gotoShare"))) {
/* We assign a share to this user, if we don't know where to mount the share */
if((!isset($_POST['gotoShareMountPoint']))||(empty($_POST['gotoShareMountPoint']))||(preg_match("/[\|]/i",$_POST['gotoShareMountPoint']))){
- msg_dialog(_("Error"), msgPool::required(_("Mount point")), ERROR_DIALOG);
+ msg_dialog::display(_("Error"), msgPool::required(_("Mount point")), ERROR_DIALOG);
}else{
if(count($this->gotoAvailableShares)){
$a_share = $this->gotoAvailableShares[$_POST['gotoShareSelection']];
}else{
if(count($this->gotoAvailableShares)){
$a_share = $this->gotoAvailableShares[$_POST['gotoShareSelection']];
}
/* Convert old style entry */
}
/* Convert old style entry */
- if (!preg_match('%:ldap://%', $server)){
+ if (!preg_match('%:ldaps?://%', $server)){
$server= "ldap://".preg_replace('/^([^:]+):/', '\1/', $server);
/* Beautify new style entries */
$server= "ldap://".preg_replace('/^([^:]+):/', '\1/', $server);
/* Beautify new style entries */
if(!in_array($entry,$this->gotoLdapServers)){
/* Convert old style entry */
if(!in_array($entry,$this->gotoLdapServers)){
/* Convert old style entry */
- if (!preg_match('%:ldap://%', $entry)){
+ if (!preg_match('%:ldap[s]*://%', $entry)){
$entry= "ldap://".preg_replace('/^([^:]+):/', '\1/', $entry);
/* Beautify new style entries */
$entry= "ldap://".preg_replace('/^([^:]+):/', '\1/', $entry);
/* Beautify new style entries */
$this->attrs['FAIclass'] = array();
$this->attrs['FAIdebianMirror'] = array();
}
$this->attrs['FAIclass'] = array();
$this->attrs['FAIdebianMirror'] = array();
}
- }
+ }else{
+ /* Don't touch FAI objects if something went wrong with the si daemon.
+ */
+ if(isset($this->attrs['FAIclass'])) unset($this->attrs['FAIclass']);
+ if(isset($this->attrs['FAIdebianMirror'])) unset($this->attrs['FAIdebianMirror']);
+ }
/* prepare share settings */
$tmp = array();
/* prepare share settings */
$tmp = array();
$res = shell_exec($cmd);
$res2 = trim($res);
if((!$res)){
$res = shell_exec($cmd);
$res2 = trim($res);
if((!$res)){
- msg_dialog(_("Configuration error"), msgPool::cmdexecfailed("REPOSITORY_HOOK", $cmd), ERROR_DIALOG);
+ msg_dialog::display(_("Configuration error"), msgPool::cmdexecfailed("REPOSITORY_HOOK", $cmd), ERROR_DIALOG);
}elseif(empty($res2)){
}elseif(empty($res2)){
- msg_dialog(_("Configuration error"), _("REPOSITORY_HOOK returned no result!"), ERROR_DIALOG);
+ msg_dialog::display(_("Configuration error"), _("REPOSITORY_HOOK returned no result!"), ERROR_DIALOG);
}else{
$tmp = split("\n",$res);
foreach($tmp as $line){
}else{
$tmp = split("\n",$res);
foreach($tmp as $line){