1
私はPhoneGapのプラグイン https://github.com/phonegap/phonegap-plugin-barcodescannerPhoneGapのバーコードスキャナのポートレートモード
にQRコードリーダーでいくつかのテストをやってる私は
cordova.plugins.barcodeScanner.scan(
function (result) {
alert("We got a barcode not \n" +
"Result: " + result.text + "\n" +
"Format: " + result.format + "\n" +
"Cancelled: " + result.cancelled);
},
function (error) {
alert("Scanning failed: " + error);
},
{
"preferFrontCamera" : true, // iOS and Android
"showFlipCameraButton" : true, // iOS and Android
"prompt" : "Place a barcode inside the scan area", // supported on Android only
"formats" : "QR_CODE,PDF_417", // default: all but PDF_417 and RSS_EXPANDED
"orientation" : "portrait" // Android only (portrait|landscape), default unset so it rotates with the device
}
);
すべては、このセクションを除いて取り組んでいるようだindex.jsにしてコードを設置、まったくトリガーしていないようです。 私はスキャナーを肖像画にする必要がありますが、常に横長モードです。
{
"preferFrontCamera" : true, // iOS and Android
"showFlipCameraButton" : true, // iOS and Android
"prompt" : "Place a barcode inside the scan area", // supported on Android only
"formats" : "QR_CODE,PDF_417", // default: all but PDF_417 and RSS_EXPANDED
"orientation" : "portrait" // Android only (portrait|landscape), default unset so it rotates with the device
}
私は、AdobeのPhoneGapのビルドでアプリを構築し、アンドロイド6.0.1 にインストールされているが、私は間違って何かを逃したか、行って何がありますか?