首页 > 解决方案 > Ionic IOS 导入多个文件

问题描述

如果我在 Apple Files 应用程序中并选择多个文档并希望将它们导入我的应用程序,它只会导入第一个文档,而不是所有选定的文档。因此,当我启动模拟器并打开查找器时,我可以在模拟器的 temp/Name-Inbox 文件夹中看到只有一个文件,但我希望将所有文件都放在这个文件夹中。是否可以更改设置以使其成为可能,例如在 Info.plist 中?

我正在使用 Ionic 5 和 Cordova 10。

这是我的 Info.plist:

<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
  <key>CFBundleDevelopmentRegion</key>
  <string>en_US</string>
  <key>CFBundleDisplayName</key>
  <string>Name</string>
  <key>CFBundleExecutable</key>
  <string>$(EXECUTABLE_NAME)</string>
  <key>CFBundleIdentifier</key>
  <string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
  <key>CFBundleInfoDictionaryVersion</key>
  <string>6.0</string>
  <key>CFBundleName</key>
  <string>$(PRODUCT_NAME)</string>
  <key>CFBundlePackageType</key>
  <string>APPL</string>
  <key>CFBundleShortVersionString</key>
  <string>1.1.0</string>
  <key>CFBundleSignature</key>
  <string>????</string>
  <key>CFBundleVersion</key>
  <string>1.1.0</string>
  <key>LSRequiresIPhoneOS</key>
  <true/>
  <key>NSMainNibFile</key>
  <string/>
  <key>NSMainNibFile~ipad</key>
  <string/>
  <key>UILaunchStoryboardName</key>
  <string>CDVLaunchScreen</string>
  <key>UIRequiresFullScreen</key>
  <true/>
  <key>UISupportedInterfaceOrientations</key>
  <array>
      <string>UIInterfaceOrientationPortrait</string>
      <string>UIInterfaceOrientationPortraitUpsideDown</string>
  </array>
  <key>UISupportedInterfaceOrientations~ipad</key>
  <array>
      <string>UIInterfaceOrientationPortrait</string>
      <string>UIInterfaceOrientationPortraitUpsideDown</string>
  </array>
  <key>NSAppTransportSecurity</key>
  <dict>
      <key>NSAllowsArbitraryLoads</key>
      <true/>
  </dict>
  <key>UIInterfaceOrientation</key>
  <array>
      <string>UIInterfaceOrientationPortrait</string>
  </array>
  <key>NSCameraUsageDescription</key>
  <string/>
  <key>NSPhotoLibraryAddUsageDescription</key>
  <string>This app requires photo library access to function properly.</string>
  <key>NSPhotoLibraryUsageDescription</key>
  <string>This app requires photo library access to function properly.</string>
  <key>NSFaceIDUsageDescription</key>
  <string/>
  <key>UISupportsDocumentBrowser</key>
  <false/>
  <key>LSSupportsOpeningDocumentsInPlace</key>
  <false/>
  <key>ITSAppUsesNonExemptEncryption</key>
  <false/>
  <key>CFBundleDocumentTypes</key>
  <array>
      <dict>
          <key>CFBundleTypeIconFiles</key>
          <array/>
          <key>CFBundleTypeMIMETypes</key>
          <array/>
          <key>CFBundleTypeName</key>
          <string>Portable Document Format</string>
          <key>CFBundleTypeRole</key>
          <string>Viewer</string>
          <key>LSHandlerRank</key>
          <string>Owner</string>
          <key>LSItemContentTypes</key>
          <array>
              <string>com.adobe.pdf</string>
          </array>
      </dict>
  </array>
  <key>CFBundleLocalizations</key>
  <array>
      <string>en</string>
      <string>de</string>
      <string>nl</string>
      <string>fr</string>
      <string>it</string>
      <string>pt-BR</string>
  </array>
  <key>NSCalendarsUsageDescription</key>
  <string/>
  <key>NSContactsUsageDescription</key>
  <string/>
</dict>
</plist>

标签: ioscordovaionic-frameworkimportdocument

解决方案


推荐阅读