game2006api/doc/InGameMall.py
2024-08-01 16:21:54 +08:00

152 lines
5.9 KiB
Python

# -*- coding: utf-8 -*-
import _common
class InGameMall(object):
def __init__(self):
self.apis = [
{
'name': 'productList',
'desc': '商品列表',
'group': 'InGameMall',
'url': 'webapp/index.php?c=InGameMall&a=productList',
'params': [
_common.ReqHead(),
['page', 0, '第几页数据'],
['seller', '', '查询指定账号'],
['order_method', 0, '排序方式 0:默认排序(当前指向1) 1:上架时间 2:价格'],
['order_asc', 0, '排序方向, 0:从小到大 1:从大到小'],
['price_filter', '', '价格过滤(用|分割)'],
['type_filter', '', '类型过滤 1:英雄皮肤 2:芯片 3:英雄碎片 11:其它(材料、宝箱)'],
['item_filter', '', 'itemId过滤(用|分割)'],
['quality_filter', '', '品质过滤'],
],
'response': [
_common.RspHead(),
['pagination', _common.Pagination(), '分页信息'],
['!rows', [_common.InGameMallGoods()], '商品列表']
]
},
{
'name': 'sellS',
'desc': '出售',
'group': 'InGameMall',
'surl': 'webapp/index.php?c=InGameMall&a=sellS',
'params': [
_common.ReqHead(),
['goods_uniid', '', '道具id'],
['item_id', '', '道具itemId'],
['amount', '', '出售数量'],
['price', '', '出售价格'],
],
'response': [
_common.RspHead()
]
},
{
'name': 'buyS',
'desc': '购买',
'group': 'InGameMall',
'surl': 'webapp/index.php?c=InGameMall&a=buyS',
'params': [
_common.ReqHead(),
['order_id', '', '订单id'],
],
'response': [
_common.RspHead(),
['property_chg', _common.PropertyChg(), '属性变更'],
]
},
{
'name': 'cancelS',
'desc': '下架物品',
'group': 'InGameMall',
'surl': 'webapp/index.php?c=InGameMall&a=cancelS',
'params': [
_common.ReqHead(),
['order_id', '', '订单id'],
],
'response': [
_common.RspHead(),
['property_chg', _common.PropertyChg(), '属性变更'],
]
},
{
'name': 'modifyPrice',
'desc': '修改价格',
'group': 'InGameMall',
'url': 'webapp/index.php?c=InGameMall&a=modifyPrice',
'params':[
_common.ReqHead(),
['order_id', '', '订单id'],
['price', '', '价格'],
],
'response': [
_common.RspHead()
]
},
{
'name': 'sellList',
'desc': '出售记录',
'group': 'InGameMall',
'url': 'webapp/index.php?c=InGameMall&a=sellList',
'params':[
_common.ReqHead(),
['page', 0, '第几页数据'],
['order_method', 0, '排序方式 0:默认排序(当前指向1) 1:购买时间 2:价格'],
['order_asc', 0, '排序方向, 0:从小到大 1:从大到小'],
],
'response': [
_common.RspHead(),
['pagination', _common.Pagination(), '分页信息'],
['!rows', [_common.InGameMallGoods()], '商品列表']
]
},
{
'name': 'buyList',
'desc': '购买记录',
'group': 'InGameMall',
'url': 'webapp/index.php?c=InGameMall&a=buyList',
'params':[
_common.ReqHead(),
['page', 0, '第几页数据'],
['order_method', 0, '排序方式 0:默认排序(当前指向1) 1:购买时间 2:价格'],
['order_asc', 0, '排序方向, 0:从小到大 1:从大到小'],
],
'response': [
_common.RspHead(),
['pagination', _common.Pagination(), '分页信息'],
['!rows', [_common.InGameMallGoods()], '商品列表']
]
},
{
'name': 'shoppingCartList',
'desc': '购物车列表',
'group': 'InGameMall',
'url': 'webapp/index.php?c=InGameMall&a=shoppingCartList',
'params':[
_common.ReqHead(),
['order_ids', '', '订单id(多个订单用 | 隔开)'],
],
'response': [
_common.RspHead(),
['!list', [_common.InGameMallGoods()], '商品列表']
]
},
{
'name': 'shoppingCartBuyS',
'desc': '购物车下单',
'group': 'InGameMall',
'surl': 'webapp/index.php?c=InGameMall&a=shoppingCartBuyS',
'params':[
_common.ReqHead(),
['order_ids', '', '订单id(多个订单用 | 隔开)'],
],
'response': [
_common.RspHead(),
['property_chg', _common.PropertyChg(), '属性变更'],
]
},
]