diff --git a/gosa-core/plugins/admin/users/class_userManagement.inc b/gosa-core/plugins/admin/users/class_userManagement.inc
index 67b0f6c9cabc3330f7de3c84ca7092425be77ffe..be15e04cdb2e1ea03ce37c7bcd84d950a7f875ee 100644 (file)
function editEntry($action="",$target=array(),$all=array(), $altTabClass ="", $altTabType = "", $altAclCategory="")
{
function editEntry($action="",$target=array(),$all=array(), $altTabClass ="", $altTabType = "", $altAclCategory="")
{
- management::editEntry($action,$target);
+ $str = management::editEntry($action,$target);
+ if($str) return($str);
if(preg_match("/^edit_/",$action)){
$tab = preg_replace("/^edit_/","",$action);
if(preg_match("/^edit_/",$action)){
$tab = preg_replace("/^edit_/","",$action);
*/
function saveChanges()
{
*/
function saveChanges()
{
- management::saveChanges();
+ $str = management::saveChanges();
+
+ if(!empty($str)) return($str);
+
+ if($this->last_tabObject instanceOf multi_plug){
+ foreach($this->last_tabObject->a_handles as $user){
+ if($user->password_change_needed()){
+ $this->force_hash_type[$user->dn] = $user->by_object['user']->pw_storage;
+ $this->pwd_change_queue[] = $user->dn;
+ }
+ }
+ return($this->handlePasswordQueue());
+ }
if(isset($this->last_tabObject->by_object['user']) && $this->last_tabObject->by_object['user']->password_change_needed()){
$this->force_hash_type[$this->last_tabObject->dn] = $this->last_tabObject->by_object['user']->pw_storage;
if(isset($this->last_tabObject->by_object['user']) && $this->last_tabObject->by_object['user']->password_change_needed()){
$this->force_hash_type[$this->last_tabObject->dn] = $this->last_tabObject->by_object['user']->pw_storage;
function cancelEdit()
{
function cancelEdit()
{
- management::cancelEdit();
+ $str = management::cancelEdit();
+ if(!empty($str)) return($str);
if(isset($this->last_tabObject->by_object['user']) &&
$this->last_tabObject->by_object['user']->dn != "new" &&
if(isset($this->last_tabObject->by_object['user']) &&
$this->last_tabObject->by_object['user']->dn != "new" &&
function newUserFromTemplate($action="",$target=array(),$all=array())
{
// Call parent method, it knows whats to do, locking and so on ...
function newUserFromTemplate($action="",$target=array(),$all=array())
{
// Call parent method, it knows whats to do, locking and so on ...
- management::newEntry($action,$target,$all);
+ $str = management::newEntry($action,$target,$all);
+ if(!empty($str)) return($str);
// Reset uid selection.
$this->got_uid= "";
// Reset uid selection.
$this->got_uid= "";
{
// Call parent method, it manages everything, locking, object creation...
{
// Call parent method, it manages everything, locking, object creation...
- management::newEntry($action,$target,$all);
+ $str = management::newEntry($action,$target,$all);
+ if(!empty($str)) return($str);
// If we've at least one template, then ask the user if he wants to use one?
$templates = array();
// If we've at least one template, then ask the user if he wants to use one?
$templates = array();
// Check entry locking
foreach($target as $dn){
if (($user= get_lock($dn)) != ""){
// Check entry locking
foreach($target as $dn){
if (($user= get_lock($dn)) != ""){
+ $this->dn = $dn;
return(gen_locked_message ($user, $dn));
}
$this->dns[] = $dn;
return(gen_locked_message ($user, $dn));
}
$this->dns[] = $dn;
*/
function lockUsers($action,$target,$all)
{
*/
function lockUsers($action,$target,$all)
{
+ if(!count($target)) return;
if($action == "lockUsers"){
$this->lockEntry($action,$target, $all, "lock");
}else{
if($action == "lockUsers"){
$this->lockEntry($action,$target, $all, "lock");
}else{
// Walk thru map
foreach ($map as $oc => $properties) {
if (in_array_ics($oc, $classes)) {
// Walk thru map
foreach ($map as $oc => $properties) {
if (in_array_ics($oc, $classes)) {
- $result.="<input class='center' type='image' src='".$properties['image']."' ".
- "alt='".$properties['alt']."' title='".$properties['title'].
- "' name='listing_edit_".$properties['plugin']."_$row' style='padding:1px'>";
+ $result.= image($properties['image'], "listing_edit_".$properties['plugin']."_$row", $properties['title']);
} else {
} else {
- $result.="<img src='images/empty.png' alt=' ' class='center' style='padding:1px'>";
+ $result.= image('images/empty.png');
}
}
return $result;
}
}
return $result;