-
Notifications
You must be signed in to change notification settings - Fork 170
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
17 changed files
with
350 additions
and
238 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
__author__ = 'Administrator' | ||
# 参数化请求 | ||
def str__post_param(list_param): | ||
result = {} | ||
for i in list_param: | ||
result[i["name"]] = i["value"] | ||
return result | ||
|
||
def str_get_param(list_param, param): | ||
result = "?" | ||
result += list_param["name"] + "=" + list_param["value"] + "&" | ||
return str_sub(0, len(result)-1, result) + "&" + for_dict(param) | ||
|
||
def for_dict(d): | ||
result = "" | ||
for (k, v) in d.items(): | ||
result += str(k) + "=" + str(v) | ||
return result | ||
|
||
def str_sub(start, end, str): | ||
return str[start:end] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ | |
to_addr = ["[email protected]", "[email protected]"] | ||
mail_host = smtp.qq.com | ||
mail_user = [email protected] | ||
mail_pass = tagdcyaqvbkqbjff | ||
mail_pass = 1111 | ||
port = 465 | ||
headerMsg = 接口测试 | ||
attach = 接口测试 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<root> | ||
<title>导购码接口测试</title> | ||
<host>dgm.boweixin.com</host> | ||
<port>80</port> | ||
<No>[]</No> | ||
<InterfaceList> | ||
<params> | ||
<name type="str">account</name> | ||
<value>18576759587</value> | ||
<must>1</must> | ||
</params> | ||
<params> | ||
<name type="str">password</name> | ||
<value>222222</value> | ||
<must>1</must> | ||
</params> | ||
<params> | ||
<name type="str">type</name> | ||
<value>0</value> | ||
<must>1</must> | ||
</params> | ||
<isList>0</isList> | ||
<id>1001</id> | ||
<name>登陆</name> | ||
<method>POST</method> | ||
<url>Login</url> | ||
<hope>{"appStatus":{"errorCode":0,"message":"操作成功"},"content":[{"user_sex":0,"fk_user_city":440300,"user_id":30,"nickname":"18576759587","user_phone":"18576759587","head_picture":"http:\/\/dgm.boweixin.com\/","has_finance":1,"user_state":1}]}</hope> | ||
<login>user_id</login> | ||
<isList>0</isList> | ||
</InterfaceList> | ||
<InterfaceList> | ||
<params> | ||
<name type="int">lookerId</name> | ||
<value>2</value> | ||
<must>1</must> | ||
</params> | ||
<id>1002</id> | ||
<name>个人主页</name> | ||
<method>GET</method> | ||
<url>GetPersonalHomePage</url> | ||
<hope>{"appStatus":{"errorCode":0,"message":"操作成功"},"content":[{"business_name":"坤达点子","notice_img":"\/product\/20160718184134_321.jpg","user_type":1,"user_id":2,"goods":[{"good_price":45211.0,"good_id":12,"good_name":"艾欧","banner_picture1":"\/product\/20160719165135_8977.png"},{"good_price":199.0,"good_id":14,"good_name":"麒麟瓜1","banner_picture1":"\/product\/20160720102028_5352.jpg"},{"good_price":452.0,"good_id":6,"good_name":"实力产品","banner_picture1":"\/product\/20160718165448_2602.png"},{"good_price":99898.0,"good_id":11,"good_name":"越南芒果","banner_picture1":"\/product\/20160720100057_5877.jpg"}],"shop_img":"\/product\/20160718120144_3196.jpg","head_picture":"http:\/\/dgm.boweixin.com\/\/product\/20160718134528_4744.jpg","notice_id":1}]}</hope> | ||
<login>1</login> | ||
<isList>1</isList> | ||
|
||
</InterfaceList> | ||
</root> |