1
This commit is contained in:
@@ -766,10 +766,20 @@ class User extends Controller
|
||||
$this->user_act_obj->where($act_where)->update(['state' => 1]);
|
||||
return json(['code' => 0]);
|
||||
} else {
|
||||
return json(['code' => 1, 'msg' => '失败!']);
|
||||
return json(['code' => 1, 'msg' => 'fail']);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public function getUserForJournal(){
|
||||
$data = $this->request->post();
|
||||
$num = $data['num'];
|
||||
$limit_start = ($num - 1) * 1000;
|
||||
$list = $this->user_obj->limit($limit_start,1000)->select();
|
||||
$re['list'] = $list;
|
||||
return jsonSuccess($re);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改用户备注
|
||||
*/
|
||||
@@ -805,13 +815,13 @@ class User extends Controller
|
||||
$data = $this->request->post();
|
||||
//验证验证码
|
||||
if (!$this->my_checkcaptcha($data['code'], $data['random_num'])) {
|
||||
return json(['code' => 1, 'msg' => '验证码错误']);
|
||||
return json(['code' => 1, 'msg' => 'Wrong captcha']);
|
||||
}
|
||||
$res = $this->user_obj
|
||||
->where('account|email', $data['username'])
|
||||
->find();
|
||||
if ($res == null) {
|
||||
return json(['code' => 1, 'msg' => '查无此人']);
|
||||
return json(['code' => 1, 'msg' => 'Incorrect user ID or password']);
|
||||
} else {
|
||||
return json(['code' => 0, 'email' => $res['email']]);
|
||||
}
|
||||
@@ -854,9 +864,9 @@ class User extends Controller
|
||||
$where['state'] = 0;
|
||||
$res = $this->user_act_obj->where($where)->find();
|
||||
if ($res == null) {
|
||||
return json(['code' => 1, 'msg' => '查询失败']);
|
||||
return json(['code' => 1, 'msg' => 'Query failed']);
|
||||
} else {
|
||||
return json(['code' => 0, 'msg' => '查询成功']);
|
||||
return json(['code' => 0, 'msg' => 'Query was successful']);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user