npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

capacitor-plugin-idata-scan

v0.0.5

Published

针对idata的pda设备T1型号针对性定制的扫描插件

Downloads

12

Readme

capacitor-plugin-idata-scan

针对idata的pda设备T1型号针对性定制的扫描插件

一、具备以下核心功能点:

  • [ ] 1. 打开扫描头
  • [ ] 2. 关闭扫描头
  • [ ] 3. 开始扫描
  • [ ] 4. 停止扫描
  • [ ] 5. 扫描成功后调用web前端预留js方法,唤醒康复app,并跳转到治疗详情界面

二、拓展功能

  • [ ] 1. 配置扫描结果的输出方式
  • [ ] 2. 配置是否禁用物理按键(黄色按键)
  • [ ] 3. 配置扫描提示音、振动、指示灯
  • [ ] 4. 配置扫描的目标格式(条形码类型、二维码类型)

Install

npm install capacitor-plugin-idata-scan
npx cap sync

API

echo(...)

echo(options: { value: string; }) => Promise<{ value: string; }>

| Param | Type | | ------------- | ------------------------------- | | options | { value: string; } |

Returns: Promise<{ value: string; }>


init()

init() => Promise<{ value: string; }>

初始化方法,需要判断设备是否具备pad功能才调用,否则会因为硬件层找不到对应的方法而闪退并且无法捕获错误

Returns: Promise<{ value: string; }>


scanStart()

scanStart() => Promise<{ value: string; }>

打开扫描头,开启后直到扫描了二维码条形码,或者调用关闭,才会关掉扫描头,否则会一直开着

Returns: Promise<{ value: string; }>


scanStop()

scanStop() => Promise<{ value: string; }>

关闭扫描头

Returns: Promise<{ value: string; }>


scanSetTimeOut(...)

scanSetTimeOut(options: { millisecond: number; }) => Promise<{ value: string; }>

设置读头超时时间,默认为3秒,参数是毫秒

| Param | Type | | ------------- | ------------------------------------- | | options | { millisecond: number; } |

Returns: Promise<{ value: string; }>


addListener('onScanListener', ...)

addListener(eventName: 'onScanListener', listenerFunc: (data: any) => void) => Promise<PluginListenerHandle>

| Param | Type | | ------------------ | ----------------------------------- | | eventName | 'onScanListener' | | listenerFunc | (data: any) => void |

Returns: Promise<PluginListenerHandle>


Interfaces

PluginListenerHandle

| Prop | Type | | ------------ | ----------------------------------------- | | remove | () => Promise<void> |