Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- How to remove auto suggest functionality on Textbox
- function SetAutoSuggest(ProductType) {
- if (ProductType == "PRODUCT") {
- $("#PantryFooodItemName").autocomplete('<%= Url.Action("GetAutosuggestProductlistForMeal", "Autosuggest") %>',
- {
- minChars: 2,
- width: 300,
- multiple: false,
- matchContains: true,
- mustMatch:true,
- formatItem: formatItem,
- formatResult: formatResult
- }
- );
- }
- if (ProductType == "CUSTOMPRODUCT") {
- $("#PantryFooodItemName").autocomplete('<%= Url.Action("GetCustomProduct", "Autosuggest") %>',
- {
- minChars: 2,
- width: 300,
- multiple: false,
- matchContains: true,
- mustMatch: true,
- formatItem: formatItem,
- formatResult: formatResult
- }
- );
- }
- }
- source: function(request, response)
- {}
- [{"id":25,"label":"mylabel","value":"myval"},{"id":26,"label":"mylabel26","value":"myval26"}]
Advertisement
Add Comment
Please, Sign In to add comment