Commit 3ff2934f authored by fendouai's avatar fendouai

add alert_type

parent 7c7a5fe3
......@@ -10,7 +10,7 @@ push.audience = jpush.all_
push.platform = jpush.all_
ios = jpush.ios(alert="Hello, IOS JPush!", sound="a.caf", extras={'k1':'v1'})
android = jpush.android(alert="Hello, Android msg", priority=1, style=1, big_text='jjjjjjjjjj', extras={'k1':'v1'})
android = jpush.android(alert="Hello, Android msg", priority=1, style=1, alert_type=1,big_text='jjjjjjjjjj', extras={'k1':'v1'})
push.notification = jpush.notification(alert="Hello, JPush!", android=android, ios=ios)
......
......@@ -71,7 +71,7 @@ __all__ = [
schedulepayload,
]
__version__ = '3.2.4'
__version__ = '3.2.5'
VERSION = tuple(map(int, __version__.split('.')))
# Silence urllib3 INFO logging by default
......
......@@ -77,7 +77,7 @@ def ios(alert=None, badge='+1', sound=None, content_available=False,
return payload
def android(alert, title=None, builder_id=None, extras=None,
priority=None, category=None, style=None, big_text=None, inbox=None, big_pic_path=None):
priority=None, category=None, style=None, alert_type=None,big_text=None, inbox=None, big_pic_path=None):
"""Android specific platform override payload.
:keyword alert: String alert text.If you set alert to a empty string,then the payload
......@@ -102,6 +102,8 @@ def android(alert, title=None, builder_id=None, extras=None,
payload['category'] = category
if style is not None:
payload['style'] = style
if alert_type is not None:
payload['alert_type'] = alert_type
if big_text is not None:
payload['big_text'] = big_text
if inbox is not None:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment