* Send encrypted password when creating user by API.

This commit is contained in:
zhujinyong
2021-09-24 14:50:27 +08:00
parent b866ebe1fd
commit eb04910243
2 changed files with 4 additions and 51 deletions
+4 -2
View File
@@ -48,8 +48,10 @@ class usersEntry extends entry
$fields = 'account,dept,realname,email,commiter,gender';
$this->batchSetPost($fields);
$this->setPost('password1', $this->request('password'));
$this->setPost('password2', $this->request('password'));
$password = $this->request('password', '') ? md5($this->request('password')) : '';
$this->setPost('password1', $password);
$this->setPost('password2', $password);
$this->setPost('passwordStrength', 3);
$this->setPost('verifyPassword', md5($this->app->user->password . $this->app->session->rand));
-49
View File
@@ -1,49 +0,0 @@
<?php
/**
* The run result of testcase.
*
* All request of entries should be routed by this router.
*
* @copyright Copyright 2009-2021 青岛易软天创网络科技有限公司(QingDao Nature Easy Soft Network Technology Co,LTD, www.cnezsoft.com)
* @license ZPL (http://zpl.pub/page/zplv12.html)
* @author Guanxing <guanxiying@easycorp.ltd>
* @package ZenTaoPMS
* @version $Id: $
* @link http://www.zentao.net
*/
class result
{
/**
* Original run result.
*
* @var mixed
* @access private
*/
private $runResult;
/**
* Properties for testing.
*
* @var string
* @access private
*/
private $properties = '';
/**
* Check properties of result.
*
* @param string $fields If fields is empty, print result.
* @access public
*/
public function check($properties)
{
$this->properties = $properties;
}
public function expect($expect)
{
if($this->properties)
{
}
}
}