From a34fc1495b6211b471fb3cee7b7d469ea3ce8117 Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Mon, 6 Dec 2021 16:37:25 +0800 Subject: [PATCH] 1 --- doc/User.py | 14 ++++++++++++++ doc/_common.py | 41 ++++++++++++++++++++++++++++++++++++++++- 2 files changed, 54 insertions(+), 1 deletion(-) diff --git a/doc/User.py b/doc/User.py index ae9780d..1b64e83 100644 --- a/doc/User.py +++ b/doc/User.py @@ -80,4 +80,18 @@ class User(object): ['info',_common.UserInfo(), '用户信息'], ] }, + { + 'name': 'detailInfo', + 'desc': '获取用户信息(详细)', + 'group': 'User', + 'url': 'webapp/index.php?c=User&a=detailInfo', + 'params': [ + _common.ReqHead(), + ['target_id', '', '用户account_id(如果要获取自己的就传自己的account_id)'] + ], + 'response': [ + _common.RspHead(), + ['info',_common.UserDetailInfo(), '用户信息(详细)'], + ] + }, ] diff --git a/doc/_common.py b/doc/_common.py index 97b04f6..73701e7 100644 --- a/doc/_common.py +++ b/doc/_common.py @@ -52,6 +52,45 @@ class UserInfo(object): ['!head_frame_list', [0], '拥有的头像框列表'], ] +class UserDetailInfo(object): + + def __init__(self): + self.fields = [ + ['activate', 0, '是否已激活'], + ['account_id', '', '账号id'], + ['name', '', '用户名字'], + ['head_id', 0, '头像id'], + ['head_frame', 0, '头像框id'], + ['level', 0, '等级'], + ['exp', 0, '经验'], + ['gold', 0, '金币'], + ['diamond', 0, '钻石'], + ['hero_id', 0, '当前使用的英雄ID'], + ['current_rank', 0, '当前段位'], + ['history_best_rank', 0, '历史最高段位'], + ['!history_seasons', [UserHisSeason()], '历史打过的赛季列表'], + ] + +class UserHisSeason(object): + + def __init__(self): + self.fields = [ + ['season_id', 0, '赛季'], + ['total_kills', 0, '击杀总数(个人信息)'], + ['game_times', 0, '游戏场次(个人信息)'], + ['win_times', 0, '胜利场次(个人信息)'], + ['win_rate', 0, '胜率(个人信息,百分比数值整数部分)'], + ['max_kills', 0, '最高击杀(游戏信息)'], + ['avg_kills', 0, '平均击杀(游戏信息)'], + ['max_damage_out', 0, '最高伤害输出(游戏信息)'], + ['avg_damage_out', 0, '平均伤害输出(游戏信息)'], + ['star_kills', 0, '击败(5纬图-击败, 百分比数值整数部分)'], + ['star_damage', 0, '伤害(5纬图-伤害, 百分比数值整数部分)'], + ['star_alive', 0, '生存(5纬图-生存, 百分比数值整数部分)'], + ['star_recover', 0, '治疗(5纬图-治疗, 百分比数值整数部分)'], + ['star_win', 0, '胜利(5纬图-胜利, 百分比数值整数部分)'], + ] + class Hero(object): def __init__(self): @@ -244,5 +283,5 @@ class RankingList(object): self.fields = [ ['type', 0, '排行榜类型 1:积分榜'], ['!ranking_list', [RankingItem()], '排行榜'], - ['my_ranked', 0, '我的排名'], + ['my_ranked', RankingItem(), '我的排名(如果ranked<1则表示自己未上榜)'], ]