* Check key when integrate with ranzhi.
This commit is contained in:
@@ -170,6 +170,7 @@ class commonModel extends model
|
||||
if($module == 'sso' and $method == 'gettodolist') return true;
|
||||
if($module == 'product' and $method == 'showerrornone') return true;
|
||||
if($module == 'block' and $method == 'printblock') return true;
|
||||
if($module == 'block' and $method == 'main') return true;
|
||||
|
||||
if($this->loadModel('user')->isLogon())
|
||||
{
|
||||
|
||||
@@ -192,6 +192,7 @@ class sso extends control
|
||||
*/
|
||||
public function getUserPairs()
|
||||
{
|
||||
if(!$this->sso->checkKey()) return false;
|
||||
$users = $this->loadModel('user')->getPairs('noclosed,nodeleted');
|
||||
die(json_encode($users));
|
||||
}
|
||||
@@ -204,6 +205,7 @@ class sso extends control
|
||||
*/
|
||||
public function getBindUsers()
|
||||
{
|
||||
if(!$this->sso->checkKey()) return false;
|
||||
$users = $this->sso->getBindUsers();
|
||||
die(json_encode($users));
|
||||
}
|
||||
@@ -250,6 +252,8 @@ class sso extends control
|
||||
*/
|
||||
public function getTodoList($account = '')
|
||||
{
|
||||
if(!$this->sso->checkKey()) return false;
|
||||
|
||||
$datas = array();
|
||||
$datas['task'] = $this->dao->select("id, name")->from(TABLE_TASK)->where('assignedTo')->eq($account)->andWhere('status')->in('wait,doing')->fetchPairs();
|
||||
$datas['bug'] = $this->dao->select("id, title")->from(TABLE_BUG)->where('assignedTo')->eq($account)->andWhere('status')->eq('active')->fetchPairs();
|
||||
|
||||
@@ -660,7 +660,7 @@ class user extends control
|
||||
if($this->post->account) $account = $this->post->account;
|
||||
if($this->get->account) $account = $this->get->account;
|
||||
if($this->post->password) $password = $this->post->password;
|
||||
if($this->get->password) $password = $this->get->password;
|
||||
if($this->get->password) $password = base64_decode($this->get->password);
|
||||
|
||||
if($this->user->checkLocked($account))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user