|
|
|
@ -49,13 +49,13 @@ def sign_failed_notify(user_obj, developer_obj, app_obj): |
|
|
|
|
now_time = get_format_time().replace('_', ' ') |
|
|
|
|
|
|
|
|
|
msg = Config.MSG_ERROR_DEVELOPER % ( |
|
|
|
|
developer_obj.user_id.first_name, app_obj.name, |
|
|
|
|
now_time, developer_obj.issuer_id) |
|
|
|
|
user_obj.first_name, app_obj.name, now_time, developer_obj.issuer_id, developer_obj.description) |
|
|
|
|
|
|
|
|
|
for wx_user_obj in get_notify_wx_queryset(user_obj, message_type): |
|
|
|
|
res = WxTemplateMsg(wx_user_obj.openid, wx_user_obj.nickname).operate_failed_msg( |
|
|
|
|
user_obj.first_name, f'应用 {app_obj.name} 签名失败了', |
|
|
|
|
f'开发者{developer_obj.issuer_id} 状态 {developer_obj.get_status_dispaly()}', now_time, '请登录后台查看具体信息') |
|
|
|
|
f'开发者{developer_obj.issuer_id} 状态 {developer_obj.get_status_dispaly()}', now_time, |
|
|
|
|
f'开发者备注:{developer_obj.description},请登录后台查看具体信息') |
|
|
|
|
logger.info(f'user_obj {user_obj} weixin notify pay success result: {res}') |
|
|
|
|
|
|
|
|
|
notify_by_email(user_obj, message_type, msg) |
|
|
|
@ -76,3 +76,23 @@ def sign_unavailable_developer(user_obj, app_obj): |
|
|
|
|
logger.info(f'user_obj {user_obj} weixin notify pay success result: {res}') |
|
|
|
|
|
|
|
|
|
notify_by_email(user_obj, message_type, msg) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def sign_app_over_limit(user_obj, app_obj, used_num, limit_number): |
|
|
|
|
""" |
|
|
|
|
0, '签名余额不足' |
|
|
|
|
:param limit_number: |
|
|
|
|
:param used_num: |
|
|
|
|
:param app_obj: |
|
|
|
|
:param user_obj: |
|
|
|
|
:return: |
|
|
|
|
""" |
|
|
|
|
message_type = 2 |
|
|
|
|
now_time = get_format_time().replace('_', ' ') |
|
|
|
|
msg = Config.MSG_SING_APP_OVER_LIMIT % (user_obj.first_name, app_obj.name, now_time, used_num, limit_number) |
|
|
|
|
for wx_user_obj in get_notify_wx_queryset(user_obj, message_type): |
|
|
|
|
res = WxTemplateMsg(wx_user_obj.openid, wx_user_obj.nickname).operate_failed_msg( |
|
|
|
|
user_obj.first_name, f'应用 {app_obj.name} 签名失败了', f'超过该应用的签名限额 {limit_number}', now_time, |
|
|
|
|
f'该应用已经使用设备数 {used_num},已超过您设置该应用的签名限额 {limit_number},当前已经无法安装新设备,为了避免业务使用,您可以修改该应用签名限额') |
|
|
|
|
logger.info(f'user_obj {user_obj} sign devices not enough result: {res}') |
|
|
|
|
notify_by_email(user_obj, message_type, msg) |
|
|
|
|