示例#1
0
文件: views.py 项目: land-pack/hokey
def get_ter_attr(terminal_request):
    msg_content = ''  # Empty message content for checking terminal attribute
    template = 'get_ter_attr|sys_fixed_msg_attr2|client_dev_id|sys_product|'
    if 'GET' in terminal_request:
        # return SplitInstance.result ...
        return redirect(url_for('0x0200'), )
    return render(terminal_request, template)
示例#2
0
文件: views.py 项目: land-pack/hokey
def register(terminal_request):
    """
    :param terminal_request: original data format to Dicts from terminal!
    :return: a render which a tuple factory
    you should know what you are doing and which field you need!
    """
    template = 'message_id|message_attr|device_id|message_product|content'
    return render(terminal_request, template)
示例#3
0
文件: views.py 项目: land-pack/hokey
def get_ter_info(terminal_request):
    template = 'get_ter_info|sys_fixed_msg_attr2|client_dev_id|sys_product|'
    print 'terminal_request', terminal_request
    return render(terminal_request, template)
示例#4
0
文件: views.py 项目: land-pack/hokey
def auth(terminal_request):
    msg_content = 'message_product|message_id|sys_ok'
    template = '0x8001|sys_fixed_msg_attr|device_id|sys_product|' + msg_content
    # template = '0x8001|auto_message_attr|device_id|auto_product|'
    return render(terminal_request, template)