小编use*_*419的帖子

Visual Studio Cordova缺少Info.plist键

我正在使用visual studio开发cordova应用程序.

如果我使用Xcode8将我的应用程序上传到商店,我会收到以下错误邮件.

Missing Info.plist key - This app attempts to access privacy-sensitive data without a usage description. The app's Info.plist must contain an NSPhotoLibraryUsageDescription key with a string value explaining to the user how the app uses this data.

基于另一个stackoverflow问题,我添加了插件https://github.com/leecrossley/cordova-plugin-transport-security并修改了plugin.xml:

<platform name="ios"> <config-file target="*-Info.plist" parent="NSAppTransportSecurity"> <dict> <key>NSAllowsArbitraryLoads</key> <true/> <key>NSPhotoLibraryUsageDescription</key> <string>This app requires access to the photo library.</string> <key>NSMicrophoneUsageDescription</key> <string>This app does not require access to the microphone.</string> <key>NSCameraUsageDescription</key> <string>This app requires access to the camera.</string> </dict> </config-file> …

xcode info.plist visual-studio ios cordova

11
推荐指数
1
解决办法
796
查看次数

Swift 编译器 - Xcode 9.1 中缺少 General

我试图在目标->构建设置-> Objective C 桥接标头中提供桥接标头

我可以使用Xcode 9创建的项目来做到这一点

在此输入图像描述

但我在Xcode 9.1中找不到Objective C Bridging 标头。在 Xcode 9.1 中创建的项目中缺少它,如下所示。

在此输入图像描述

xcode ios swift bridging-header xcode9.1

1
推荐指数
1
解决办法
3897
查看次数

来自时间戳的日期变得错误

我正在尝试将时间戳转换为日期.但它返回错误的日期.

我有时间戳

1524637838000.0

根据此在线转换器返回25-04-2018 12:00

但是在使用我的代码进行转换时,我的日期错误

let date = Date(timeIntervalSince1970:1524637838000.0)
    let dateFormatter = DateFormatter()
    dateFormatter.dateFormat = "dd-MM-yyyy hh:mm"
    let myDate = dateFormatter.string(from: date)
    print("Date is = ",myDate)
Run Code Online (Sandbox Code Playgroud)

我明白了

07-11-50283 12:03

结果.我的代码有什么问题吗?

timestamp date nsdateformatter ios swift

1
推荐指数
1
解决办法
223
查看次数