[TOC=2,3]
* * * * *
* * * * *
* * * * *
- ## 1. 获取在某段时间售出的产品列表信息
+++
get:/store/product/product_list
*string:time=默认值#可以为以下值:today/yesterday/this_week/last_week/this_month/last_month/this_quarter/last_quarter/year【PS: /store/product/product_list?time=this_month】
<<<
success
返回示例:
{
count: 1,
status: 200,
product_info: [
{
id: 3,
sid: "003",
add_time: "2016-12-01 00:00:00",
sale_time: "2016-12-05 14:49:10",
status: 1
}
],
product_type_name: [
"FOHEART-C1",
"FOHEART-TLE"
],
devices_type_name: [
"节点",
"插排",
"路由器",
"其他"
]
}
返回参数说明:
count: 符合产品的数量
product_info: 产品的信息
<<<
error
返回示例:
{
status: 400,
message: "没有产品信息!"
}
+++
* * * * *
* * * * *
* * * * *
- ## 2. 获取产品在不同状态下的列表信息
+++
get:/store/product/product_list
*int:status=默认值#可以为以下值:-1(有问题)/0(在库)/1(出售)
*string:product_type_name=默认值#可以为以下值:FOHEART-C1/FOHEART-TLE/等等【PS: /store/product/product_list?status=0&product_type_name=FOHEART-C1】
<<<
success
返回示例:
{
"product_type_name": [
"FOHEART-C1",
"FOHEART-TLE"
],
"devices_type_name": [
"节点",
"插排",
"路由器",
"其他"
],
"status": 200,
"product_info": [
{
"id": 2,
"sid": "002",
"product_type": "FOHEART-C1",
"add_time": "2015-12-01 00:00:00",
"sale_time": "2016-10-01 00:00:00",
"status": 0
},
{
"id": 1,
"sid": "001",
"product_type": "FOHEART-C1",
"add_time": "2014-12-01 00:00:00",
"sale_time": "2016-11-01 00:00:00",
"status": 0
}
],
"count": 2
}
返回参数说明:
count: 符合产品的数量
product_info: 产品的信息
<<<
error
返回示例:
{
status: 400,
message: "没有产品信息!"
}
+++
* * * * *
* * * * *
* * * * *
- ## 3. 各种查询条件查询产品列表信息
+++
post:/store/product/product_list
string:sid#每套产品唯一序列号
string:product_type_name#产品的类型名称
string:add_start_time#添加产品的开始时间
string:end_start_time#添加产品的结束时间
int:status#-1(有问题)/0(在库)/1(出售)
string:sale_start_time#售出产品的开始时间
string:sale_end_time#售出产品的结束时间
int:page=默认从第一页开始显示(全部数据)#显示第几页数据
int:list=默认为每页显示15条数据#每页多少条数据
<<<
success
{
count: 5,
status: 200,
product_info: [
{
id: 5,
sid: "005",
product_type: "FOHEART-TLE",
add_time: "2016-12-01 00:00:00",
sale_time: "2016-12-01 00:00:00",
status: 0
},
{
id: 4,
sid: "004",
product_type: "FOHEART-TLE",
add_time: "2016-12-01 00:00:00",
sale_time: "2016-12-01 00:00:00",
status: -1
},
{
id: 3,
sid: "003",
product_type: "FOHEART-C1",
add_time: "2016-12-01 00:00:00",
sale_time: "2016-12-05 14:49:10",
status: 1
},
{
id: 2,
sid: "002",
product_type: "FOHEART-C1",
add_time: "2015-12-01 00:00:00",
sale_time: "2016-10-01 00:00:00",
status: 0
},
{
id: 1,
sid: "001",
product_type: "FOHEART-C1",
add_time: "2014-12-01 00:00:00",
sale_time: "2016-11-01 00:00:00",
status: 0
}
],
product_type_name: [
"FOHEART-C1",
"FOHEART-TLE"
],
devices_type_name: [
"节点",
"插排",
"路由器",
"其他"
]
}
<<<
error
返回示例:
{
status: 400,
message: "没有产品信息!"
}
+++