{"action":"closed","issue":{"url":"https://api.github.com/repos/katzer/cordova-plugin-local-notifications/issues/768","labels_url":"https://api.github.com/repos/katzer/cordova-plugin-local-notifications/issues/768/labels{/name}","comments_url":"https://api.github.com/repos/katzer/cordova-plugin-local-notifications/issues/768/comments","events_url":"https://api.github.com/repos/katzer/cordova-plugin-local-notifications/issues/768/events","html_url":"https://github.com/katzer/cordova-plugin-local-notifications/issues/768","id":119873511,"number":768,"title":"Scheduling multiple notifications at different times","user":{"login":"khalid-hussain","id":3102714,"avatar_url":"https://avatars.githubusercontent.com/u/3102714?v=3","gravatar_id":"","url":"https://api.github.com/users/khalid-hussain","html_url":"https://github.com/khalid-hussain","followers_url":"https://api.github.com/users/khalid-hussain/followers","following_url":"https://api.github.com/users/khalid-hussain/following{/other_user}","gists_url":"https://api.github.com/users/khalid-hussain/gists{/gist_id}","starred_url":"https://api.github.com/users/khalid-hussain/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/khalid-hussain/subscriptions","organizations_url":"https://api.github.com/users/khalid-hussain/orgs","repos_url":"https://api.github.com/users/khalid-hussain/repos","events_url":"https://api.github.com/users/khalid-hussain/events{/privacy}","received_events_url":"https://api.github.com/users/khalid-hussain/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-12-02T06:02:43Z","updated_at":"2015-12-02T13:26:01Z","closed_at":"2015-12-02T13:26:01Z","body":"Hi there,\r\n\r\nI'm having some trouble here and I'm a complete beginner at Javascript. The app gets values from the GPS which is then passed to another javascript function which calculates Muslim prayer times.\r\n\r\nI then set up notifications for each of the prayer times using the function below but for some reason I'm only getting the last notification (\"This is the TEST!\"). Does anyone know why?\r\n\r\n```javascript\r\nfunction add_reminder(list, times) {\r\n        var salahTimes = [];\r\n\r\n        for (var i = 0; i < 6; i++) {\r\n            var schedule_time = new Date();\r\n            var strTimeTemp = times[list[i].toLowerCase()].split(':');\r\n\r\n            schedule_time.setHours(strTimeTemp[0], strTimeTemp[1]);\r\n            salahTimes[i] = schedule_time;\r\n        }\r\n\r\n        console.log(\"salahTimes: \");\r\n        console.log(salahTimes);\r\n        console.log(list);\r\n\r\n        cordova.plugins.notification.local.schedule([{\r\n            title: list[0],\r\n            text: \"Time for Fajr in your area\",\r\n            at: salahTimes[0],\r\n            every: \"day\"\r\n        }, {\r\n            title: list[1],\r\n            text: \"It is now Sunrise\",\r\n            at: salahTimes[1],\r\n            every: \"day\"\r\n        }, {\r\n            title: list[2],\r\n            text: \"Time for Zuhur in your area\",\r\n            at: salahTimes[2],\r\n            every: \"day\"\r\n        }, {\r\n            title: list[3],\r\n            text: \"Time for Asr in your area\",\r\n            at: salahTimes[3],\r\n            every: \"day\"\r\n        }, {\r\n            title: list[4],\r\n            text: \"Time for Maghrib in your area\",\r\n            at: salahTimes[4],\r\n            every: \"day\"\r\n        }, {\r\n            title: list[5],\r\n            text: \"Time for Isha in your area\",\r\n            at: salahTimes[5],\r\n            every: \"day\"\r\n        }, {\r\n            title: \"Khalid\",\r\n            text: \"This is the TEST!\"\r\n        }]);        \r\n    }\r\n```"}}