摘要: 1.通过模块netifaces获取,当系统为Windows时,可能会有报错现象 import os import sys try: import netifaces except ImportError: try: command_to_execute = "pip install netiface 阅读全文
posted @ 2020-01-03 20:13 LiangShaoY 阅读(2048) 评论(0) 推荐(0) 编辑
摘要: 1. 很多人还是习惯使用restful格式进行接口操作,但odoo已默认jsonrpc,所以需要专门写一个装饰器 def json_response(func): """返回去除封装的JSON""" @wraps(func) def decorate(*args, **kwargs): reques 阅读全文
posted @ 2020-01-03 18:13 LiangShaoY 阅读(1391) 评论(2) 推荐(0) 编辑