From b26bbbb60cd8f0e72cde9339287f29275f6a118c Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Tue, 2 Jul 2024 14:57:49 +0800 Subject: [PATCH] 1 --- doc/AALogin.py | 32 ++++++++++++++++++++- webapp/controller/ToolsController.class.php | 8 +++--- 2 files changed, 35 insertions(+), 5 deletions(-) diff --git a/doc/AALogin.py b/doc/AALogin.py index 7f0209e0..deaa7265 100644 --- a/doc/AALogin.py +++ b/doc/AALogin.py @@ -82,7 +82,7 @@ class AALogin(object): { 'method': 'POST', 'name': 'auth2', - 'desc': '登录验证', + 'desc': '登录验证(errcode == 505 需要验证码)', 'group': '!AALogin', 'url': 'https://login-test.kingsome.cn/webapp/index.php?c=Login&a=auth2', 'is_json_params': True, @@ -97,6 +97,36 @@ class AALogin(object): ['server_time', 0, '回合制专用字段-服务器当前utc时间'], ] }, + { + 'method': 'POST', + 'name': 'verifyAccount', + 'desc': '校验账号信息', + 'group': '!AALogin', + 'url': 'https://login-test.kingsome.cn/webapp/index.php?c=Login&a=verifyAccount', + 'is_json_params': True, + 'params': [ + ['data', '', 'idtoken'], + ], + 'response': [ + _common.RspHead(), + ['state', '', '账号状态 1:可以直接进游戏 2:需要兑换码'], + ] + }, + { + 'method': 'POST', + 'name': 'useExchangeCode', + 'desc': '使用兑换码', + 'group': '!AALogin', + 'url': 'https://login-test.kingsome.cn/webapp/index.php?c=Login&a=useExchangeCode', + 'is_json_params': True, + 'params': [ + ['exchange_code', '', '兑换码'], + ['data', '', 'idtoken'], + ], + 'response': [ + _common.RspHead(), + ] + }, { 'name': 'getSwitch', 'desc': '获取开关', diff --git a/webapp/controller/ToolsController.class.php b/webapp/controller/ToolsController.class.php index 4e23961e..092077e3 100644 --- a/webapp/controller/ToolsController.class.php +++ b/webapp/controller/ToolsController.class.php @@ -13,10 +13,10 @@ class ToolsController extends BaseController { public function _handlePre() { parent::_handlePre(); -// if (SERVER_ENV == _ONLINE) { -// die("can't create ToolsController"); -// return; -// } + if (SERVER_ENV == _ONLINE) { + die("can't create ToolsController"); + return; + } } public function test()