以下代码行可以每周重复一次本地通知,对吗?:
let triggerWeekly = Calendar.current.dateComponents([.weekday,hour,.minute,.second,], from: date)
let trigger = UNCalendarNotificationTrigger(dateMatching: triggerWeekly, repeats: true)
但是如何在每个月重复一次本地通知呢?安排每月通知需要哪些日期组件?
以下代码行可以每周重复一次本地通知,对吗?:
let triggerWeekly = Calendar.current.dateComponents([.weekday,hour,.minute,.second,], from: date)
let trigger = UNCalendarNotificationTrigger(dateMatching: triggerWeekly, repeats: true)
但是如何在每个月重复一次本地通知呢?安排每月通知需要哪些日期组件?