chengc 4 ngày trước cách đây
mục cha
commit
694861a456

+ 276 - 0
collections/api-auto-test.json

@@ -0,0 +1,276 @@
+{
+	"info": {
+		"_postman_id": "5b90b987-503f-484c-b8d7-a0974674e95d",
+		"name": "api-auto-test",
+		"description": "Auto API test for Jenkins",
+		"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
+		"_exporter_id": "3170378"
+	},
+	"item": [
+		{
+			"name": "登录",
+			"item": [
+				{
+					"name": "登录",
+					"event": [
+						{
+							"listen": "test",
+							"script": {
+								"exec": [
+									"var result = pm.response.json();",
+									"pm.environment.set(\"api-login-id\", result.LoginId);"
+								],
+								"type": "text/javascript",
+								"packages": {},
+								"requests": {}
+							}
+						}
+					],
+					"request": {
+						"auth": {
+							"type": "noauth"
+						},
+						"method": "POST",
+						"header": [
+							{
+								"key": "LanguageId",
+								"value": "{{api-language}}",
+								"description": "客户端语言别,0:简体  1:繁体  2:英文"
+							},
+							{
+								"key": "Authorization",
+								"value": "{{api-authorization}}",
+								"description": "\"Basic MTBYWF8wMTo=\" 为\"10XX_01:\"的BASE64加密字符串,如在POSTMAN中的Authorization部分选择Basic Auth填入用户名+密码则不需在此传值"
+							},
+							{
+								"key": "ClientType",
+								"value": "{{api-client-type}}",
+								"description": "用户自定义的客户端识别号,比如客户是WMS系统,可以自定义ClientType=“WMS”"
+							},
+							{
+								"key": "Content-Type",
+								"value": "{{api-content-type}}"
+							},
+							{
+								"key": "X-Tiansi-Auth-Bypass",
+								"value": "{{api-x-tiansi-bypass}}",
+								"description": "跳过接口注册检验",
+								"type": "text"
+							},
+							{
+								"key": "sn",
+								"value": "{{api-sn}}",
+								"type": "text"
+							}
+						],
+						"url": {
+							"raw": "{{api-url}}/User/login",
+							"host": [
+								"{{api-url}}"
+							],
+							"path": [
+								"User",
+								"login"
+							]
+						},
+						"description": "用户登录"
+					},
+					"response": []
+				}
+			],
+			"description": "登录"
+		},
+		{
+			"name": "货品资料",
+			"item": [
+				{
+					"name": "新增货品",
+					"request": {
+						"method": "POST",
+						"header": [
+							{
+								"key": "LoginId",
+								"value": "{{api-login-id}}",
+								"type": "text"
+							},
+							{
+								"key": "sn",
+								"value": "{{api-sn}}",
+								"type": "text"
+							}
+						],
+						"body": {
+							"mode": "raw",
+							"raw": "[\r\n    {\r\n        \"PRD_NO\": \"HP00001\", // 必须,货品代号,该货品代号在资料中存在即为修改原数据,不存在为新增\r\n        \"NAME\": \"货品HP00001\", // 必须,货品名称\r\n        \"UT\": \"KG\", // 必须,主单位\r\n        \"SNM\": \"HP00001\", // 非必须,简称\r\n        \"REM\": \"货品HP00001摘要,API测试\" // 非必须,摘要\r\n    }\r\n]",
+							"options": {
+								"raw": {
+									"language": "json"
+								}
+							}
+						},
+						"url": {
+							"raw": "{{api-url}}/Prdt/AppendToPrdt",
+							"host": [
+								"{{api-url}}"
+							],
+							"path": [
+								"Prdt",
+								"AppendToPrdt"
+							]
+						},
+						"description": "新增货品"
+					},
+					"response": []
+				},
+				{
+					"name": "删除货品",
+					"request": {
+						"method": "POST",
+						"header": [
+							{
+								"key": "LoginId",
+								"value": "{{api-login-id}}",
+								"type": "text"
+							},
+							{
+								"key": "sn",
+								"value": "{{api-sn}}",
+								"type": "text"
+							}
+						],
+						"body": {
+							"mode": "raw",
+							"raw": "[\r\n    {\r\n        \"PRD_NO\": \"HP00001\" // 必须,货品代号,删除该笔货品资料\r\n    }\r\n]",
+							"options": {
+								"raw": {
+									"language": "json"
+								}
+							}
+						},
+						"url": {
+							"raw": "{{api-url}}/Prdt/DeleteForPrdt",
+							"host": [
+								"{{api-url}}"
+							],
+							"path": [
+								"Prdt",
+								"DeleteForPrdt"
+							]
+						},
+						"description": "删除货品资料"
+					},
+					"response": []
+				}
+			],
+			"description": "货品资料"
+		},
+		{
+			"name": "客户厂商资料",
+			"item": [
+				{
+					"name": "新增客户厂商",
+					"request": {
+						"method": "POST",
+						"header": [
+							{
+								"key": "LoginId",
+								"value": "{{api-login-id}}",
+								"type": "text"
+							},
+							{
+								"key": "sn",
+								"value": "{{api-sn}}",
+								"type": "text"
+							}
+						],
+						"body": {
+							"mode": "raw",
+							"raw": "[\r\n    {\r\n        \"CUS_NO\": \"KH00001\", // 必须,客户厂商代号,该客户厂商代号在资料中存在即为修改原数据,不存在为新增\r\n        \"OBJ_ID\": \"1\", // 必须,对象别,1:客户,2:厂商,3 :客户厂商;为空时默认取3\r\n        \"NAME\": \"客户00001\", // 必须,全称\r\n        \"SNM\": \"KH00001\", // 非必须,简称\r\n        \"REM\": \"这是客户00001备注\" // 非必须,备注\r\n    }\r\n]",
+							"options": {
+								"raw": {
+									"language": "json"
+								}
+							}
+						},
+						"url": {
+							"raw": "{{api-url}}/Cust/AppendToCust",
+							"host": [
+								"{{api-url}}"
+							],
+							"path": [
+								"Cust",
+								"AppendToCust"
+							]
+						},
+						"description": "新增客户厂商资料"
+					},
+					"response": []
+				},
+				{
+					"name": "删除客户厂商资料",
+					"request": {
+						"method": "POST",
+						"header": [
+							{
+								"key": "LoginId",
+								"value": "{{api-login-id}}",
+								"type": "text"
+							},
+							{
+								"key": "sn",
+								"value": "{{api-sn}}",
+								"type": "text"
+							}
+						],
+						"body": {
+							"mode": "raw",
+							"raw": "[\r\n    {\r\n        \"CUS_NO\": \"KH00001\" // 必须,客户厂商代号,删除该笔客户厂商资料\r\n    }\r\n]",
+							"options": {
+								"raw": {
+									"language": "json"
+								}
+							}
+						},
+						"url": {
+							"raw": "{{api-url}}/Cust/DeleteForCust",
+							"host": [
+								"{{api-url}}"
+							],
+							"path": [
+								"Cust",
+								"DeleteForCust"
+							]
+						},
+						"description": "删除客户厂商资料"
+					},
+					"response": []
+				}
+			],
+			"description": "客户/厂商资料"
+		}
+	],
+	"event": [
+		{
+			"listen": "prerequest",
+			"script": {
+				"type": "text/javascript",
+				"packages": {},
+				"requests": {},
+				"exec": [
+					""
+				]
+			}
+		},
+		{
+			"listen": "test",
+			"script": {
+				"type": "text/javascript",
+				"packages": {},
+				"requests": {},
+				"exec": [
+					""
+				]
+			}
+		}
+	]
+}

