|
@@ -116,13 +116,13 @@ class NotificationView(View):
|
|
push_type = ua['push_type']
|
|
push_type = ua['push_type']
|
|
# ios apns
|
|
# ios apns
|
|
if push_type == 0:
|
|
if push_type == 0:
|
|
- return self.do_apns(request_dict, ua, response)
|
|
|
|
|
|
+ self.do_apns(request_dict, ua, response)
|
|
# android gcm
|
|
# android gcm
|
|
elif push_type == 1:
|
|
elif push_type == 1:
|
|
- return self.do_gmc(request_dict, ua, response)
|
|
|
|
|
|
+ self.do_gmc(request_dict, ua, response)
|
|
# android jpush
|
|
# android jpush
|
|
elif push_type == 2:
|
|
elif push_type == 2:
|
|
- return self.do_jpush(request_dict, ua, response)
|
|
|
|
|
|
+ self.do_jpush(request_dict, ua, response)
|
|
return response.json(0)
|
|
return response.json(0)
|
|
|
|
|
|
else:
|
|
else:
|
|
@@ -229,7 +229,7 @@ class NotificationView(View):
|
|
appBundleId = uaql['appBundleId']
|
|
appBundleId = uaql['appBundleId']
|
|
uid = uaql['uid']
|
|
uid = uaql['uid']
|
|
apns_config = {
|
|
apns_config = {
|
|
- 'appbundleId': {'pem_path': 'xxxx', 'topic': 'topic','password':'password'}
|
|
|
|
|
|
+ 'appbundleId': {'pem_path': 'xxxx', 'topic': 'topic', 'password': 'password'}
|
|
}
|
|
}
|
|
try:
|
|
try:
|
|
# daytime = time.strftime("%Y%m%d%H%M", time.localtime(1547256103))
|
|
# daytime = time.strftime("%Y%m%d%H%M", time.localtime(1547256103))
|