[TOC]
简要描述
请求URL
http://172.17.10.52:8080/pyapi/kanban
负责人:谭自强
请求方式
请求参数
参数名 |
类型 |
说明 |
timeRange |
nvarchar |
时间范围: date, week, month |
ID |
bigint |
产品ID |
请求示例
{
"timeRange": "month",
"ID": 1
}
返回示例
# "timeRange": "week" or "month"
{
"code": 200,
"data": {
"production_chart": {
"x_axis": [
"2022-07-06",
"2022-07-08",
"2022-07-12",
"2022-07-14"
],
"y_axis_chk": [
0.0,
0.0,
1.0,
0.0
],
"y_axis_pred": [
0.0,
0.0,
0.0,
11.0
],
"y_axis_prod": [
1.0,
11.0,
0.0,
11.0
]
},
"statistic": {
"chk_num": 1,
"chk_rate": 4.2,
"ng_num": 12,
"ng_rate": 52.2,
"pass_num": 11,
"pass_rate": 47.8,
"total_num": 23
}
},
"msg": "success"
}
# "timeRange": "date"
{
"code": 200,
"data": {
"production_chart": null,
"statistic": {
"chk_num": 0,
"chk_rate": 0.0,
"ng_num": 11,
"ng_rate": 10.0,
"pass_num": 99,
"pass_rate": 90.0,
"total_num": 110
}
},
"msg": "success"
}
返回参数说明
参数名 |
类型 |
说明 |
data |
dict |
返回production_chart/statistic数据包 |
production_chart |
dict |
{"X坐标值": x_axis, "Y轴-总产量": y_axis_prod, "Y轴-预测量": y_axis_pred, "Y轴-抽检量": y_axis_chk};在查询本天数据时该字段为None |
statistic |
dict |
{"总产量": total_num, "PASS数": pass_num, "NG数": ng_num, "抽检量": chk_num, "PASS率": pass_rate, "NG率": ng_rate, "抽检率": check_rate} |
备注