示例#1
0
def registerdevice():
    if request.method == 'GET':
        return Codes.invalidrequest()
    if request.method == 'POST':
        return db.registerDevice(request.get_json())
示例#2
0
def addmoney():
    if request.method == 'GET':
        return Codes.invalidrequest()
    if request.method == 'POST':
        return db.addMoney(request.get_json())
示例#3
0
def getdevicedata():
    if request.method == 'GET':
        return Codes.invalidrequest()
    if request.method == 'POST':
        return db.getDeviceData(request.get_json())
示例#4
0
def login():
    if request.method == 'GET':
        return Codes.invalidrequest()
    if request.method == 'POST':
        return db.loginuser(request.get_json())