-
Notifications
You must be signed in to change notification settings - Fork 1.9k
"Actionable" Notification Buttons #62
Comments
@jterps08 Yes, the action buttons are on the roadmap. I was just talking with someone last night about this. If possibly I'll get it into the 1.2 release. Please raise a separate issue for multi line notifications as well. +1 this folks if you want it. |
👍 scheduled 1.2 release date? |
Sweet thanks! |
@austinpapp When something is ready it goes right into master but I try to maintain official releases at the end of each month where I will tag and submit to npm. |
@macdonst sounds good. was just curious as this helps me with my personal roadmap. thanks for the hard work. |
So how do you folks expect this to work, when you click on an action button will it fire off a native Android intent or will it call a JS function in the app? Possibly looking at something like this:
If each action will need to have either an "action" which will call an Android intent or a "callback" which is some JS that can get executed. Just thinking out loud but what does everyone think? |
From our end, I think having the buttons be able to call JS functions within the phonegap app would be most useful. I think LinkedIn does this with their app nicely where you can accept a connection request or view profile directly from the notification drawer... Curious what @austinpapp thinks... |
having that key action or callback handle different functionality makes sense to me. this could potentially open up further use cases outside of our needs. for my purposes, a callback is our use case. ultimately we would call the |
@jterps08 & @austinpapp okay, thanks for the feedback, I will make the JS callback route the first priority. |
@macdonst thanks . 👊 |
@jterps08 & @austinpapp alright, I was noodling around with some code this afternoon and if you get a chance please try out the issue62 branch of the plugin. Try sending the push in the following format:
It should create two buttons in the notification and when you click on it the corresponding callback will be invoked with the notification data as the parameter being passing into the method. |
@jterps08 & @austinpapp I merged it into master. Please give me some feedback when you get a chance. I'm targeting the 1.2 release for Wednesday the 26th. |
@macdonst hey thanks for the quick turnaround on this. let me get through a few things this week and try and get back to you asap on some feedback. |
This is great, what fantastic work you guys have done. Really excited about this new update 👍 |
@macdonst I wanted to know if this was ready to receive push notifications, and add the buttons for Android and iOS. I looked at the documentation but saw no examples of how to use it, am i looking in the wrong place ? Thanks Addy |
👍 |
@mrAddy If you look at the README under Android Behaviour/Action Buttons you will see how to send a push with buttons and how to act on their tap. This is in Support for buttons on iOS will come along with the iOS9 update that I'm going to be working on for September. |
@macdonst Thank you for getting back, I have looked at it, but I am using Appery.io, and trying to use this Push plugin, but i do not understand what i am doing if i am honest. I need buttons on push notification, and Appery are not looking to implement this. When i included the Push.js i had errors regarding the var cordova on line 7. I am guessing having two Push solutions in the same app will not be compatible? |
@mrAddy Is Appery.io a Cordova/PhoneGap based solution? Because if their service doesn't include cordova.js then you will not be able to use this plugin. |
Hi @macdonst yeah it is, it is a little complex because of how they work there file system, but i am now trying to install your plugin, based on their own documentation on adding 3rd party plugins. So i should know in about 20 mins if it works :) But I do understand a lot more than I did an hour ago :) |
I am getting a build error : src/com/adobe/phonegap/push/GCMIntentService.java:[28,29] error: package android.support.v4.app does not exist /src/com/adobe/phonegap/push/GCMIntentService.java:[201,64] error: package NotificationCompat does not exist I cannot see a sport.v4 file, but i do have a v.13 in my libs, or is that something else ? |
@mrAddy make sure that the most up to date android-support-v13.jar file is in your libs folder and picked up by the build. |
* 'master' of github.com:phonegap/phonegap-plugin-push: Update README Update CHANGELOG Version 1.2.0 Issue phonegap#75: Implement Big Picture Style for Android Issue phonegap#74: Implement Inbox style for Android Issue phonegap#67: Pushes being deleted from notification bar when cold start Issue phonegap#62: "Actionable" Notification Buttons Issue phonegap#65: On Android, GCMIntentService.onError() doesn't get passed to the JavaScript 'error' event Group notifications and insert Html format
Would be nice to also add some field to the |
@macdonst Just wanted to follow up on this. Due to some issues on our end, we weren't able to test the new plugin until now. We have transitioned from our old plugin to this one and we're now in process of adding buttons. WIll update soon, but didn't want you to think we forgot about this and your quick action on it! Thanks again - J |
Please how can i implement actionable to this code: // API access key from Google API's Console // prep the bundle $msg = array ); $alert = $msg; $headers = array $ch = curl_init(); |
Hello @macdonst , I am new to Mobile development. May I know where exactly I need to place my callback function ? here, where exactly I can place the Archive and reply javascript function, basically my requirement is to open a sepcific page on push notification click instead of opening an app with default landing page. Appreciate your response on this. Thank you :) |
@GaneshSawant your callback function must be addressable from window. So if the function is |
This thread has been automatically locked. |
Greetings - Thank you @macdonst for all of your work with PhoneGap. We currently use your videoplayer plugin for Powerline. Good stuff!
Anyway, we are looking for the ability to add buttons to a notification similar to how GMail allows you to View or Reply to an e-mail when you're looking at the preview in the OS notification drawer (see image below). Your Push plugin has all the other features we're looking for (remote loaded large icon, small icon overlay, title, message, sound, badge, etc.), but it doesn't have multi-line text support (again, think previewing a gmail message) or this button concept.
Is that on your roadmap at all? Do you know if anyone is currently working on that? Hope this is the right place for this question!
Thanks,
Jesse
The text was updated successfully, but these errors were encountered: