Local Notification some specific day

Hi, I 'm developing an application with ionic , in which I need the user to program the hours and days in which must reach a reminder.

I am using the plugin Cordova local notifications , as I can create a notification for example be repeated every Monday or the day that the user place ?

I’m around trying to do this but does not work

$scope.addNotification = function (task) {

  var d= new Date();

  $cordovaLocalNotification.isScheduled(task.id).then(function (isScheduled) {
    if (isScheduled){
        title: "Warning",
        template: "Notification with this ID is already scheduled"
      }).then(function(res) {
        task.id = "";
        id:      task.id,
        title:   'Notification',
        message: task.msg,
        every: "monday"
1 Like

From my knowledge, this plugin doesn’t have such a specific time frames, and it don’t need them.

// "day", "minute", "hour", "week", "month", "year"

You can use JavaScript Date object and check if it’s Monday. Or if you need to do it every Monday use these properties:

firstAt: monday_9_am,
every: "week",

Thank you!!!

Let me try that and I mention it was worked out

What I want is to set the notification the day the user choose, the Monday is just one example

1 Like

In case how to set specific in local notification.?

@Gajotres What if I want to set notification only on weekdays for specific time. For example,I want to send notification at 3 PM that remind user for daily training on Week Days only and for that below is my notification schedule code. I am using cordova local notifications plugin having version 0.8.4

var date = new Date();

 id: 1,
 title: 'Daily Training Reminder',
 at: date,
 every: 'weekday'
}).then(function (result) {

But it is not working. Could you please tell me what is wrong with this?

Thanks in advance.