Browse Source

物料接口测试调整

master
吕成旭 1 year ago
parent
commit
7570243007
  1. 72
      mes/物料/修改物料.md
  2. 99
      mes/物料/列出物料.md
  3. 62
      mes/物料/列出物料类别.md
  4. 4
      mes/物料/删除物料.md
  5. 97
      mes/物料/查询物料详情.md
  6. 73
      mes/物料/添加物料.md

72
mes/物料/修改物料.md

@ -35,37 +35,33 @@ attrs字段
| attrName | string | 否 | 属性名称 | | attrName | string | 否 | 属性名称 |
| attrValue | string | 否 | 物料属性值 | | attrValue | string | 否 | 物料属性值 |
| attrValueCode | string | 否 | 物料属性值代码 | | attrValueCode | string | 否 | 物料属性值代码 |
| flag | int | 否 | 数据状态:0禁用 1启用,默认1 |
示例 1:修改电池片及物料属性值 示例 1:修改电池片及物料属性值
``` ```
{ {
"data": { "data": {
profile: "测试厂区", "profile": "测试",
materialCode: "CELL001", "materialCode": "CELL002",
materialTypeCode: "CELL", "materialTypeCode": "CELL",
descriptions: "电池片描述", "descriptions": "电池片描述",
flag: 1, "attrs": [{
attrs: [{ "materialCode": "CELL002",
materialCode: "CELL001", "materialTypeCode": "CELL",
materialTypeCode: "CELL", "attrCode": "crys_type",
attrCode: "crys_type", "attrName": "晶体结构",
attrName: "晶体结构", "attrValue": "单晶",
attrValue: "单晶", "attrValueCode": "单晶"
attrValueCode: "单晶",
flag: 1
}, },
{ {
materialCode: "CELL001", "materialCode": "CELL002",
materialTypeCode: "CELL", "materialTypeCode": "CELL",
attrCode: "cell_uop", "attrCode": "cell_uop",
attrName: "单片功率", "attrName": "单片功率",
attrValue: "7.82", "attrValue": "7.88",
attrValueCode: "7.82", "attrValueCode": "7.88"
flag: 1
} }
], ]
} }
} }
``` ```
@ -80,9 +76,37 @@ attrs字段
``` ```
{ {
"clock": "2023-06-25 20:00:00.000", "clock": "2023-07-05 14:37:28.022",
"status": "ok", "status": "ok",
"data": {} "data": {
"info": {
"materialCode": "CELL002",
"materialTypeCode": "CELL",
"materialTypeDesc": "电池片",
"descriptions": "电池片描述",
"createTime": "2023-07-05 14:29:40.007",
"attrs": [
{
"materialCode": "CELL002",
"materialTypeCode": "CELL",
"materialTypeDesc": "电池片",
"attrCode": "cell_uop",
"attrName": "单片功率",
"attrValue": "7.88",
"attrValueCode": "7.88"
},
{
"materialCode": "CELL002",
"materialTypeCode": "CELL",
"materialTypeDesc": "电池片",
"attrCode": "crys_type",
"attrName": "晶体结构",
"attrValue": "单晶",
"attrValueCode": "单晶"
}
]
}
}
} }
``` ```

99
mes/物料/列出物料.md

