Changeset 21611


Ignore:
Timestamp:
03/17/13 02:42:00 (6 years ago)
Author:
Eric
Message:

Bug 2872 fixed - Check if confirmed users group is set as the default group and set it if not

Location:
extensions/UserAdvManager/trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • extensions/UserAdvManager/trunk/admin/UAM_admin.php

    r21598 r21611  
    183183      $UAM_Illegal_Flag_Error1 = true; 
    184184      array_push($page['errors'], l10n('UAM_Error_Using_illegal_Kdays')); 
     185    } 
     186 
     187    // Check if VALIDATED_GROUP is set as the gallery's default group and set it as default if not 
     188    // Experimental : It's better the "validated users" group is the gallery's default group 
     189    // ------------------------------------------------------------------------------------------- 
     190    if (isset($_POST['UAM_Validated_Group']) and $_POST['UAM_Validated_Group'] <> '-1') 
     191    { 
     192      $query = ' 
     193SELECT name, is_default 
     194FROM '.GROUPS_TABLE.' 
     195WHERE id = '.$_POST['UAM_Validated_Group'].' 
     196;'; 
     197 
     198      $UAM_group = pwg_db_fetch_assoc(pwg_query($query)); 
     199 
     200      if (isset($UAM_group['is_default']) and $UAM_group['is_default'] == "false") 
     201      { 
     202        $query = ' 
     203UPDATE '.GROUPS_TABLE.' 
     204SET is_default = true 
     205WHERE id = '.$_POST['UAM_Validated_Group'].' 
     206;'; 
     207        pwg_query($query); 
     208 
     209        array_push( 
     210          $page['infos'], 
     211          sprintf(l10n('UAM_group "%s" updated'), $UAM_group['name']) 
     212        ); 
     213      } 
    185214    } 
    186215 
  • extensions/UserAdvManager/trunk/changelog.txt.php

    r21606 r21611  
    401401-- 2.50.3 : Bug 2870 fixed - Error in tracking confirmation tab if $conf['default_user_id'] is set with an ID different than Guest user ID 
    402402            Bug 2871 fixed - Improved process : User registration is confirmed by default when user is added by an admin and confirmation of registration for admins is set to OFF 
     403            Bug 2872 fixed - Check if confirmed users group is set as the default group and set it if not 
    403404*/ 
    404405?> 
  • extensions/UserAdvManager/trunk/language/en_UK/plugin.lang.php

    r19234 r21611  
    424424$lang['UAM_Customize_messagesandmails'] = 'Customize the messages and mails'; 
    425425$lang['UAM_Change'] = 'Change the Group/Status/Privacy Level of the users who have been confirmed'; 
    426  
    427426// --------- End: New or revised $lang ---- from version 2.41.0 
     427 
     428$lang['UAM_group "%s" updated'] = 'For best performance, the group %s was automatically set as the default group.'; 
    428429?> 
  • extensions/UserAdvManager/trunk/language/fr_FR/plugin.lang.php

    r21075 r21611  
    426426$lang['UAM_Change'] = 'Changer l\'utilisateur confirmé de Groupe/Statut/Niveau de confidentialité'; 
    427427// --------- End: New or revised $lang ---- from version 2.41.0 
     428 
     429$lang['UAM_group "%s" updated'] = 'Pour un meilleur fonctionnement, le groupe %s a été automatiquement positionné comme groupe par défault.'; 
    428430?> 
Note: See TracChangeset for help on using the changeset viewer.