Authored by 孙凯

add camera param review by hongmo

... ... @@ -23,9 +23,9 @@ RCT_EXPORT_METHOD(startScanQRCode) {
avscanViewController.scanType = YHScanType_Express;
[avscanViewController.view setFrame:[[UIScreen mainScreen] bounds]];
avscanViewController.resultCallBack = ^(NSString *info) {
NSDictionary *dic = @{@"QRCode" : info};
[self.bridge.eventDispatcher sendAppEventWithName:@"scanQRComplete"
body:info];
body:dic];
};
AppDelegate *delegate = (AppDelegate *)[[UIApplication sharedApplication] delegate];
... ...
... ... @@ -43,6 +43,8 @@
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>
<key>NSCameraUsageDescription</key>
<string>使用相机</string>
<key>NSLocationWhenInUseUsageDescription</key>
<string></string>
<key>UIRequiredDeviceCapabilities</key>
... ... @@ -57,7 +59,5 @@
</array>
<key>UIViewControllerBasedStatusBarAppearance</key>
<false/>
<key>NSCameraUsageDescription</key>
<string>使用相机</string>
</dict>
</plist>
... ...
... ... @@ -58,8 +58,7 @@ class DeliverGoodsContainer extends Component {
this.subscription = NativeAppEventEmitter.addListener(
'scanQRComplete',
(param) => {
console.log(param);
this.props.actions.setExpressNum(param);
this.props.actions.setExpressNum(param.QRCode);
}
);
}
... ...