@ -27,21 +27,9 @@ URL: http://localhost:8033/open/ListMaterial
``` ```
{ {
"data": { "data": {
profile: "测试厂区", "profile": "测试",
search: "玻璃", "search": "001",
type: "" "type": "CELL"
}
}
```
示例 2:根据物料类别查询玻璃主材
```
{
"data": {
profile: "测试厂区",
search: "",
type: "GLASS"
} }
} }
``` ```
@ -79,38 +67,65 @@ attrs字段
``` ```
{ {
"clock": "2023-06-25 20:00:00.000", "clock": "2023-07-05 14:12:33.463",
"status": "ok", "status": "ok",
"data": { "data": {
list: [{ "list": [
materialCode: "CELL001", {
materialTypeCode: "CELL", "materialCode": "20230704001",
materialTypeDesc: "电池片", "materialTypeCode": "CELL",
descriptions: "电池片描述", "materialTypeDesc": "电池片",
flag: 1, "descriptions": "测试电池片",
createTime: "2023-04-09 18:10:01", "createTime": "2023-07-04 13:38:41.100",
attrs: [{ "attrs": [
materialCode: "CELL001", {
materialTypeCode: "CELL", "materialCode": "20230704001",
materialTypeDesc: "电池片", "materialTypeCode": "CELL",
attrCode: "crys_type", "materialTypeDesc": "电池片",
attrName: "晶体结构", "attrCode": "cell_uop",
attrValue: "单晶", "attrName": "单片功率",
attrValueCode: "单晶", "attrValue": "7.24",
flag: 1 "attrValueCode": ""
}
]
}, },
{ {
materialCode: "CELL001", "materialCode": "dianchi0001",
materialTypeCode: "CELL", "materialTypeCode": "CELL",
materialTypeDesc: "电池片", "materialTypeDesc": "电池片",
attrCode: "cell_uop", "descriptions": "电池01",
attrName: "单片功率", "createTime": "2023-06-08 16:00:50.750",
attrValue: "7.82", "attrs": [
attrValueCode: "7.82", {
flag: 1 "materialCode": "dianchi0001",
"materialTypeCode": "CELL",
"materialTypeDesc": "电池片",
"attrCode": "cell_eff",
"attrName": "电池效率",
"attrValue": "24",
"attrValueCode": ""
},
{
"materialCode": "dianchi0001",
"materialTypeCode": "CELL",
"materialTypeDesc": "电池片",
"attrCode": "cell_uop",
"attrName": "单片功率",
"attrValue": "23",
"attrValueCode": ""
},
{
"materialCode": "dianchi0001",
"materialTypeCode": "CELL",
"materialTypeDesc": "电池片",
"attrCode": "d",
"attrName": "d",
"attrValue": "123",
"attrValueCode": "123"
}
]
} }
], ]
}]
} }
} }
``` ```

62
mes/物料/列出物料类别.md

