Skip to content

yy7054wyq5/bootstrap-select-ajax

 
 

Repository files navigation

bootstrap-select-ajax

Notice: This package is forked from silviomoreto/bootstrap-select. I just modify a little code for ajax(at line 1426 in js/boostrap-select-ajax.js).And i add a stamp.

Install

npm install bootstrap-select-ajax

HTML

<select class="ajax-search" ajax-url="your ajax api" ajax-params="{#pnType#: #onePart#, #fromSys#: #scmship#}" ajax-option-name="name" ajax-option-value="age" default-data="{#name#: #xiaoming#, #age#: 28}"></select>

Attribute description

Attribute type description
ajax-search-key string search key
ajax-url string request url
ajax-params like json use # instead ", request other params
ajax-option-name string option's name
ajax-option-value value option's value
default-data like json use # instead " ,corresponding ajax-option-name and ajax-option-value

How to use

1.npm install

2.gulp

3.open http://localhost:8080 in your chrome brower

4.you will see demo

About

bootstrap-select with ajax options. Example in index.html

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 83.5%
  • HTML 12.0%
  • PowerShell 2.9%
  • CSS 1.6%