+ 0 - 180
collections/api-tests-basic.json

@@ -1,180 +0,0 @@
-{
-	"info": {
-		"_postman_id": "5b90b987-503f-484c-b8d7-a0974674e95d",
-		"name": "api-tests-basic",
-		"description": "Auto test for Jenkins",
-		"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
-		"_exporter_id": "3170378"
-	},
-	"item": [
-		{
-			"name": "登录",
-			"event": [
-				{
-					"listen": "test",
-					"script": {
-						"exec": [
-							"var result = pm.response.json();",
-							"pm.environment.set(\"api-login-id\", result.LoginId);"
-						],
-						"type": "text/javascript",
-						"packages": {},
-						"requests": {}
-					}
-				}
-			],
-			"request": {
-				"auth": {
-					"type": "noauth"
-				},
-				"method": "POST",
-				"header": [
-					{
-						"key": "LanguageId",
-						"value": "{{api-language}}",
-						"description": "客户端语言别,0:简体  1:繁体  2:英文"
-					},
-					{
-						"key": "Authorization",
-						"value": "{{api-authorization}}",
-						"description": "\"Basic MTBYWF8wMTo=\" 为\"10XX_01:\"的BASE64加密字符串,如在POSTMAN中的Authorization部分选择Basic Auth填入用户名+密码则不需在此传值"
-					},
-					{
-						"key": "ClientType",
-						"value": "{{api-client-type}}",
-						"description": "用户自定义的客户端识别号,比如客户是WMS系统,可以自定义ClientType=“WMS”"
-					},
-					{
-						"key": "Content-Type",
-						"value": "{{api-content-type}}"
-					},
-					{
-						"key": "X-Tiansi-Auth-Bypass",
-						"value": "{{api-x-tiansi-bypass}}",
-						"description": "跳过接口注册检验",
-						"type": "text"
-					},
-					{
-						"key": "sn",
-						"value": "{{api-sn}}",
-						"type": "text"
-					}
-				],
-				"url": {
-					"raw": "{{api-url}}/User/login",
-					"host": [
-						"{{api-url}}"
-					],
-					"path": [
-						"User",
-						"login"
-					]
-				},
-				"description": "用户登录"
-			},
-			"response": []
-		},
-		{
-			"name": "新增货品",
-			"request": {
-				"method": "POST",
-				"header": [
-					{
-						"key": "LoginId",
-						"value": "{{api-login-id}}",
-						"type": "text"
-					},
-					{
-						"key": "sn",
-						"value": "{{api-sn}}",
-						"type": "text"
-					}
-				],
-				"body": {
-					"mode": "raw",
-					"raw": "[\r\n    {\r\n        \"PRD_NO\": \"HP00001\", // 必须,货品代号,该货品代号在资料中存在即为修改原数据,不存在为新增\r\n        \"NAME\": \"货品HP00001\", // 必须,货品名称\r\n        \"UT\": \"KG\", // 必须,主单位\r\n        \"SNM\": \"HP00001\", // 非必须,简称\r\n        \"REM\": \"货品HP00001摘要,API测试\" // 非必须,摘要\r\n    }\r\n]",
-					"options": {
-						"raw": {
-							"language": "json"
-						}
-					}
-				},
-				"url": {
-					"raw": "{{api-url}}/Prdt/AppendToPrdt",
-					"host": [
-						"{{api-url}}"
-					],
-					"path": [
-						"Prdt",
-						"AppendToPrdt"
-					]
-				},
-				"description": "新增货品"
-			},
-			"response": []
-		},
-		{
-			"name": "删除货品",
-			"request": {
-				"method": "POST",
-				"header": [
-					{
-						"key": "LoginId",
-						"value": "{{api-login-id}}",
-						"type": "text"
-					},
-					{
-						"key": "sn",
-						"value": "{{api-sn}}",
-						"type": "text"
-					}
-				],
-				"body": {
-					"mode": "raw",
-					"raw": "[\r\n    {\r\n        \"PRD_NO\": \"HP00001\" // 必须,货品代号,删除该笔货品资料\r\n    }\r\n]",
-					"options": {
-						"raw": {
-							"language": "json"
-						}
-					}
-				},
-				"url": {
-					"raw": "{{api-url}}/Prdt/DeleteForPrdt",
-					"host": [
-						"{{api-url}}"
-					],
-					"path": [
-						"Prdt",
-						"DeleteForPrdt"
-					]
-				},
-				"description": "删除货品"
-			},
-			"response": []
-		}
-	],
-	"event": [
-		{
-			"listen": "prerequest",
-			"script": {
-				"type": "text/javascript",
-				"packages": {},
-				"requests": {},
-				"exec": [
-					""
-				]
-			}
-		},
-		{
-			"listen": "test",
-			"script": {
-				"type": "text/javascript",
-				"packages": {},
-				"requests": {},
-				"exec": [
-					""
-				]
-			}
-		}
-	]
-}

