ios - 使用推送通知服务扩展上传应用程序

标签 ios objective-c xcode app-store-connect rich-notifications

I just created an application with bundle identifier com.example.xyz

并且还为此生成了供应和证书。现在,我需要使用 Push Notification Service Extension 来使用 Rich notification 所以我创建了名为 AppNameNotificationService 的新目标并尝试在设备上运行该应用程序,但它没有工作 bcoz 我创建的扩展目标 有 bundle ID com.example.xyzNotificationServie 不匹配 我为我的应用程序创建的配置。

So, what I did is I created new APP ID on developer account with the bundle ID com.example.xyzNotificationServie and generated provisioning for the same.

现在一切正常。我使用了扩展,一切都很好。但是 Rich push notification 只有在我运行扩展目标而不是实际的 App 目标时才有效。没关系,因为我知道每个扩展都是这样工作的。

But now, I am confused that If I will upload my app on iTC then what should be my app bundle identifier?

What should I archieve from Xcode, either App target or extension target?

谁能帮忙??

最佳答案

应用扩展随您的主应用一起安装在设备上。应用程序扩展是我们在主项目中添加的目标。扩展与主项目捆绑在一起。 因此,您的主要应用 ID 将用于将带有扩展名的应用上传到应用商店。

关于ios - 使用推送通知服务扩展上传应用程序,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43315765/

相关文章:

iphone - xcode:如何在使用 AVFoundation 录制音频后保存音频文件

ios - 显示窗口级别的 View UIWindowLevelStatusBar 退出当前的第一响应者

ios - 删除对象作为某些 KVO 属性的观察者的最佳实践

具有返回值的 iOS block

ios - 将图像从 Google Places Photo JSON 返回到 imageView

swift - 在展开可选值 prepareForSegue 时意外发现 nil

objective-c - 在设备之间来回发送 NSData - GameCenter 替代方案

ios - Swift iOS - 游戏重置时角色动画静态

ios - Apple 的反向地理编码国家列表

iphone - iOS,我应该如何设置周期性的本地推送通知,例如每月的1号?