之后,遇到
提示要获取通知权限时,显示的是: (null)
而不是app的名字
猜测可能是通过category去设置的。
搜:
swift local notification null want to get access
iOS local notification
cocoa touch – Ask for User Permission to Receive UILocalNotifications in iOS 8 – Stack Overflow
TheCodeNinja — Notifications in iOS 8 Part 1 (Using Swift) – What…
iOS Programming Tutorial: Adding Local Notification to iPhone App
搜:
swift (null) would like to send your notifications
ios – "(null)" Would like to send you notifications with iOS9 / XCode 7 – Stack Overflow
设置为:
$(PRODUCT_NAME)
再去运行试试:
先去删除程序:
再去重新用Xcode调试:
就可以正常显示:
“JianDao” 想给您发送推送通知
了。