|
...
|
...
|
@@ -10,6 +10,7 @@ use App\Http\Logic\Bside\User\UserLogic; |
|
|
|
use App\Http\Logic\Bside\User\UserLoginLogic;
|
|
|
|
use App\Models\Project\Project;
|
|
|
|
use App\Models\Project\Project as ProjectModel;
|
|
|
|
use App\Models\Service\Service;
|
|
|
|
use App\Models\SmsLog;
|
|
|
|
use App\Models\User\ProjectMenu as ProjectMenuModel;
|
|
|
|
use App\Models\User\ProjectRole as ProjectRoleModel;
|
|
...
|
...
|
@@ -54,12 +55,17 @@ class ComController extends BaseController |
|
|
|
*/
|
|
|
|
public function autologin(UserLoginLogic $logic, EncryptUtils $encrypt)
|
|
|
|
{
|
|
|
|
$data = $encrypt->unlock_url($this->param['code'], 'v6.globalso.com');
|
|
|
|
$serviceSettingModel = new Service();
|
|
|
|
$info = $serviceSettingModel->read(['type'=>4]);
|
|
|
|
if($info === false){
|
|
|
|
$this->response('当前访问地址不存在',Code::USER_ERROR);
|
|
|
|
}
|
|
|
|
$data = $encrypt->unlock_url($this->param['code'], $info['values']);
|
|
|
|
$data = json_decode($data, true);
|
|
|
|
if(empty($data['project_id'])){
|
|
|
|
if(!isset($data['project_id']) || !isset($data['user_id'])){
|
|
|
|
$this->response('无效Code',Code::USER_ERROR);
|
|
|
|
}
|
|
|
|
$res = $logic->autologin($data['project_id']);
|
|
|
|
$res = $logic->autologin($data);
|
|
|
|
$this->response('请求成功',Code::SUCCESS, $res);
|
|
|
|
}
|
|
|
|
|
...
|
...
|
|