{"_id":"@1ziton/react-native-scancode","_rev":"6-912b70dfed1b6580eb3cf6adf539df72","name":"@1ziton/react-native-scancode","dist-tags":{"latest":"1.0.5"},"versions":{"1.0.2":{"_from":"react-native-scancode","_id":"@1ziton/react-native-scancode@1.0.2","_inBundle":false,"_integrity":"sha1-lX8O+K4LrxGur3+2HXjf3JROUTI=","_location":"/react-native-scancode","_phantomChildren":{},"_requested":{"type":"tag","registry":true,"raw":"react-native-scancode","name":"@1ziton/react-native-bdidentifi","escapedName":"react-native-scancode","rawSpec":"","saveSpec":null,"fetchSpec":"latest"},"_requiredBy":["#USER","/"],"repository":{"type":"git","url":"git+ssh://git@github.com/Txiaomo/react-native-scancode.git"},"_resolved":"https://registry.npm.taobao.org/react-native-scancode/download/react-native-scancode-1.3.7.tgz","_shasum":"957f0ef8ae0baf11aeaf7fb61d78dfdc944e5132","_spec":"react-native-scancode","_where":"F:\\vision\\RNDemo","author":{"name":"xiaomo"},"bundleDependencies":false,"deprecated":false,"description":"## PDA扫描插件","keywords":["react-native"],"license":"PDA扫描插件","main":"index.js","name":"@1ziton/react-native-scancode","peerDependencies":{"react-native":"^0.41.2"},"scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"version":"1.0.2","gitHead":"91d3bb6e13bfe033b8b699cc18131ae92b150db0","bugs":{"url":"https://github.com/Txiaomo/react-native-scancode/issues"},"homepage":"https://github.com/Txiaomo/react-native-scancode#readme","_npmVersion":"6.4.1","_nodeVersion":"8.12.0","_npmUser":{"name":"tangjijun","email":"920449619@qq.com"},"dist":{"integrity":"sha512-UMMZhN756241B7iwuRLNMNsy5V8ad0eJc7hhNLyoEJFA7UhmXwbf+RJ3RPlvb+hAlRDzerpq56QLVL1mVI7f0Q==","shasum":"5b2bfb61250724d82138218209428b6285dc12e0","tarball":"https://registry.npmjs.org/@1ziton/react-native-scancode/-/react-native-scancode-1.0.2.tgz","fileCount":17,"unpackedSize":76860,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdY0D3CRA9TVsSAnZWagAAy20P/0LUVvIeyGhkF3Lrno9U\npuEhb+83ImcW/PurQCz+rqOd9P4tEyXhd+cuQdZ9ovMjNLEbPk8SuuBthmXc\n4el/6lNwNfwbmAUfsf1GEYFO5VcMta+a8Rs1l5mYB8dQ1hv2EdzpNZMANdFQ\nL6yEElE6oOXOSrmnt9yPrLSB9A/2n9A7WoP65r9feQDfruC9jILWhlKyqdhb\nE7hT1fdbxOhUdwoV8WpdsdllfXznxEZE+4WPGqOWCNq9Wq9LcjjF/54/UwR7\nBaMVd1YpSyc+eG4+2iPdwsGq58vJyHPXhk+8Ne56dcJhB6cKVGcuPkyPot78\nROzaXYIcmwhk0SjhhOFSw6Fct7JbseXYr1UEec149dz2pqKxbrEqRG9Y6Q/V\nNDIA6Fgdg/wvNziBUkWZJuMmtwQlD1q/rmW2pa/ze7RoXdaytihH3Gy2WgO5\nqo80tiDGFlVf6Mzjx1g8V407yrPMuVOPyhn/BHZPvebqLXuMzEsnkOsPJ/F0\nSbhX53n40S8v7MzsyndRxZrgukgrNo0vEARzG0jLEjGN8hjY1MlA6zSiG6GS\nSAaIu0DeBhZtwN1ZSl8Cq3m8VG1WGsY6Bs+9QV8FaoDy+t5pLdEjMZKsiGrk\ncfqA073BevpnJpAle2JUfE+CS8Iq59V3eQDxRs5jrkr+zZx6/N5tmi3eit2C\nFITj\r\n=S4zc\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGkTqtrgBkZneBXZRoFRh2UpPquFsGsSg3R+PiM6bhC2AiAhfVOs5FRBKfH73YnnhcnvSdQglXdy5mr4FI5fFr+wIA=="}]},"maintainers":[{"name":"wuyuxing","email":"359827672@qq.com"},{"name":"xinzhenyong","email":"494063647@qq.com"},{"name":"tangjijun","email":"920449619@qq.com"},{"name":"giscafer","email":"giscafer@outlook.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/react-native-scancode_1.0.2_1566785782667_0.8254771414377002"},"_hasShrinkwrap":false},"1.0.3":{"_from":"react-native-scancode","_id":"@1ziton/react-native-scancode@1.0.3","_inBundle":false,"_integrity":"sha1-lX8O+K4LrxGur3+2HXjf3JROUTI=","_location":"/react-native-scancode","_phantomChildren":{},"_requested":{"type":"tag","registry":true,"raw":"react-native-scancode","name":"@1ziton/react-native-scancode","escapedName":"react-native-scancode","rawSpec":"","saveSpec":null,"fetchSpec":"latest"},"_requiredBy":["#USER","/"],"repository":{"type":"git","url":"git+ssh://git@github.com/Txiaomo/react-native-scancode.git"},"_resolved":"https://registry.npm.taobao.org/react-native-scancode/download/react-native-scancode-1.3.7.tgz","_shasum":"957f0ef8ae0baf11aeaf7fb61d78dfdc944e5132","_spec":"react-native-scancode","_where":"F:\\vision\\RNDemo","author":{"name":"xiaomo"},"bundleDependencies":false,"deprecated":false,"description":"## PDA扫描插件","keywords":["react-native"],"license":"PDA扫描插件","main":"index.js","name":"@1ziton/react-native-scancode","peerDependencies":{"react-native":"^0.41.2"},"scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"version":"1.0.3","gitHead":"91d3bb6e13bfe033b8b699cc18131ae92b150db0","bugs":{"url":"https://github.com/Txiaomo/react-native-scancode/issues"},"homepage":"https://github.com/Txiaomo/react-native-scancode#readme","_npmVersion":"6.4.1","_nodeVersion":"8.12.0","_npmUser":{"name":"tangjijun","email":"920449619@qq.com"},"dist":{"integrity":"sha512-rD9869FoUZ5GMl/lE+0tkaBgpXcOjd/M1jcDe3WuNuoooiePBdCwOl9PIDIgJAXhXP81OJYCUbGvo7+eobag8g==","shasum":"42a9245f74eeb7cfcf0e1c7bf348248dc8af6882","tarball":"https://registry.npmjs.org/@1ziton/react-native-scancode/-/react-native-scancode-1.0.3.tgz","fileCount":17,"unpackedSize":76858,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdY0FJCRA9TVsSAnZWagAA0JwP/1QlRSLujQq0i6+pTqTC\nXLfjLGOBVomuTJqDYK7Ls+h6nU5AovAQeoPmLYOqnamRl+nRRkxRrwiOIjzL\n5uFXZatlvBwsG9hld3OafX4gfxQD6kvB/rjhFvohfHJ/AIyVTauvSYtYeYGl\nG8HhO6+eg5Tr18TZjp1SgJVqR2dmHy1zOiF3GonJvz9/2ZbMp42ejGToR/1q\nQ83/RXFbnxJ3gDAtmZWuHwnF3+4+RQ+w0OMnPUhMNum508shdq+aWWe1FKku\nMpgaxmnZvCUvBdSRCv7uQs6OaCe1mbEgjQi5U5l3EYfFxSWs9y6l86Aj3kxd\nKUowgkIp6tI81pqIS2lBIvtVnzkDhqtrdRUFwUd2EFcyI5Fy4Qs19mQCQ+Al\nWzMUj2/LL2P6CUILvSkKkTIR1f9zBkq7YR1FDsLCO6Fu8cfUrQz+2NhN2Jz7\nd5rVxYu5TFKoR1QfmnO0FaXXvBaPj5EZXKU1iZ3WDQroz/pDtiWpvvufDaRC\nYmKSMcsPsu0c0h9Cn38zNu0/LwaDWlIyqcrXHQcLhcJ//myHj3+gmgeB+5CF\n9dx4YbKTXmGihOK5jWO3p77t9HF/2QxGf5xdEIfvzD9yYhmwP6s+ufC5OER2\nbcTFDx5OBEPjlIajzOe8VgL/Go2j6GtZHPGXjUoAZXxCXJ+tjGyzAg1AQg+L\nbc8V\r\n=aWAL\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDHb/YsXSda1s9Onq8gv17zwDfDy0DLCJ6+3Z85qGJdhQIhAPEDyL1Ibz7beHFJxFdGaLpxrDKKp9vcZFXcygRRP60i"}]},"maintainers":[{"name":"giscafer","email":"giscafer@outlook.com"},{"name":"tangjijun","email":"920449619@qq.com"},{"name":"wuyuxing","email":"359827672@qq.com"},{"name":"xinzhenyong","email":"494063647@qq.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/react-native-scancode_1.0.3_1566785864522_0.7469716176391319"},"_hasShrinkwrap":false},"1.0.4":{"_from":"react-native-scancode","_id":"@1ziton/react-native-scancode@1.0.4","_inBundle":false,"_integrity":"sha1-lX8O+K4LrxGur3+2HXjf3JROUTI=","_location":"/react-native-scancode","_phantomChildren":{},"_requested":{"type":"tag","registry":true,"raw":"react-native-scancode","name":"react-native-scancode","escapedName":"react-native-scancode","rawSpec":"","saveSpec":null,"fetchSpec":"latest"},"_requiredBy":["#USER","/"],"repository":{"type":"git","url":"git+ssh://git@github.com/Txiaomo/react-native-scancode.git"},"_resolved":"https://registry.npm.taobao.org/react-native-scancode/download/react-native-scancode-1.3.7.tgz","_shasum":"957f0ef8ae0baf11aeaf7fb61d78dfdc944e5132","_spec":"react-native-scancode","_where":"F:\\vision\\RNDemo","author":{"name":"xiaomo"},"bundleDependencies":false,"deprecated":false,"description":"## PDA扫描插件","keywords":["react-native"],"license":"PDA扫描插件","main":"index.js","name":"@1ziton/react-native-scancode","peerDependencies":{"react-native":"^0.41.2"},"scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"version":"1.0.4","gitHead":"d04b75f67dafa385904181b14b26d667d31fa57d","bugs":{"url":"https://github.com/Txiaomo/react-native-scancode/issues"},"homepage":"https://github.com/Txiaomo/react-native-scancode#readme","_nodeVersion":"10.16.0","_npmVersion":"6.9.0","dist":{"integrity":"sha512-TnUs4xrq1a5HhAhrXDMGzHJol9FF6o03HGZRvOB35JSbHj5NzB/acfEugkKn0ICHdKvYAdIK24NU5W36OPl6Xg==","shasum":"1f93e586f3bc39aaef61a974fe74e3a7c8a09e5f","tarball":"https://registry.npmjs.org/@1ziton/react-native-scancode/-/react-native-scancode-1.0.4.tgz","fileCount":15,"unpackedSize":75219,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdjdKhCRA9TVsSAnZWagAADHYP/1PPRTr2sgm/e5KFDjw3\nC9FJeGa+47T6n+Wgq6CrIYXD6j/EkF4T4cVAsUkniihTFBR5mrJxhqhBhc/j\nHlUaapaPY0/Zmcxo6J318h1YcJxH9WKckmhIwiL3AwiaEYzQLpUPneckWO/N\njKvtXi2FmmakWKqP55h5S+o2au7fzjsZ+Fc+h9JQHNVbrNbSe1he9hLkWNwH\n3omG3b0xZSKuLa3kYTtCohdG5NmBIqmNteI7MOmHcxuVvpmNNbNyjyXDKAEt\nnAEmRCPIc3/MVNzrmjK7F06Yr3ZQ8bJSUT+nf6uv/UpsL4FkDGTJzuRg/yo5\nq05ghqWunnpF90iFvNtg0Ozaiba+vF/n7EowLSG92fLFecW++EkchqOeQpff\n+R7DJTS3JZgMfVJMB+9KK+q7zxAyGVG2wN6P7ZlFpSr/KtKsZh91765KKLFo\nacSv+aQANztSIrnhlNe61hM2T/n2WPcP1zoye/oOLHhi6wliAJ8FsL6hGQB9\nwr7FSAnLgP04EA5oH5HsSU/+VLdZA7JXvs9lptOcVccR1BywLx/jUPKW20gN\nJ7iY1rPPAyXDQSRc+eDDvh0QYPeJwsb1ncIiDIIUtr2ShT/kkfhcUG2AUgqi\n8HaJPWohbaRhPx6VMTr0x/k1dzeOIDdLdeGc4ckzd/FH2o5ymVk3YqiE9Wcq\nNSJR\r\n=uWnY\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCICqtUW3atEpKZg+zKPLljo/VdcQ/n1+ITLb/yOMpH3x9AiAyzHpCKFZnrjptownZsZJ/rhnyNjnOhYSPHk8SA6Y7Bg=="}]},"maintainers":[{"name":"giscafer","email":"giscafer@outlook.com"},{"name":"tangjijun","email":"920449619@qq.com"},{"name":"wuyuxing","email":"359827672@qq.com"},{"name":"xinzhenyong","email":"494063647@qq.com"}],"_npmUser":{"name":"xinzhenyong","email":"494063647@qq.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/react-native-scancode_1.0.4_1569575584994_0.9917205338914583"},"_hasShrinkwrap":false},"1.0.5":{"_from":"react-native-scancode","_id":"@1ziton/react-native-scancode@1.0.5","_inBundle":false,"_integrity":"sha1-lX8O+K4LrxGur3+2HXjf3JROUTI=","_location":"/react-native-scancode","_phantomChildren":{},"_requested":{"type":"tag","registry":true,"raw":"react-native-scancode","name":"react-native-scancode","escapedName":"react-native-scancode","rawSpec":"","saveSpec":null,"fetchSpec":"latest"},"_requiredBy":["#USER","/"],"repository":{"type":"git","url":"git+ssh://git@github.com/Txiaomo/react-native-scancode.git"},"_resolved":"https://registry.npm.taobao.org/react-native-scancode/download/react-native-scancode-1.3.7.tgz","_shasum":"957f0ef8ae0baf11aeaf7fb61d78dfdc944e5132","_spec":"react-native-scancode","_where":"F:\\vision\\RNDemo","author":{"name":"xiaomo"},"bundleDependencies":false,"deprecated":false,"description":"## PDA扫描插件","keywords":["react-native"],"license":"PDA扫描插件","main":"index.js","name":"@1ziton/react-native-scancode","peerDependencies":{"react-native":"^0.41.2"},"scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"version":"1.0.5","gitHead":"451814fa851870baa170d22bcc75e78600a6fb2e","bugs":{"url":"https://github.com/Txiaomo/react-native-scancode/issues"},"homepage":"https://github.com/Txiaomo/react-native-scancode#readme","_nodeVersion":"10.16.0","_npmVersion":"6.9.0","dist":{"integrity":"sha512-SGgr2KFCKwvjtj6gubn42eT6BYggV+n78qV9yxq0SDv8N2Yz240ouw69GBbI9W55CYIv5wZ1wldesC8R09v+rg==","shasum":"4d6277a4bc3d4628eb16a7ce3f3179e13252abf7","tarball":"https://registry.npmjs.org/@1ziton/react-native-scancode/-/react-native-scancode-1.0.5.tgz","fileCount":15,"unpackedSize":75219,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdjeSiCRA9TVsSAnZWagAAm8kP/1SYzdeqsVNzGHjWYdTh\n68G/W1xPU8xc0lqh9r3yp/W/Smuv7DNBfJmo4OVPGz8dA0RKYNbk+tVLQ6mU\nRrl5VVPVT31zDz4MD7ZxhyiDEUeRsfRI04q9ETA/E4A96TVHGYlS+NoouYlZ\n42qLt0eBuyXZqMSr2LAUVxrTO6HrIi/bfU4Tj3yUFlpuug+KHrBDxfrEFyIb\niChmmHxIi7qQeFn5Cgn7sTbEyEGcfT8UQCxpH+IT3ALZd4ObDLVE5x7wXmvy\nDzUWXpxTORfjZxhbmJkcFQAQsw36JMPmEDrWIaLwNUBkA3lV9YD6rbzdT0ji\n/xWi8Fk9CApq53OdMYw7YrgA4iAuYMjMTy709bcvy9ppnL0cDGsOsSeauU+N\nGfR+vJGu8GeWrBV2N5RKwhdJSLFMu+a61Lw1mhsDhPHhssZhF2E9NU0GC0Tw\noSje2qr+U6c7BU4vEryIkl58t6pxlE+t5JAcxGLCmb3rSIwU98zXuP+O8Jbn\nw+CZ29wzC/gINMerXhhl4Y3DfmAB/lBkYBLjeMjocEZxg6RHlgWFBETp3Gau\nu22LDBY8CV93S+zSiBa9fYsgLXYlqn2mBXc5SNu4vXpvUCo6RPmfm8ZqocCL\n9F9DHGI0IAmGEX3i4TAppYdvKaJC1T4ySjD+ZOQyilpk+JdbdB29yD0vhaCT\nobOg\r\n=a2yQ\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIBp43jc2h//PKblXavyK/811e9938zf4KRFIyDUYqAEoAiAWm0APYmUYBIad0eilLO2rka/bMAze637G9+sF3DP4yw=="}]},"maintainers":[{"name":"giscafer","email":"giscafer@outlook.com"},{"name":"tangjijun","email":"920449619@qq.com"},{"name":"wuyuxing","email":"359827672@qq.com"},{"name":"xinzhenyong","email":"494063647@qq.com"}],"_npmUser":{"name":"xinzhenyong","email":"494063647@qq.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/react-native-scancode_1.0.5_1569580194005_0.355050567479545"},"_hasShrinkwrap":false}},"time":{"created":"2019-08-26T02:16:22.434Z","1.0.2":"2019-08-26T02:16:22.823Z","modified":"2022-04-04T10:34:48.770Z","1.0.3":"2019-08-26T02:17:44.658Z","1.0.4":"2019-09-27T09:13:05.162Z","1.0.5":"2019-09-27T10:29:54.126Z"},"maintainers":[{"email":"it@1ziton.com","name":"yztnpm"},{"email":"359827672@qq.com","name":"wuyuxing"},{"email":"494063647@qq.com","name":"xinzhenyong"},{"email":"giscafer@outlook.com","name":"giscafer"}],"description":"## PDA扫描插件","homepage":"https://github.com/Txiaomo/react-native-scancode#readme","keywords":["react-native"],"repository":{"type":"git","url":"git+ssh://git@github.com/Txiaomo/react-native-scancode.git"},"author":{"name":"xiaomo"},"bugs":{"url":"https://github.com/Txiaomo/react-native-scancode/issues"},"license":"PDA扫描插件","readme":"# react-native-scancode\r\n\r\n## Getting started\r\n\r\n`$ npm install react-native-scancode --save`\r\n\r\n### Mostly automatic installation\r\n\r\n`$ react-native link react-native-scancode`\r\n\r\n### Manual installation\r\n\r\n#### Android\r\n\r\n1. Open up `android/app/src/main/java/[...]/MainApplication.java`\r\n\r\n- Add `import com.xiaomo.ScancodePackage;` to the imports at the top of the file\r\n- Add `new ScancodePackage()` to the list returned by the `getPackages()` method\r\n\r\n2. Append the following lines to `android/settings.gradle`:\r\n\r\n   ```\r\n   include ':react-native-scancode'\r\n   project(':react-native-scancode').projectDir = new File(rootProject.projectDir, \t'../node_modules/react-native-scancode/android')\r\n   ```\r\n\r\n3. Insert the following lines inside the dependencies block in `android/app/build.gradle`:\r\n   ```\r\n   compile project(':react-native-scancode')\r\n   ```\r\n\r\n## Usage\r\n\r\n```javascript\r\n// TODO: What to do with the module?\r\nimport { NativeModules } from \"react-native\";\r\nconst { WmsScanCode } = NativeModules;\r\n\r\n//设置扫码选项(当PDA设备能通过广播进行设置的时候可用)\r\nlet obj={};\r\nlet list=[];\r\nobj['key']='barcode_send_mode';\r\nobj['value']='BROADCAST';\r\nlist.push(obj);\r\nWmsScanCode.setBroadcastSetting('com.android.scanner.service_settings',list);\r\n\r\n//广播和接收字段(接收的广播名和接收的字段名)\r\nWmsScanCode.getCode('android.intent.action.SCANRESULT','value');\r\n\r\n//接收扫描结果\r\nimport { DeviceEventEmitter } from \"react-native\";\r\ncomponentWillMount() {\r\n  if (this.searchListener) {\r\n    this.searchListener.remove();\r\n  }\r\n  this.searchListener = DeviceEventEmitter.addListener(\"scannerCodeShow\",e => {\r\n    console.log(e.code)\r\n    }\r\n  )\r\n}\r\n//退出页面移除监听\r\ncomponentWillUnmount() {\r\n  if (this.searchListener) {\r\n    DeviceEventEmitter.removeListener(\"scannerCodeShow\");\r\n    this.searchListener.remove();\r\n    this.searchListener = null;\r\n  }\r\n}\r\n\r\n\r\n```\r\n","readmeFilename":"README.md"}