|
@@ -13,17 +13,12 @@ class ResponseObject(object):
|
|
|
def data(self, code, res={}):
|
|
|
data_en = {
|
|
|
0: 'Success',
|
|
|
- 4: 'Operation failed',
|
|
|
5: 'Please try again one minute later!',
|
|
|
- 9: 'User accounts is not exist',
|
|
|
10: res,
|
|
|
12: 'You are not the primary user of the device!',
|
|
|
- 13: 'Device is not exist !',
|
|
|
14: 'Device is not belong to you',
|
|
|
- 15: 'Not own service',
|
|
|
44: 'System error! Can not send email',
|
|
|
48: 'System object error!',
|
|
|
- 60: 'The app info has already exist',
|
|
|
89: 'Already send the code, please check it or get it again after 10m',
|
|
|
90: 'please check code or get it again after 5m',
|
|
|
100: 'Phone format error!',
|
|
@@ -32,51 +27,27 @@ class ResponseObject(object):
|
|
|
103: 'Mail already existed!',
|
|
|
104: 'Account doesn\'t exist!',
|
|
|
105: 'Email format error!',
|
|
|
- 106: 'Create User Error',
|
|
|
107: 'The username not conform to the rules!',
|
|
|
108: 'Email format error!',
|
|
|
109: 'The password not conform to the rules!',
|
|
|
- 110: 'user is not activated',
|
|
|
+ 110: 'user doesn\'t activated',
|
|
|
111: 'Error password',
|
|
|
- 112: 'update password error!',
|
|
|
- 114: 'Delete user failure error',
|
|
|
- 118: 'You do not enter the password two times!',
|
|
|
120: 'The code has expired',
|
|
|
121: 'The verification code is wrong!',
|
|
|
- 150: 'Wrong superID is None or userID',
|
|
|
- 160: 'The All Equipment has been shared by the User!',
|
|
|
- 171: 'Delete Equipment sharing failed',
|
|
|
- 172: 'There is no Equipment for this User!',
|
|
|
- 173: 'The UID does not exist!',
|
|
|
- 174: 'The user equipment has already existed!',
|
|
|
- 175: 'The user equipment has already binding!',
|
|
|
- 176: 'Delete equipment error',
|
|
|
- 177: 'Update equipment error',
|
|
|
- 178: 'ADD equipment error',
|
|
|
- 179: 'Device nickname cannot be repeated',
|
|
|
- 180: 'UID specification error',
|
|
|
- 190: 'The rid does not exist!',
|
|
|
- 191: 'The roleName does not exist!',
|
|
|
- 192: 'Delete role error',
|
|
|
- 193: 'role can not be deleted!',
|
|
|
- 194: 'Update role error',
|
|
|
- 195: 'role can not be updated!',
|
|
|
+ 173: 'Data does not exists!',
|
|
|
+ 174: 'Data already exists!',
|
|
|
+ 176: 'Delete error',
|
|
|
+ 177: 'Update error',
|
|
|
+ 178: 'ADD error',
|
|
|
+ 179: 'Nickname repeated',
|
|
|
306: 'The link has expired!',
|
|
|
309: 'Please ReLogin! errmsg token',
|
|
|
- 403: 'API ERROR!',
|
|
|
404: 'You don not have permission to access this!',
|
|
|
414: 'Please confirm the request url!',
|
|
|
424: 'Database Error !',
|
|
|
444: 'Wrong parameters!',
|
|
|
474: 'System Maintaining!',
|
|
|
500: 'Query Database Error:',
|
|
|
- 501: 'Update database error!',
|
|
|
- 606: 'User has not assigned role!',
|
|
|
- 807: 'The role has already existed!',
|
|
|
- 808: 'Add a new role to the wrong',
|
|
|
- 816: 'Add a new permissions error',
|
|
|
- 817: 'The permissions do not exist!',
|
|
|
- 818: 'Delete permission failed',
|
|
|
700: 'Upload file error',
|
|
|
701: 'The file does not exist!',
|
|
|
900: 'There is no information about this version!',
|
|
@@ -88,17 +59,12 @@ class ResponseObject(object):
|
|
|
}
|
|
|
data_cn = {
|
|
|
0: '成功',
|
|
|
- 4: '操作失败',
|
|
|
5: '请一分钟后再尝试',
|
|
|
- 9: '用户账号不存在',
|
|
|
10: res,
|
|
|
12: '您不是设备主用户',
|
|
|
- 13: '设备不存在',
|
|
|
14: '设备不属于您',
|
|
|
- 15: '您尚未打开此服务',
|
|
|
44: '系统错误!无法发送电子邮件',
|
|
|
48: '系统对象错误',
|
|
|
- 60: 'APP信息已经存在',
|
|
|
89: '已发验证码,请检测或10分钟后重新获取。',
|
|
|
90: '请检测或5分钟后重新获取。',
|
|
|
100: '手机格式错误!',
|
|
@@ -107,52 +73,27 @@ class ResponseObject(object):
|
|
|
103: '邮箱已存在!',
|
|
|
104: '账户不存在!',
|
|
|
105: '邮箱格式错误!',
|
|
|
- 106: '创建用户错误',
|
|
|
107: '用户名格式不符合!',
|
|
|
108: '邮箱格式错误!',
|
|
|
109: '密码格式不符合!',
|
|
|
110: '用户未激活!',
|
|
|
- 111: '您输入的密码不正确!',
|
|
|
- 112: '未知错误不能更新密码!',
|
|
|
- 114: '删除用户失败错误',
|
|
|
- 118: '你不输入密码两次!',
|
|
|
+ 111: '密码不正确!',
|
|
|
120: '验证码过期',
|
|
|
121: '验证码错了!',
|
|
|
- 150: '超级用户或用户id错误',
|
|
|
- 160: '所有设备已被用户共享!',
|
|
|
- 171: '删除设备共享失败',
|
|
|
- 172: '这个用户没有设备!',
|
|
|
- 173: '设备UID不存在!',
|
|
|
- 174: '用户设备已经存在!',
|
|
|
- 175: '用户设备已经绑定了!',
|
|
|
- 176: '删除设备错误',
|
|
|
- 177: '更新设备错误',
|
|
|
- 178: '添加设备错误',
|
|
|
- 179: '设备名称不能重复',
|
|
|
- 180: 'UID规格错误',
|
|
|
- 190: '角色rid不存在!',
|
|
|
- 191: '角色名不存在!',
|
|
|
- 192: '删除角色错误',
|
|
|
- 193: '未知的错误导致角色不能被删除!',
|
|
|
- 194: '更新角色错误',
|
|
|
- 195: '未知的错误导致角色无法更新!',
|
|
|
+ 173: '数据不存在!',
|
|
|
+ 174: '数据已存在!',
|
|
|
+ 176: '删除错误',
|
|
|
+ 177: '更新错误',
|
|
|
+ 178: '增加错误',
|
|
|
+ 179: '名称不能重复',
|
|
|
306: '链接已超过有效期!',
|
|
|
309: '请重新登录!',
|
|
|
- 403: 'API错误!',
|
|
|
404: '您没有访问的权限!',
|
|
|
414: '请确认请求url!',
|
|
|
424: '数据库错误!',
|
|
|
444: '参数错误!',
|
|
|
474: '系统维护中!',
|
|
|
500: '查询数据库错误!',
|
|
|
- 501: '更新数据库错误!',
|
|
|
- 606: '用户没有分配角色!',
|
|
|
- 616: '用户帐户不存在!',
|
|
|
- 807: '角色已经存在!',
|
|
|
- 808: '添加新角色错误',
|
|
|
- 816: '新增权限错误',
|
|
|
- 817: '权限不存在',
|
|
|
- 818: '删除权限错误',
|
|
|
700: '上传文件错误',
|
|
|
701: '文件不存在',
|
|
|
900: '版本信息不存在',
|