cksubscription

CloudKit + no valid aps-environment entitlement error

对着背影说爱祢 提交于 2020-01-06 14:57:18
问题 I try to use CloudKit subscriptions in my app, but didReceiveRemoteNotification not get triggered. I saved CKSubscription to CloudKit . To be sure they exists, when app starts, I plot them out, like: <CKSubscription: 0x15576310; ; Query Subscription: recordType=DailyVote, predicate=TRUEPREDICATE, subscriptionOptions=7, subscriptionID=1FA456A6-9BA5-411D-97B9-1EB57121A5D0, zoneID=(null)> predicate: TRUEPREDICATE subscriptionType: (Enum Value) subscriptionOptions: C.CKSubscriptionOptions I try

CloudKit won't reset my badge count to 0

荒凉一梦 提交于 2019-12-28 06:46:06
问题 I've tried a number of things and can't seem to reset the badge count from notifications comings from cloudKit. Has anyone else ran into this problem. Here is what I've tried: 1) Set the badge count locally to 0 application.applicationIconBadgeNumber = 0; (temporarily removes the badge count). No luck... 2) Call the server to clear the badge count CKModifyBadgeOperation *oper = [[CKModifyBadgeOperation alloc] initWithBadgeValue:0]; [oper start]; No luck... 3) Pull in all notification changes

CloudKit Subscription Notification for CKReference Not Working As Expected

风格不统一 提交于 2019-12-23 15:44:57
问题 I'm trying to setup a CKSubscription for records that contain a field with a CKReference to the user. But anytime a record is created, it ignores this part of the compoundPredicate and the notification never comes. Is there something different about using a CKReference in a predicate for a CKSubscription? I go into the dashboard to enter a new record under my own user recordID (while running another user in simulator) because I believe I read that if the record comes from the device, it won't

How to set up a minimal CKSubscription?

让人想犯罪 __ 提交于 2019-12-20 12:38:07
问题 I want to set up a simple CKSubscription that notifies me a recordType was created, how? 回答1: After experimenting a while this is how to setup a minimal CKSubscription. You have to test it on Device, push notification does not work on simulator. You can add record in Dashboard, that will trigger push notification too. func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: NSDictionary?) -> Bool { application.registerUserNotificationSettings

CKQuerySubscriptions are not supported in a sharedCloudDatabase

这一生的挚爱 提交于 2019-12-08 06:40:00
问题 I noticed that the docs mention that the newly introduced shared CloudKit databases do not support CKQuerySubscription (in earlier iOS versions these were called CKSubscription ). So I guess that means that it is not possible to notify users when privately shared records have changed. Major disappointment. Has anyone run into this problem? 回答1: According to the WWDC video about CloudKit this year: So, new this year in iOS 10, there's an API called CKDatabaseSubscription. This allows you to

CKQuerySubscriptions are not supported in a sharedCloudDatabase

一笑奈何 提交于 2019-12-08 03:17:27
I noticed that the docs mention that the newly introduced shared CloudKit databases do not support CKQuerySubscription (in earlier iOS versions these were called CKSubscription ). So I guess that means that it is not possible to notify users when privately shared records have changed. Major disappointment. Has anyone run into this problem? According to the WWDC video about CloudKit this year: So, new this year in iOS 10, there's an API called CKDatabaseSubscription. This allows you to subscribe to any change across an entire database, and it works in a private database, in a shared database.

How to set up a minimal CKSubscription?

爷,独闯天下 提交于 2019-12-03 02:57:31
I want to set up a simple CKSubscription that notifies me a recordType was created, how? After experimenting a while this is how to setup a minimal CKSubscription. You have to test it on Device, push notification does not work on simulator. You can add record in Dashboard, that will trigger push notification too. func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: NSDictionary?) -> Bool { application.registerUserNotificationSettings(UIUserNotificationSettings(forTypes: .Alert, categories: nil)) application.registerForRemoteNotifications() return true }

Observe CKRecord deletion via CKSubscription does not work

孤街浪徒 提交于 2019-11-29 14:07:02
问题 CKSubscription doc says: When a record modification causes a subscription to fire, the server sends push notifications to all devices with that subscription except for the one that made the original change to the record. Let assume I have two devices: device 1 and device 2 logged in from different iCloud accounts. Let assume both devices subscribed for record deletion for a certain record type. If device 1 creates a record and then device 1 deletes it then device 2 get notified - THAT IS

CloudKit push notifications on record update stopped working

我只是一个虾纸丫 提交于 2019-11-28 12:21:29
EDIT : Retested today 27.08.2015 and it works again, Apple has fixed it. I have an application in development mode. The application uses CKSubscription to get notified on changes on the server, configured for all three options: create, update, delete. Everything was working fine but recently during regression tests I have discovered the application does not receive notifications on record updates, the create and delete notifications are still working. The susbcription types are set correctly for all three options as I checked on the dashboard and the application is registered for

CloudKit push notifications on record update stopped working

烂漫一生 提交于 2019-11-27 06:55:52
问题 EDIT : Retested today 27.08.2015 and it works again, Apple has fixed it. I have an application in development mode. The application uses CKSubscription to get notified on changes on the server, configured for all three options: create, update, delete. Everything was working fine but recently during regression tests I have discovered the application does not receive notifications on record updates, the create and delete notifications are still working. The susbcription types are set correctly