@ -21,13 +21,12 @@ URL: http://localhost:8033/open/ListMaterialType
| profile | string | 是 | 厂区代码 | | profile | string | 是 | 厂区代码 |
| search | string | 否 | 物料类型模糊查询 | | search | string | 否 | 物料类型模糊查询 |
示例 1:模糊查询电池物料类别 示例 1:查询物料类别
``` ```
{ {
"data": { "data": {
profile: "测试厂区", "profile": "测试",
search: "电池",
} }
} }
``` ```
@ -43,7 +42,6 @@ URL: http://localhost:8033/open/ListMaterialType
| materialTypeCode | string | 物料类别代码 | | materialTypeCode | string | 物料类别代码 |
| materialTypeDesc | string | 物料类别名称 | | materialTypeDesc | string | 物料类别名称 |
| unit | string | 单位 | | unit | string | 单位 |
| flag | int | 数据状态:0禁用 1启用 |
| ManagerType | string | 创建时间 | | ManagerType | string | 创建时间 |
| Sort | int | 序号 | | Sort | int | 序号 |
| ErpCode | string | | | ErpCode | string | |
@ -53,26 +51,50 @@ URL: http://localhost:8033/open/ListMaterialType
``` ```
{ {
"clock": "2023-06-25 20:00:00.000", "clock": "2023-07-05 14:14:46.536",
"status": "ok", "status": "ok",
"data": { "data": {
list: [{ "list": [
materialTypeCode: "CELL",
materialTypeDesc: "电池片", {
unit: "pcs", "materialTypeCode": "Battery",
flag: 1, "materialTypeDesc": "电池材料",
ManagerType: "Photovoltaic", "unit": "",
Sort: 1, "managerType": "",
ErpCode: "", "sort": 0,
"erpCode": " "
},
{
"materialTypeCode": "BKSHEET",
"materialTypeDesc": "背板",
"unit": "m2",
"managerType": "Photovoltaic",
"sort": 5,
"erpCode": "#F06#,#F06# "
},
{
"materialTypeCode": "BOMID",
"materialTypeDesc": "BOMID",
"unit": "",
"managerType": "Photovoltaic",
"sort": 0,
"erpCode": " "
},
{
"materialTypeCode": "CELL",
"materialTypeDesc": "电池片",
"unit": "pcs",
"managerType": "Photovoltaic",
"sort": 1,
"erpCode": "#D#,#D# "
}, },
{ {
materialTypeCode: "EVA", "materialTypeCode": "EVA",
materialTypeDesc: "EVA", "materialTypeDesc": "EVA",
unit: "m2", "unit": "m2",
flag: 1, "managerType": "Photovoltaic",
ManagerType: "Photovoltaic", "sort": 2,
Sort: 2, "erpCode": "#H0603#,#H0603# "
ErpCode: "",
} }
] ]
} }

4
mes/物料/删除物料.md

@ -26,8 +26,8 @@ URL: http://localhost:8033/open/DeleteMaterial
``` ```
{ {
"data": { "data": {
profile: "测试厂区", "profile": "测试",
materialCode: "CELL001", "materialCode": "Z测试1"
} }
} }
``` ```

97
mes/物料/查询物料详情.md

@ -26,8 +26,8 @@ URL: http://localhost:8033/open/GetMaterial
``` ```
{ {
"data": { "data": {
profile: "测试厂区", "profile": "测试",
materialCode: "CELL001", "materialCode": "M.1.1.N.107"
} }
} }
``` ```
@ -65,37 +65,78 @@ attrs字段
``` ```
{ {
"clock": "2023-06-25 20:00:00.000", "clock": "2023-07-05 14:04:45.089",
"status": "ok", "status": "ok",
"data": { "data": {
info: { "info": {
materialCode: "CELL001", "materialCode": "M.1.1.N.107",
materialTypeCode: "CELL", "materialTypeCode": "CELL",
materialTypeDesc: "电池片", "materialTypeDesc": "电池片",
descriptions: "电池片描述", "descriptions": "电池片",
flag: 1, "flag": 1,
createTime: "2023-04-09 18:10:01", "createTime": "2023-04-08 23:43:38.023",
attrs: [{ "attrs": [
materialCode: "CELL001", {
materialTypeCode: "CELL", "materialCode": "M.1.1.N.107",
materialTypeDesc: "电池片", "materialTypeCode": "CELL",
attrCode: "crys_type", "materialTypeDesc": "电池片",
attrName: "晶体结构", "attrCode": "cell_uop",
attrValue: "单晶", "attrName": "单片功率",
attrValueCode: "单晶", "attrValue": "7.82",
flag: 1 "attrValueCode": "",
"flag": 1
},
{
"materialCode": "M.1.1.N.107",
"materialTypeCode": "CELL",
"materialTypeDesc": "电池片",
"attrCode": "cell_color",
"attrName": "电池颜色",
"attrValue": "淡蓝",
"attrValueCode": "",
"flag": 1
},
{
"materialCode": "M.1.1.N.107",
"materialTypeCode": "CELL",
"materialTypeDesc": "电池片",
"attrCode": "cell_grade",
"attrName": "电池等级",
"attrValue": "A",
"attrValueCode": "",
"flag": 1
},
{
"materialCode": "M.1.1.N.107",
"materialTypeCode": "CELL",
"materialTypeDesc": "电池片",
"attrCode": "cell_size",
"attrName": "电池规格",
"attrValue": "M10",
"attrValueCode": "",
"flag": 1
},
{
"materialCode": "M.1.1.N.107",
"materialTypeCode": "CELL",
"materialTypeDesc": "电池片",
"attrCode": "cell_eff",
"attrName": "电池效率",
"attrValue": "22.9%",
"attrValueCode": "",
"flag": 1
}, },
{ {
materialCode: "CELL001", "materialCode": "M.1.1.N.107",
materialTypeCode: "CELL", "materialTypeCode": "CELL",
materialTypeDesc: "电池片", "materialTypeDesc": "电池片",
attrCode: "cell_uop", "attrCode": "cell_type",
attrName: "单片功率", "attrName": "电池类型",
attrValue: "7.82", "attrValue": "N",
attrValueCode: "7.82", "attrValueCode": "",
flag: 1 "flag": 1
} }
], ]
} }
} }
} }

73
mes/物料/添加物料.md

@ -23,7 +23,6 @@ URL: http://localhost:8033/open/AddMaterial
| materialTypeCode | string | 是 | 物料类别代码 | | materialTypeCode | string | 是 | 物料类别代码 |
| descriptions | string | 否 | 物料描述 | | descriptions | string | 否 | 物料描述 |
| attrs | Array | 否 | 物料属性 | | attrs | Array | 否 | 物料属性 |
| flag | int | 否 | 数据状态:0禁用 1启用,默认1|
attrs字段 attrs字段
@ -35,37 +34,33 @@ attrs字段
| attrName | string | 否 | 属性名称 | | attrName | string | 否 | 属性名称 |
| attrValue | string | 否 | 物料属性值 | | attrValue | string | 否 | 物料属性值 |
| attrValueCode | string | 否 | 物料属性值代码 | | attrValueCode | string | 否 | 物料属性值代码 |
| flag | int | 否 | 数据状态:0禁用 1启用,默认1 |
示例 1:添加电池片及物料属性值 示例 1:添加电池片及物料属性值
``` ```
{ {
"data": { "data": {
profile: "测试厂区", "profile": "测试",
materialCode: "CELL001", "materialCode": "CELL002",
materialTypeCode: "CELL", "materialTypeCode": "CELL",
descriptions: "电池片描述", "descriptions": "电池片描述",
flag: 1, "attrs": [{
attrs: [{ "materialCode": "CELL002",
materialCode: "CELL001", "materialTypeCode": "CELL",
materialTypeCode: "CELL", "attrCode": "crys_type",
attrCode: "crys_type", "attrName": "晶体结构",
attrName: "晶体结构", "attrValue": "单晶",
attrValue: "单晶", "attrValueCode": "单晶"
attrValueCode: "单晶",
flag: 1
}, },
{ {
materialCode: "CELL001", "materialCode": "CELL002",
materialTypeCode: "CELL", "materialTypeCode": "CELL",
attrCode: "cell_uop", "attrCode": "cell_uop",
attrName: "单片功率", "attrName": "单片功率",
attrValue: "7.82", "attrValue": "7.82",
attrValueCode: "7.82", "attrValueCode": "7.82"
flag: 1
} }
], ]
} }
} }
``` ```
@ -79,9 +74,37 @@ attrs字段
``` ```
{ {
"clock": "2023-06-25 20:00:00.000", "clock": "2023-07-05 14:29:40.122",
"status": "ok", "status": "ok",
"data": {} "data": {
"info": {
"materialCode": "CELL002",
"materialTypeCode": "CELL",
"materialTypeDesc": "电池片",
"descriptions": "电池片描述",
"createTime": "2023-07-05 14:29:40.008",
"attrs": [
{
"materialCode": "CELL002",
"materialTypeCode": "CELL",
"materialTypeDesc": "电池片",
"attrCode": "cell_uop",
"attrName": "单片功率",
"attrValue": "7.82",
"attrValueCode": "7.82"
},
{
"materialCode": "CELL002",
"materialTypeCode": "CELL",
"materialTypeDesc": "电池片",
"attrCode": "crys_type",
"attrName": "晶体结构",
"attrValue": "单晶",
"attrValueCode": "单晶"
}
]
}
}
} }
``` ```

Loading…
Cancel
Save