cssivision / react-native-qrcode

a minimalist qrcode component for react-native
MIT License
853 stars 304 forks source link

the code can not be recognizerd #19

Closed santcool closed 7 years ago

santcool commented 8 years ago

I use it like this: <QRCode value={'http://www.baidu.com/'} bgColor="#fff" fgColor="#333"/>)

mltucker commented 8 years ago

I think you need to switch your bgColor and fgColor.

cssivision commented 7 years ago

in some Extreme situation, this may happen, but i can not fix this.

Raven11 commented 7 years ago

Facing similar issue. QrCode generated is not recognized.

froatsnook commented 7 years ago

@Raven11 what are your fgColor and bgColor?

Raven11 commented 7 years ago

@froatsnook below is the code that I am using. <QRCode value='{\"orderIdPOS\":\"41257\",\"orderIdFL\":1057,\"customerId\":119746142258,\"fulfillType\":0,\"storeCode\":\"0111001228\",\"grossAmount\":\"187\",\"netAmount\":\"155.00\",\"totalTax\":\"32.00\",\"totalDiscount\":\"0\",\"cash\":\"173.0\",\"shots\":\"14.0\",\"items\":[{\"code\":\"A001\",\"qty\":1,\"price\":\"155\",\"kkCess\":\"0.31\",\"sbCess\":\"0.31\",\"serviceTax\":\"8.68\",\"vat\":\"22.475\",\"otherTax\":\"0\",\"discount\":\"0\"}]}:T6pXI4esyWZRX3k3flSpek4jAqtEROsfVgbKgOZ/jC/aOooimZGg1NfThlgf6R7O1dnDpuRuXCmckgk8HOf/ucXSyNzr3WsZn+TT1bB3XW8/ULAqJzLh/ELDvpyQgBR0Mx0OpA3kP+JPam3DCOYi2B8iObGWmg7cXIJIU1UZYn6RafqX6A1ogT5W0+9p7Y3p5RKzFBD8tk2BQ3Tm39cg0O2fCkBMst8rrvODsXTTuQwvwT9XcDIh3edBcqYRnC91iegGccXQ2GK5f10EyiKQUIPpCpn1ILStUkCOcBoUduPNlR3lzLq82oygWnGqPsKUc5g1XWm5xbt6A6NTFv3eTQ==' size={200} bgColor='black' fgColor='white'/>

froatsnook commented 7 years ago

@Raven11 I think that's just too much data. I was able to get it to scan when I used size=300 and value='{"orderIdPOS":"41257","orderIdFL":1057,"customerId":119746142258,"fulfillType":0,"storeCode":"0111001228","grossAmount":"187","netAmount":"155.00","totalTax":"32.00","totalDiscount":"0","cash":"173.0","shots":"14.0"}' (i.e. I cut out items and the base64 at the end -- also unescaped the " since you used a ' quote, but that shouldn't really matter).

cssivision commented 7 years ago

too much data