Commit 80234996 by 黄日华

屏保添加无码商品

parent 44751709
...@@ -71,7 +71,7 @@ const CounterMixins = ComposeComponent => { ...@@ -71,7 +71,7 @@ const CounterMixins = ComposeComponent => {
cloudFinishModal: false, cloudFinishModal: false,
noBuyModal: false, noBuyModal: false,
logoVisible: true, logoVisible: true,
nobodyVoice: true, nobodyVoice: false,
}; };
componentWillMount = async () => { componentWillMount = async () => {
...@@ -135,7 +135,9 @@ const CounterMixins = ComposeComponent => { ...@@ -135,7 +135,9 @@ const CounterMixins = ComposeComponent => {
}); });
this.printerConnect(); this.printerConnect();
this.listen(); this.listen();
if (this.state.nobodyVoice) {
this.guideVoice(); this.guideVoice();
}
}; };
initSetting = () => { initSetting = () => {
...@@ -153,7 +155,6 @@ const CounterMixins = ComposeComponent => { ...@@ -153,7 +155,6 @@ const CounterMixins = ComposeComponent => {
type: 'store/findModuleSetting', type: 'store/findModuleSetting',
group, group,
}); });
console.warn(data.data);
if (data.code === 1 && data.data) { if (data.code === 1 && data.data) {
const state = {priceVisible: data.data.priceVisible}; const state = {priceVisible: data.data.priceVisible};
if (data.data.cardCounter) { if (data.data.cardCounter) {
...@@ -261,7 +262,6 @@ const CounterMixins = ComposeComponent => { ...@@ -261,7 +262,6 @@ const CounterMixins = ComposeComponent => {
window.socket.on( window.socket.on(
'goodsOperate', 'goodsOperate',
({type, number, row, barcode, price}) => { ({type, number, row, barcode, price}) => {
console.warn('goodsOperate', barcode);
const index = row; const index = row;
if (type === 'add') { if (type === 'add') {
// 新增 // 新增
...@@ -1027,15 +1027,15 @@ const CounterMixins = ComposeComponent => { ...@@ -1027,15 +1027,15 @@ const CounterMixins = ComposeComponent => {
guideVoice = () => { guideVoice = () => {
if (this.nobodyInter) clearInterval(this.nobodyInter); if (this.nobodyInter) clearInterval(this.nobodyInter);
// const that = this; const that = this;
this.nobodyInter = setInterval(async () => { this.nobodyInter = setInterval(async () => {
// if (this.state.nobodyVoice) { if (this.state.nobodyVoice) {
// await Speech.speak('您好,选购完商品后请到收银机这边付款'); await Speech.speak('您好,选购完商品后请到收银机这边付款');
// await wait(5000); await wait(5000);
// await Speech.speak('请先扫描商品条码,再出示付款码'); await Speech.speak('请先扫描商品条码,再出示付款码');
// } else { } else {
// clearInterval(that.nobodyInter); clearInterval(that.nobodyInter);
// } }
}, 45000); }, 45000);
this.setState({ this.setState({
nobodyVoice: true, nobodyVoice: true,
......
...@@ -706,7 +706,15 @@ class VerticalPage extends Component { ...@@ -706,7 +706,15 @@ class VerticalPage extends Component {
justifyContent: 'flex-end', justifyContent: 'flex-end',
alignItems: 'center', alignItems: 'center',
}}> }}>
<View style={[styles.guardModal_button_call, {opacity: 0}]} /> <Touch onPress={() => this.props.handleCodeless()}>
<View
style={[
styles.guardModal_button_nobuy,
{marginRight: 50},
]}>
<Text style={styles.callText}>无码商品</Text>
</View>
</Touch>
<Touch onPress={() => this.props.handleBarcode()}> <Touch onPress={() => this.props.handleBarcode()}>
<View style={styles.guardModal_button_nobuy}> <View style={styles.guardModal_button_nobuy}>
<Text style={styles.callText}>输入条码</Text> <Text style={styles.callText}>输入条码</Text>
......
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