-
Notifications
You must be signed in to change notification settings - Fork 44
/
Fuct_Account.py
42 lines (32 loc) · 929 Bytes
/
Fuct_Account.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# -*- coding: utf-8 -*-
import Fuct_Http
import Fuct_Json
"""
账户相关
"""
# 链接
host = "http://127.0.0.1/"
host = "http://qtrader.duapp.com/"
login_url = host+"login/"
checkLogin_url = host+"checkLogin/"
register_url = host+"register/"
get_test = host+"get/"
# 登录
def Login(event):
event = Fuct_Json.Encode(event)
return Fuct_Http.request_post(login_url, event)
# 登出
def Logout(event):
return Fuct_Http.request_post(register_url, event)
# 账户注册
def Register(event):
event = Fuct_Json.Encode(event)
return Fuct_Http.request_post(register_url, event)
# 检查单点登录
def CheckLogin(event):
return Fuct_Http.request_post(register_url, event)
# 测试
def get(event):
return Fuct_Http.request_post(get_test, event)
if __name__ == '__main__':
print( "Register:", Register({"userName":"KingMagic2","passWord":"Huawei@123","phone":"17358536853","qq":"542601619"}))