Gettinf错误:插件'设备'找不到,或者不是CDVPlugin。检查config.xml中的插件映射。 XCODE

时间:2014-07-10 10:50:57

标签: ios xcode cordova phonegap-plugins

我在x代码项目中遇到插件错误,其中我使用了手机间隙。我还集成了In App Purchase ..但是当我运行项目时,我收到插件错误,我将在下面显示。我使用此链接完成了此操作github link

2014-07-10 16:18:07.648 Mileage[8340:60b] Unlimited access to network resources
2014-07-10 16:18:07.700 Mileage[8340:60b] CDVPlugin class CDVSplashScreen (pluginName: splashscreen) does not exist.
2014-07-10 16:18:07.701 Mileage[8340:60b] [CDVTimer][splashscreen] 0.514984ms
2014-07-10 16:18:07.701 Mileage[8340:60b] [CDVTimer][TotalPluginStartup] 0.954986ms
2014-07-10 16:18:07.824 Mileage[8340:60b] Resetting plugins due to page load.
2014-07-10 16:18:08.641 Mileage[8340:60b] Finished load of: file:///Users/jaykishanvansadawala/Library/Application%20Support/iPhone%20Simulator/7.1/Applications/3890311E-0D18-42FA-8A28-58BB8EA6EFEC/Mileage.app/www/index.html#settings-page
2014-07-10 16:18:08.687 Mileage[8340:60b] CDVPlugin class CDVDevice (pluginName: Device) does not exist.
2014-07-10 16:18:08.687 Mileage[8340:60b] ERROR: Plugin 'Device' not found, or is not a CDVPlugin. Check your plugin mapping in config.xml.
2014-07-10 16:18:08.687 Mileage[8340:60b] -[CDVCommandQueue executePending] [Line 158] FAILED pluginJSON = [
  "Device1682550080",
  "Device",
  "getDeviceInfo",
  [

  ]
]
2014-07-10 16:18:08.688 Mileage[8340:60b] CDVPlugin class CDVConnection (pluginName: NetworkStatus) does not exist.
2014-07-10 16:18:08.688 Mileage[8340:60b] ERROR: Plugin 'NetworkStatus' not found, or is not a CDVPlugin. Check your plugin mapping in config.xml.
2014-07-10 16:18:08.688 Mileage[8340:60b] -[CDVCommandQueue executePending] [Line 158] FAILED pluginJSON = [
  "NetworkStatus1682550081",
  "NetworkStatus",
  "getConnectionInfo",
  [

  ]
]
2014-07-10 16:18:17.506 Mileage[8340:60b] CDVPlugin class InAppPurchase (pluginName: InAppPurchase) does not exist.
2014-07-10 16:18:17.506 Mileage[8340:60b] ERROR: Plugin 'InAppPurchase' not found, or is not a CDVPlugin. Check your plugin mapping in config.xml.
2014-07-10 16:18:17.506 Mileage[8340:60b] -[CDVCommandQueue executePending] [Line 158] FAILED pluginJSON = [
  "InAppPurchase1682550082",
  "InAppPurchase",
  "debug",
  [

  ]
]
2014-07-10 16:18:17.507 Mileage[8340:60b] CDVPlugin class InAppPurchase (pluginName: InAppPurchase) does not exist.
2014-07-10 16:18:17.507 Mileage[8340:60b] ERROR: Plugin 'InAppPurchase' not found, or is not a CDVPlugin. Check your plugin mapping in config.xml.
2014-07-10 16:18:17.507 Mileage[8340:60b] -[CDVCommandQueue executePending] [Line 158] FAILED pluginJSON = [
  "InAppPurchase1682550083",
  "InAppPurchase",
  "noAutoFinish",
  [

  ]
]
2014-07-10 16:18:17.508 Mileage[8340:60b] CDVPlugin class InAppPurchase (pluginName: InAppPurchase) does not exist.
2014-07-10 16:18:17.508 Mileage[8340:60b] ERROR: Plugin 'InAppPurchase' not found, or is not a CDVPlugin. Check your plugin mapping in config.xml.
2014-07-10 16:18:17.508 Mileage[8340:60b] -[CDVCommandQueue executePending] [Line 158] FAILED pluginJSON = [
  "InAppPurchase1682550084",
  "InAppPurchase",
  "setup",
  [

  ]
]
2014-07-10 16:18:17.508 Mileage[8340:60b] CDVPlugin class InAppPurchase (pluginName: InAppPurchase) does not exist.
2014-07-10 16:18:17.509 Mileage[8340:60b] ERROR: Plugin 'InAppPurchase' not found, or is not a CDVPlugin. Check your plugin mapping in config.xml.
2014-07-10 16:18:17.509 Mileage[8340:60b] -[CDVCommandQueue executePending] [Line 158] FAILED pluginJSON = [
  "InAppPurchase1682550085",
  "InAppPurchase",
  "load",
  [
    [
      "com.innospace.autotax"
    ]
  ]
]

1 个答案:

答案 0 :(得分:0)

好像你手动添加了插件而忘了添加一些配置cordova_plugin.js / config.xml。

请找到以下代码。

 <feature name="NetworkStatus">
         <param name="ios-package" value="CDVConnection" />
 </feature>

网络状态将是功能名称,值将是您的班级名称。

同时检查cordova_plugin.js

cordova.define('cordova/plugin_list', function(require, exports, module) {
    module.exports = [{
        "file": "plugins/org.apache.cordova.dialogs/www/notification.js",
        "id": "org.apache.cordova.dialogs.notification",
        "merges": ["navigator.notification"]
    }, {
        "file": "plugins/org.apache.cordova.network-information/www/network.js",
        "id": "org.apache.cordova.network-information.network",
        "clobbers": ["navigator.connection", "navigator.network.connection"]
    }];
    module.exports.metadata = // TOP OF METADATA 
    {
        "org.apache.cordova.device": "0.2.8",
        "org.apache.cordova.network-information": "0.2.7"
    }
});

这些是一些权限类型。