android增加本地通知

This commit is contained in:
zhangqinghe
2015-01-15 10:31:43 +08:00
parent 5a33f0c6e2
commit 3d74b92952
3 changed files with 66 additions and 3 deletions
+17
View File
@@ -223,6 +223,23 @@ JPushPlugin.prototype.setDebugMode = function(mode){
this.call_native("setDebugMode",[mode],null);
}
}
JPushPlugin.prototype.addLocalNotification = function(builderId,content,title,notificaitonID,broadcastTime,extras){
if(device.platform == "Android") {
data=[builderId,content,title,notificaitonID,broadcastTime,extras];
this.call_native("addLocalNotification",data,null);
}
}
JPushPlugin.prototype.removeLocalNotification = function(notificationID){
if(device.platform == "Android") {
this.call_native("removeLocalNotification",[notificationID],null);
}
}
JPushPlugin.prototype.clearLocalNotifications = function(){
if(device.platform == "Android") {
data=[]
this.call_native("clearLocalNotifications",data,null);
}
}
//iOS single