+ 0 - 180
collections/api-tests-business.json

@@ -1,180 +0,0 @@
-{
-	"info": {
-		"_postman_id": "e7a3950b-03eb-46e8-ba46-394801b15ea1",
-		"name": "api-tests-business",
-		"description": "Auto test for Jenkins",
-		"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
-		"_exporter_id": "3170378"
-	},
-	"item": [
-		{
-			"name": "登录",
-			"event": [
-				{
-					"listen": "test",
-					"script": {
-						"exec": [
-							"var result = pm.response.json();",
-							"pm.environment.set(\"api-login-id\", result.LoginId);"
-						],
-						"type": "text/javascript",
-						"packages": {},
-						"requests": {}
-					}
-				}
-			],
-			"request": {
-				"auth": {
-					"type": "noauth"
-				},
-				"method": "POST",
-				"header": [
-					{
-						"key": "LanguageId",
-						"value": "{{api-language}}",
-						"description": "客户端语言别,0:简体  1:繁体  2:英文"
-					},
-					{
-						"key": "Authorization",
-						"value": "{{api-authorization}}",
-						"description": "\"Basic MTBYWF8wMTo=\" 为\"10XX_01:\"的BASE64加密字符串,如在POSTMAN中的Authorization部分选择Basic Auth填入用户名+密码则不需在此传值"
-					},
-					{
-						"key": "ClientType",
-						"value": "{{api-client-type}}",
-						"description": "用户自定义的客户端识别号,比如客户是WMS系统,可以自定义ClientType=“WMS”"
-					},
-					{
-						"key": "Content-Type",
-						"value": "{{api-content-type}}"
-					},
-					{
-						"key": "X-Tiansi-Auth-Bypass",
-						"value": "{{api-x-tiansi-bypass}}",
-						"description": "跳过接口注册检验",
-						"type": "text"
-					},
-					{
-						"key": "sn",
-						"value": "{{api-sn}}",
-						"type": "text"
-					}
-				],
-				"url": {
-					"raw": "{{api-url}}/User/login",
-					"host": [
-						"{{api-url}}"
-					],
-					"path": [
-						"User",
-						"login"
-					]
-				},
-				"description": "用户登录"
-			},
-			"response": []
-		},
-		{
-			"name": "新增客户厂商",
-			"request": {
-				"method": "POST",
-				"header": [
-					{
-						"key": "LoginId",
-						"value": "{{api-login-id}}",
-						"type": "text"
-					},
-					{
-						"key": "sn",
-						"value": "{{api-sn}}",
-						"type": "text"
-					}
-				],
-				"body": {
-					"mode": "raw",
-					"raw": "[\r\n    {\r\n        \"CUS_NO\": \"KH00001\", // 必须,客户厂商代号,该客户厂商代号在资料中存在即为修改原数据,不存在为新增\r\n        \"OBJ_ID\": \"1\", // 必须,对象别,1:客户,2:厂商,3 :客户厂商;为空时默认取3\r\n        \"NAME\": \"客户00001\", // 必须,全称\r\n        \"SNM\": \"KH00001\", // 非必须,简称\r\n        \"REM\": \"客户00001备注\" // 非必须,备注\r\n    }\r\n]",
-					"options": {
-						"raw": {
-							"language": "json"
-						}
-					}
-				},
-				"url": {
-					"raw": "{{api-url}}/Cust/AppendToCust",
-					"host": [
-						"{{api-url}}"
-					],
-					"path": [
-						"Cust",
-						"AppendToCust"
-					]
-				},
-				"description": "新增客户厂商"
-			},
-			"response": []
-		},
-		{
-			"name": "删除客户厂商",
-			"request": {
-				"method": "POST",
-				"header": [
-					{
-						"key": "LoginId",
-						"value": "{{api-login-id}}",
-						"type": "text"
-					},
-					{
-						"key": "sn",
-						"value": "{{api-sn}}",
-						"type": "text"
-					}
-				],
-				"body": {
-					"mode": "raw",
-					"raw": "[\r\n    {\r\n        \"CUS_NO\": \"KH00001\" // 必须,客户厂商代号,删除该笔客户厂商资料\r\n    }\r\n]",
-					"options": {
-						"raw": {
-							"language": "json"
-						}
-					}
-				},
-				"url": {
-					"raw": "{{api-url}}/Cust/DeleteForCust",
-					"host": [
-						"{{api-url}}"
-					],
-					"path": [
-						"Cust",
-						"DeleteForCust"
-					]
-				},
-				"description": "删除客户厂商"
-			},
-			"response": []
-		}
-	],
-	"event": [
-		{
-			"listen": "prerequest",
-			"script": {
-				"type": "text/javascript",
-				"packages": {},
-				"requests": {},
-				"exec": [
-					""
-				]
-			}
-		},
-		{
-			"listen": "test",
-			"script": {
-				"type": "text/javascript",
-				"packages": {},
-				"requests": {},
-				"exec": [
-					""
-				]
-			}
-		}
-	]
-}