X-Git-Url: http://plrg.eecs.uci.edu/git/?a=blobdiff_plain;f=Methods%2FsendNotificationToContacts.groovy;h=06563c0878eb63d714a5dd88caffa1ea776a982b;hb=3de3a90422a04058becf03dd39555943c1770f9f;hp=165d0a4320a977b8e0382d24b9aba7beeebd6dd4;hpb=d6c9bed26d6482e0565de85fda57281899546ebb;p=smartthings-infrastructure.git diff --git a/Methods/sendNotificationToContacts.groovy b/Methods/sendNotificationToContacts.groovy index 165d0a4..06563c0 100644 --- a/Methods/sendNotificationToContacts.groovy +++ b/Methods/sendNotificationToContacts.groovy @@ -9,3 +9,13 @@ def sendNotificationToContacts(String text, String recipients) { } } } + +def sendNotificationToContacts(String text, String recipients, LinkedHashMap metaData) { + for (int i = 0;i < recipients.size();i++) { + for (int j = 0;j < location.contacts.size();j++) { + if (recipients[i] == location.contacts[j]) { + println("Sending \""+text+"\" to "+location.phoneNumbers[j].toString()) + } + } + } +}