Giter Site home page Giter Site logo

zbarcordovaplugin's Introduction

cordova-plugin-barcode 二维码扫描Cordova插件

This plugin implements barcode scanner on Cordova 4.0

Supported Cordova Platforms

  • Android 4.0.0 or above
  • iOS 7.0.0 or above

Usage

cordova plugin add https://github.com/JiaQiYue/ZBarCordovaPlugin.git

JS

com.jieweifu.plugins.barcode.startScan({
        message:{
                barTitle:'标题栏文案',
                explainFlag: false,//是否显示说明按钮
                title:'扫码上方描述',
                tipScan:'扫码下方描述',
                inputFlag: true,//是否显示输入按钮
                lightFlag: true,//是否显示照亮按钮
                tipInput:'输入单号提示',
                tipLightOn:'打开照亮提示',
                tipLightOff:'关闭照亮提示',
                tipLoading:'调接口的过程中的提示',
                tipNetworkError:'网络错误时的提示',
                tipOffline:'没有打开web时的提示',
                openButton:'我已打开按钮文字',
                footerFirst:'底部提示第一行,可空',
                footerSecond:'底部提示第二行,可空',
                delayTime:'1000'

        },
        operationType:'REVIEW',
        requests:[
                {
                    url:'www.huilianyi.com',
                    method:'POST',
                    headers:{
                        Authorization:'Bearer xxxxx',
                        Content-Type:'xxxx'
                    },

	            config: {
			timeout: 10000 (单位是毫秒)
		    },

                    data:{
                        code:'xxxx-xxxx',
                        operate:'xxxx'
                    }
                },
                ...
        ]

    },function(success){
        alert(JSON.stringify(success));
    }, function(error){
        alert(JSON.stringify(error));   
    });

注:此插件的作者是jieweifu

zbarcordovaplugin's People

Contributors

jiaqiyue avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.