This commit is contained in:
2025-08-13 19:09:29 +08:00
parent 275713f893
commit 75a410e376
3 changed files with 18 additions and 24 deletions

View File

@@ -4,10 +4,12 @@ namespace app\common\controller;
use app\common\library\Auth;
use app\common\library\token\TokenExpirationException;
use app\exception\MyBusinessException;
use support\exception\BusinessException;
use support\Request;
use HttpResponseException;
use support\Response;
abstract class BaseController
class BaseController
{
/**
* 无需登录的方法
@@ -189,7 +191,7 @@ abstract class BaseController
'time' => time(),
$dataKey => $data,
];
throw new \app\exception\HttpResponseException(json($result));
throw new MyBusinessException(json_encode($result));
}
public function ApiDataReturn($data)