Commit 09d7c791 by 修福龙

修复刷脸窗口循环弹出的问题

parent d907f077
......@@ -173,7 +173,7 @@ class FacePage extends Component {
handleScaleChange = async ({count}) => {
if (count === -1) {
// 重力感应开始识别
this.wechatFace(true);
this.wechatFace();
} else if (count === 0) {
// 重力感应归零
this.leaveC();
......@@ -235,9 +235,9 @@ class FacePage extends Component {
};
// 微信人脸身份识别
wechatFace = async face => {
wechatFace = async () => {
const {orderDetailsModal, tipsModal} = this.state;
if ((orderDetailsModal || tipsModal) && !face) {
if (orderDetailsModal || tipsModal) {
return;
} // 出现订单弹窗,不做人脸识别
const tipText = '正在人脸识别,请看向屏幕,靠中间站稳';
......@@ -394,7 +394,7 @@ class FacePage extends Component {
<View style={styles.faceRecogn}>
<Touch
style={styles.faceGif}
onPress={() => this.wechatFace(true)}
onPress={() => this.wechatFace()}
feedback={false}>
<Image
source={require('../assets/Vertical/face.gif')}
......@@ -422,7 +422,7 @@ class FacePage extends Component {
)}
</View>
<Touch
onPress={() => this.wechatFace(true)}
onPress={() => this.wechatFace()}
style={styles.btnCome}
feedback={false}>
<View style={styles.click}>
......@@ -619,7 +619,7 @@ const styles = {
backgroundColor: '#FC4000',
width: '70%',
// height: '18%',
// height: 200,
height: 200,
justifyContent: 'center',
alignItems: 'center',
marginRight: 5,
......@@ -636,7 +636,7 @@ const styles = {
callTouch: {
width: '30%',
// height: '18%',
// height: 200,
height: 200,
marginLeft: 5,
backgroundColor: '#FC4000',
},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment