首页修改,jk8修改,历史记录相关,api权限

This commit is contained in:
2026-06-04 10:53:45 +08:00
parent 95684c784e
commit 1975d24db3
16 changed files with 565 additions and 96 deletions

View File

@@ -0,0 +1,35 @@
<?php
namespace app\api\controller;
use Throwable;
use ba\Captcha;
use ba\ClickCaptcha;
use think\facade\Validate;
use app\common\model\User;
use app\common\library\Email;
use app\common\controller\Frontend;
use PHPMailer\PHPMailer\Exception as PHPMailerException;
class External extends Frontend
{
protected array $noNeedLogin = ['depositNotify'];
public function initialize(): void
{
parent::initialize();
}
public function depositNotify(): void
{
try {
} catch (PHPMailerException) {
}
$this->success(__('Mail sent successfully~'));
}
}

18
app/api/route/app.php Normal file
View File

@@ -0,0 +1,18 @@
<?php
use app\common\middleware\ApiAuth;
use think\facade\Route;
Route::group('external', function () {
Route::post('register-notify', 'External/registerNotify');
Route::post('deposit-notify', 'External/depositNotify');
Route::post('withdrawal-notify', 'External/withdrawalNotify');
Route::post('agent-notify', 'External/agentNotify');
});
Route::group('external', function () {
// 这里面的所有路由都会经过 ApiAuth 中间件
Route::post('test', 'Account/test');
Route::post('user-withdraw', 'Withdraw/apply');
})->middleware(ApiAuth::class);