mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-06-18 02:59:27 +00:00
allow sending login data only if enableEmail is set
This commit is contained in:
parent
31284c5688
commit
b3a41875b3
|
@ -265,7 +265,7 @@ else if ($action == "transferobjects") {
|
|||
}
|
||||
|
||||
// send login data to user
|
||||
else if ($action == "sendlogindata") {
|
||||
else if ($action == "sendlogindata" && $settings->_enableEmail) {
|
||||
/* Check if the form data comes from a trusted request */
|
||||
if(!checkFormKey('sendlogindata')) {
|
||||
UI::exitError(getMLText("admin_tools"),getMLText("invalid_request_token"));
|
||||
|
|
|
@ -49,7 +49,7 @@ if(isset($_GET['userid']) && $_GET['userid']) {
|
|||
}
|
||||
|
||||
$tmp = explode('.', basename($_SERVER['SCRIPT_FILENAME']));
|
||||
$view = UI::factory($theme, $tmp[1], array('dms'=>$dms, 'user'=>$user, 'seluser'=>$seluser, 'allusers'=>$users, 'allgroups'=>$groups, 'passwordstrength'=>$settings->_passwordStrength, 'passwordexpiration'=>$settings->_passwordExpiration, 'httproot'=>$settings->_httpRoot, 'enableuserimage'=>$settings->_enableUserImage, 'undeluserids'=>explode(',', $settings->_undelUserIds), 'workflowmode'=>$settings->_workflowMode, 'quota'=>$settings->_quota, 'strictformcheck'=>$settings->_strictFormCheck));
|
||||
$view = UI::factory($theme, $tmp[1], array('dms'=>$dms, 'user'=>$user, 'seluser'=>$seluser, 'allusers'=>$users, 'allgroups'=>$groups, 'passwordstrength'=>$settings->_passwordStrength, 'passwordexpiration'=>$settings->_passwordExpiration, 'httproot'=>$settings->_httpRoot, 'enableuserimage'=>$settings->_enableUserImage, 'undeluserids'=>explode(',', $settings->_undelUserIds), 'workflowmode'=>$settings->_workflowMode, 'quota'=>$settings->_quota, 'strictformcheck'=>$settings->_strictFormCheck, 'enableemail'=>$settings->_enableEmail));
|
||||
if($view) {
|
||||
$view($_GET);
|
||||
}
|
||||
|
|
|
@ -168,6 +168,7 @@ $(document).ready( function() {
|
|||
$quota = $this->params['quota'];
|
||||
$workflowmode = $this->params['workflowmode'];
|
||||
$undeluserids = $this->params['undeluserids'];
|
||||
$enableemail = $this->params['enableemail'];
|
||||
|
||||
if($seluser) {
|
||||
?>
|
||||
|
@ -185,7 +186,8 @@ $(document).ready( function() {
|
|||
echo '<li><a href="../out/out.TransferObjects.php?userid='.$seluser->getID().'"><i class="icon-share-alt"></i> '.getMLText("transfer_objects").'</a></li>';
|
||||
if($user->isAdmin() && $seluser->getID() != $user->getID())
|
||||
echo "<li><a href=\"../op/op.SubstituteUser.php?userid=".$seluser->getID()."&formtoken=".createFormKey('substituteuser')."\"><i class=\"icon-exchange\"></i> ".getMLText("substitute_user")."</a></li>\n";
|
||||
echo '<li><a href="../out/out.SendLoginData.php?userid='.$seluser->getID().'"><i class="icon-envelope-alt"></i> '.getMLText("send_login_data").'</a></li>';
|
||||
if($enableemail)
|
||||
echo '<li><a href="../out/out.SendLoginData.php?userid='.$seluser->getID().'"><i class="icon-envelope-alt"></i> '.getMLText("send_login_data").'</a></li>';
|
||||
?>
|
||||
</ul>
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue
Block a user